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

starting /etc/init.d/* from re-mountable media



I filed a (wishlist) bug against sysklogd as when I install it, I do:

   dpkg -i sysklogd*.deb

>From a directory on a Zip drive. Later on I was puzzled why I couldn't
"umount" the Zip drive - it was because sysklogd had been run from there.

This doesn't particularly bug me, but what do other people think - should
all postinst scripts "cd" somewhere safe before running /etc/init.d/...?

I've attached the bug report and Joey's reply below.

---cut-here---
[joey@kuolema.Infodrom.North.DE: Re: Bug#17278: sysklogd: restart from root directory]
On Mon, Jan 19, 1998 at 05:33:10PM +0000, Adrian Bridgett wrote:
> Package: sysklogd
> Version: 1.3-21
> Priority: wishlist
> 
> I often install sysklogd from a zip drive like this:
> 
> cd /zip
> sudo dpkg -i sysklogd*
> cd
> 
> However afterwards I cannot umount the /zip drive as sysklogd is running. I
> have to do "sudo /etc/init.d sysklogd restart" when $PWD is not in /zip and
> then I can umount the drive.
> 
> Perhaps you could do a "cd /" before restarting sysklogd, or maybe since I
> am not using dselect this isn't supported?

Only very few packages do this - to be honest, I only found msqld and
roxen doing this.  Roxen can only be started from a well-defined directory
and msqld?  I don't know why there is a "cd /tmp" when _stopping_ the
program.

I'm closing this bugreport.

If you still want to change this you should go to debian-policy and
start a proposal that every /etc/init.d scrips that support start/stop/restart
etc. must have a defined "cd /some/whe/re" before starting the daemon.
/some/whe/re should be /tmp if the package doesn't depend on a particular
start path.

---cut-here---

email: adrian.bridgett@poboxes.com       | Debian Linux - www.debian.org
http://www.poboxes.com/adrian.bridgett   | Because bloated, unstable 
PGP key available on public key servers  | operating systems are from MS


Reply to: