On Mon, 8 Jan 2007, Andrew Beekhof wrote:

> you might also want to check out the one under source control:
>    http://hg.linux-ha.org/dev/file/tip/resources/OCF/mysql.in

Sorry for butting in like this, having been dormant here for many, many
months.


> > # Default values - You can tweak them out
> > MYSQL_CONFIG="/etc/my.cnf"
> > MYSQL_DATADIR="/var/lib/mysql"
> > MYSQL_USER="mysql"
> > MYSQL_GROUP="mysql"
> > MYSQL_TEST_TABLE="mysql.user"
> > MYSQL_PIDFILE=/var/run/mysqld/mysqld.pid
> > MYSQL_SOCKET=/var/lib/mysql/mysql.sock

Shouldn't almost all those pathnames appear as "@...@" format?

"configure.in" already sets "@HA_VARRUNDIR@", "@HA_VARLIBDIR@" etc. for
this very purpose, to maintain portability.

And wouldn't "/etc" would be better specified as some variant of
"@sysconfdir@"?


> >         touch /var/lock/subsys/mysqld

And there's another.  There is a "@HA_VARLOCKDIR@" for such pathnames.


Looking wider...

It would be worth going through the entire source tree looking for "/var/"
"/usr/" and "/etc/" and regarding occurences with "guilty until proven
innocent" suspicion.

Occurences in "configure.in", "ConfigureMe" and the various pkg/rpm/port
maintenance things probably are the only likely candidates for innocence.
And even a few of those might benefit from "@...@" generalisation (if only
to assist future maintenance as things inevitably evolve).

I've just grabbed the tip "http://hg.linux-ha.org/dev/archive/tip.tar.gz";
and a done a quick grep... there are quite a few "/var" occurences.

(Alas, I have never had mercurial set up, so I am unable to drip-feed
updates on this.)

Happy New Year from the UK!


-- 

:  David Lee                                I.T. Service          :
:  Senior Systems Programmer                Computer Centre       :
:                                           Durham University     :
:  http://www.dur.ac.uk/t.d.lee/            South Road            :
:                                           Durham DH1 3LE        :
:  Phone: +44 191 334 2752                  U.K.                  :
_______________________________________________________
Linux-HA-Dev: [email protected]
http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev
Home Page: http://linux-ha.org/

Reply via email to