UCARP should install as a startable daemon (files included here)

Bug #613888 reported by Tony Shadwick
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
ucarp (Ubuntu)
New
Undecided
Unassigned

Bug Description

Binary package hint: ucarp

The package currently installs as a binary unto itself, requiring the end user to jump through hoops of adding up-scripts and down-scripts, and the documentation is rather lacking in the department of how to make this happen.

What I have done here is templated the ucarp init script after that of OpenVPN. The init script checks /etc/default/ucarp for what virtual IP's to start: all, none, or specifically named ones. Whatever interfaces are named in /etc/default/ucarp must have a matching /etc/ucarp/(name).conf file. So if I have an entry named "mysql", there must be a matching mysql.conf file in /etc/carp.

From within that *.conf file, you must define a START_SCRIPT and a STOP_SCRIPT. These two files bring the virtual interface up and tear the virtual interface down when appropriate. I've included a pair of good starter examples for these. Users may very well need to adjust these to create and remove routes, along with possibly restarting daemons, etc. That leaves me wondering if the right place to default them is /etc/ucarp, or perhaps /usr/lib/ucarp. I will leave that to you to decide.

The only other thing of interest is that with these adjustments adds a dependency on iputils-arping (not to be confused with the package arping). It seems that handoff does not happen smoothly without arping, so rather than leave the end user to flounder with this problem, I've added the solution. It is easily removed from the up and down scripts if they don't want it, but rather than presume that they don't want it to work smoothly in 99% of use cases, I'd addressed the 99% and left the 1% to remove it instead.

I'm attaching an archive of files. The file locations as I can determine them are this:

/etc/init.d/ucarp <- startup script. Someone might want to adjust this for upstart?
/etc/default/ucarp <- as it says, the default settings.
/etc/ucarp/ucarp.conf <- default virtual interface file.
/etc/ucarp/ucarp-up.conf <- default START_SCRIPT
/etc/ucarp/ucarp-down.conf <-default STOP_SCRIPT

The only case I've not extensively tested is that which the user executes /etc/init.d/networking stop or /etc/init.d/networking/restart. I believe they should work okay (again, based on the OpenVPN package's way of handling these cases), but just as a warning.

Revision history for this message
Tony Shadwick (numbski+bugs-launchpad-net) wrote :
Revision history for this message
Tony Shadwick (numbski+bugs-launchpad-net) wrote :

Well, this is an "interesting" state of affairs. The package maintainer is Eric Evans, yet Launchpad points out that "Eric Evans does not use Launchpad".

So....this is destined to sit here infinitely unless I can find a way to contact Eric Evans. Looks like about 20 other people or so get notified other than Eric, so if one of you happens to know the right thing to do here, please let me know. :)

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.