[Printing-architecture] printers.conf frequently gets truncated to zero length after unclean shutdowns

Jiri Popelka jpopelka at redhat.com
Mon Jul 22 17:28:58 UTC 2013


Hello,

When cupsd lives on a filesystem with delayed allocation, like ext4 and
it experience an unclean shutdown under heavy load, its printers.conf 
very often ends up being truncated to zero.

Even original report (https://bugzilla.redhat.com/show_bug.cgi?id=984883)
has been against cups-1.4.2 I've seen no reason to think this has been 
fixed in recent versions.
I see cupsd since 1.5 (due to STR #3715) has been more carefully 
creating and removing conf files,
but that doesn't seem to be sufficient.
Especially updating of printers.conf probably needs some sort of 
synchronization data to disk.

I have a patch (in comment #11), which makes cupsd read backup 
filename.O file if filename is truncated to zero, but that's only a 
work-around
and I'm afraid it won't work if the file gets updated couple times 
between last sync and the unexpected shutdown.

I've promised interested parties to ask you publicly
and since bug tracker @ cups.org is still down ... here I am ;-)

With regards,
Jiri


More information about the Printing-architecture mailing list