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

Bug#324900: nscd: umount /var fails (unclean shutdowns)

At Thu, 25 Aug 2005 09:59:46 +0200,
Zlatko Calusic wrote:
> GOTO Masanori <gotom@debian.or.jp> writes:
> > At Wed, 24 Aug 2005 20:14:43 +0200,
> > Zlatko Calusic wrote:
> >> With the latest changes in nscd functionality, namely using persistent
> >> database in /var/db/nscd, /var partition can't be cleanly umounted. I
> >> tried to avoid the problem by disabling persistent database, but even
> >> that didn't help because nscd keeps open descriptor to a deleted file
> >> in /var/run, and somehow /etc/init.d/rc inherits it.
> >> 
> >> This is the relevant part of the lsof output fired just before the
> >> umount line in /etc/init.d/umountfs:
> >> 
> >> rc        2470 root  DEL       REG    3,9           1093449 /var/run/nscd/dbUUHtCX

I missed this line.  /var/run/nscd/dbXXXXXX is created at nscd_init()
in nscd/connections.c.  However, even if this file is created, it's
closed soon in the same initialization routine.  rc does not have any
relations with this temporary file.  So, if this file is marked as
open, someone takes over fd of /var/run/nscd/dbXXXXXX and it passes to

> > Why didn't your nscd shutdown before /etc/init.d/umountfs was invoked?
> > Under my standard sid environment, such problem does not occur because
> > nscd is stopped before umount is executed.
> But it DID! To prove it, here's full lsof output, there's no
> mentioning of nscd running. I'm also confused how that one reference
> leaks to /etc/init.d/rc. But it happens on three machines, so it is
> very repeatable here.

Could you reinstall libc6 and nscd packages again?  Hmm, is this
problem repeatable even after rebooting the system?  If so, rc or some
packages behave incorrectly.

-- gotom

Reply to: