http://bugzilla.novell.com/show_bug.cgi?id=520612 Summary: CUPS 1.4: yast2-printer: few seconds delay until cupsd created printers.conf Classification: openSUSE Product: openSUSE 11.2 Version: Factory Platform: All OS/Version: SuSE Other Status: ASSIGNED Severity: Normal Priority: P5 - None Component: Printing AssignedTo: jsmeix@novell.com ReportedBy: jsmeix@novell.com QAContact: jsmeix@novell.com CC: mzugec@novell.com Found By: Development Currently I run CUPS 1.4 RC1 for testing it on my openSUSE 11.1 i386 workstation. Initially after CUPS 1.4 installation from scratch there was no /etc/cups/printers.conf (which is correct because I had no queue and cupsd creates it when needed). I added a queue with YaST without error messages but directly after it the "Overview" dialog did not show the new queue while "lpstat" shows it. In y2log there are lines 2009-07-09 14:24:54 ... Printerlib.ycp:66 Executing bash commandline: /usr/lib/YaST2/bin/autodetect_print_queues
/var/lib/YaST2/autodetected_print_queues.ycp 2009-07-09 14:24:55 ... ShellCommand.cc(shellcommand):78 grep: /etc/cups/printers.conf: No such file or directory
nelson:~ # stat /etc/cups/printers.conf File: `/etc/cups/printers.conf' Size: 573 Blocks: 8 IO Block: 4096 regular file Device: 807h/2055d Inode: 803344 Links: 1 Access: (0600/-rw-------) Uid: ( 0/ root) Gid: ( 7/ lp) Access: 2009-07-09 14:27:07.000000000 +0200 Modify: 2009-07-09 14:25:25.000000000 +0200 Change: 2009-07-09 14:25:25.000000000 +0200 I.e. on 14:24:55 YaST tried to read from printers.conf but the cupsd had not yet written it which is the reason why autodetect_print_queues did not detect the new queue. After clicking [Refresh List] in the "Overview" dialog it shows the new queue. This cupsd behaviour is well known and described in http://en.opensuse.org/SDB:CUPS_in_a_Nutshell "General information on the command-line tools: ... cupsd keeps much of the information in the main memory and writes information back to the configuration files whenever needed" but Michael Sweet had told me that the cupsd does not needlessly delay writing (i.e. it writes as soon as possible which is usually "instantly") - but one cannot rely on it. I will add some best-effort test in YaST to deal with this case. Probably a simple 'sleep 10' if the first attempt to read /etc/cups/printers.conf failed and then one single retry in autodetect_print_queues. -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.