[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: backing up/replacing files from another package

Eric Winger wrote:
> Can't I even "Depend" on a package and then fine tune its configuration 
> though?

I don't think you can depend upon a package and tweak its
conffiles.  It would be interesting to be able to do that and it
certainly makes sense from an object oriented inherit and modify

Frank suggested building your own package which completely replaced
the original package and naming it autofs-$erico or something similar
and if you are up for it that would work very well.  I do that in a
couple of places, but not for autofs.  Some packages can be renamed
and tweaked with little effort.  Others require more effort.  But I
realize that recompiling the package can make you nervous for critical
and obtuse applications like NFS.

I have the same problem as you and have solved it but unfortunately my
solution is probably a little heavy for your needs.  I install system
configuration scripts which I call a 'sysconf' package.  These scripts
run both at system boot time and by cron.  The first thing they do is
rsync a new copy of themselves from our "gold" servers ensuring that
they are the latest available.  Then they run to configure all of the
little bits of the system like /etc/auto.master which locally we need
configured in a particular way.

As packages are normally upgraded through the life of a system I train
people to always say 'Y' to the replace a conffile question.  Sure
this may leave the system in a generic and locally unworkable state.
But the file is updated to follow the package to the latest version.
After any particular update that a question like that is asked I train
people to always run our 'sysconf' script which configures all of the
little bits of the system, including conffiles, which need to be
tweaked up.  This leaves the system in a locally configured good state
and we are done.  The sysconf scripts must be smart enough to handle
reconfiguring these files and the *running* system in place.

Because it runs by cron this will fix any host that gets accidentally
left in a partially configured state.  Or one that the user left in a
broken state.  By running at boot time it means that a host that is
powered off for a long time will be brought up to the latest local
configuration when it is powered back on.


Attachment: pgpU3l0Umt0Z9.pgp
Description: PGP signature

Reply to: