Bug 200395 - broken initscript
broken initscript
Status: CLOSED CURRENTRELEASE
Product: Fedora
Classification: Fedora
Component: ucarp (Show other bugs)
5
All Linux
medium Severity high
: ---
: ---
Assigned To: Matthias Saou
Fedora Extras Quality Assurance
:
Depends On:
Blocks: FE7Target
  Show dependency treegraph
 
Reported: 2006-07-27 09:34 EDT by ValueCommerce Infrastructure Team
Modified: 2007-11-30 17:11 EST (History)
1 user (show)

See Also:
Fixed In Version: 1.2-7
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2007-02-05 08:10:20 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
the src.rpm (185.27 KB, application/x-rpm)
2006-09-20 07:58 EDT, ValueCommerce Infrastructure Team
no flags Details

  None (edit)
Description ValueCommerce Infrastructure Team 2006-07-27 09:34:22 EDT
Description of problem:
The initscript uses invalid find call and thus doesn't work:

# service carp restart
find: warning: you have specified the -maxdepth option after a non-option
argument -type, but options are not positional (-maxdepth affects tests
specified before it as well as those specified after it).  Please specify
options before other arguments.

WARNING: initlog is deprecated and will be removed in a future release

Starting common address redundancy protocol daemon: find: warning: you have
specified the -maxdepth option after a non-option argument -type, but options
are not positional (-maxdepth affects tests specified before it as well as those
specified after it).  Please specify options before other arguments.

                                                           [  OK  ]



Version-Release number of selected component (if applicable):
ucarp-1.1-5.fc5
Comment 1 ValueCommerce Infrastructure Team 2006-07-27 09:43:24 EDT
This is the patch to /etc/init.d/carp:

--- carp.orig   2006-07-27 17:38:32.000000000 +0400
+++ carp        2006-07-27 17:41:04.000000000 +0400
@@ -15,7 +15,7 @@
 [ ${NETWORKING} = "no" ] && exit 0
 
 get_files() {
-    FILES=`find /etc/sysconfig/carp -type f -name 'vip-*.conf' -maxdepth 1 \
+    FILES=`find /etc/sysconfig/carp -maxdepth 1 -type f -name 'vip-*.conf' \
            -printf "%f\n" | LC_COLLATE="C" sort`
 }
Comment 2 Matthias Saou 2006-07-27 10:16:22 EDT
Thanks a lot for spotting this problem. The fix will be pushed once bug #200400
is also taken care of.
Comment 3 Matthias Saou 2006-08-22 09:15:34 EDT
Fixed packages of 1.2, which include a patch to bring the code up to the 1.3
snapshot, have just been rebuilt for FC-4, FC-5 and devel. They should be pushed
shortly.
Comment 4 ValueCommerce Infrastructure Team 2006-09-20 07:56:43 EDT
Thank you.
I continued to enhance the scripts until I got something that to my point of
view could be useful to other UCARP users. With the changes offered one gets two
benefits:
1. There is no dependency on initscripts files.
2. It is now possible to bind as many as needed IP addresses to a virtual router.
There is a small drawback also: VIP_INTERFACE must be replaced with appropriate
VIP_ADDRESS. You can find the src.rpm attached, it is built against the latest
ucarp-1.2-3.fc5.src.rpm found in Fedora Extras 5.
Comment 5 ValueCommerce Infrastructure Team 2006-09-20 07:58:08 EDT
Created attachment 136730 [details]
the src.rpm
Comment 6 Matthias Saou 2007-02-05 08:10:20 EST
This has all been merged in the Fedora 7 package. Please have a look at it and
let me know if anything else needs to be changed. Note that I've moved all files
from /etc/sysconfig/carp/ to /etc/ucarp/ and renamed the service to "ucarp"
(changed from carp to ucarp in many places to keep more consistent).

The only minor enhancement I'd like to see is the ability to add an optional
"label" to the VIP interfaces in order to have them show up in "ifconfig"'s output.
Comment 7 ValueCommerce Infrastructure Team 2007-03-02 07:31:42 EST
Thank you, I will try to review on this weekend.

Note You need to log in before you can comment on or make changes to this bug.