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

RE: Packages should not Conflict on the basis of duplicate functionality

Why not implement a system similar to that in Irix ( and a few other sysv
style systems ), and use a 'chkconfig' type setup..

Irix implements it with a config directory (/etc/config), which contains
files with the same name as the init script or app, and contains a single
word .. 'on' or 'off' ..

so, you can issue:

chkconfig postgresql on
/etc/init.d/postgresql start
chkconfig postgresql off

The modifications to add this to the distribution shouldn't be that
difficult .. the chkconfig (or whatever you want to call it) script can be
used to both test for and set the options..

chkconfig [<app> [on/off]] .. leave off the last parameter to check for the
status inside an init.d script and start based on that .. (leave off second
parameter to see a complete list of whats on/off)

The initial change to add this to the init scripts could take a while
(although its simple to just add it to the beginning of the init scripts,
and just exit if the config is off), but once its implemented it would be a
nice tool.. no?  (every now and again it would be nice to be able to
chkconfig gdm off, and/or chkconfig network off, etc...)

this is a li'l longer implementation (to get started) than changing
start->go, and if you change it just locally then whenever a package is
upgraded you'll have to add the check line to the beginning of the init
scripts .. but long term, this may be a nice feature for debian in general
.. no?

my 2c

-Terry Katz

> -----Original Message-----
> From: Craig Sanders [mailto:cas@taz.net.au]
> Sent: Saturday, October 02, 1999 6:31 PM
> To: Piotr Roszatycki
> Cc: Debian Development Mailing List
> Subject: Re: Packages should not Conflict on the basis of duplicate
> functionality
> On Sat, Oct 02, 1999 at 04:36:04PM +0200, Piotr Roszatycki wrote:
> > I've install postgresql on my home computer. I need this daemon only
> > sometimes. I don't want to start it every time I reboot system.
> you need to do something non-standard, so you should do a little bit of
> work to accommodate your own needs.
> if i needed to do the above then i would edit /etc/init.d/postgresql and
> (in the case statement) change "start)" to "go)". this way, it would
> not get started at boot time, but i could easily start it by running
> "/etc/init.d/postgresql go".
> pros:
> simple. takes <20 seconds with vi. minimal change, so follows principle
> of least surprise. easy to remember. init.d scripts are conffiles so it
> won't be automatically replaced at the next upgrade.
> cons:
> you have to re-do the change if you ever upgrade and answer "Y" to
> dpkg's question about replacing /etc/init.d/postgresql.
> craig
> --
> craig sanders
> --
> To UNSUBSCRIBE, email to debian-devel-request@lists.debian.org
> with a subject of "unsubscribe". Trouble? Contact
> listmaster@lists.debian.org

Reply to: