First Last Prev Next    No search results available      Search page      Enter new bug
Bug#: 15492
Alias:
Product:
Component:
Status: RESOLVED
Resolution: FIXED
Assigned To: Printing Team <printing@gentoo.org>
Hardware:
OS:
Version:
Priority:
Severity:
Reporter: Chris Paulson-Ellis <kelsall@dsl.pipex.com>
Add CC:
CC:
URL:
Summary:
Status Whiteboard:
Keywords:

Filename Description Type Creator Created Size Actions
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 15492 depends on: Show dependency tree
Bug 15492 blocks:
Votes: 0    Show votes for this bug    Vote for this bug

Additional Comments: (this is where you put emerge --info)


Not eligible to see or edit group visibility for this bug.






View Bug Activity   |   Format For Printing   |   XML   |   Clone This Bug


Description:   Opened: 2003-02-11 07:24 0000
I have samba configured to serve up all the printers configured in cups. This 
works fine if samba is started (or restarted) manually. However, when started 
on boot, although samba is started after cups (the samba init script says "use 
cupsd"), it does not serve any printers.

As a work-around, I changed the samba init script to say "after *" to get it to 
start a bit later than "use cupsd" does. This gives cups more time to complete 
its startup. By the time samba starts, it manages to enumerate the printers 
correctly and serves them all.

My work-around is in the wrong place really. It would be better if the cupsd 
init script didn't return until the server is fully initialised and ready to 
list the printers.


Reproducible: Always
Steps to Reproduce:
1. Configure samba to use cups to find printers.
2. Add samba and cupsd to the default run level.
3. Reboot.
4. Do "smbclient -L localhost -N"

Actual Results:  
No printers appear in the smbclient output.

Expected Results:  
The output from smbclient should include a line for each printer, like this:

        Sharename      Type      Comment
        ---------      ----      -------
        IPC$           IPC       IPC Service (Samba Server 2.2.7a)
        ADMIN$         Disk      IPC Service (Samba Server 2.2.7a)
        dj895cxi       Printer

Manually do '/etc/init.d/samba restart'. Smbclient will then show the printers 
correctly.


net-fs/samba: 2.2.7a
net-print/cups: 1.1.18

Portage 2.0.46-r6 (default-1.0, gcc-2.95.3, glibc-2.2.5-r7,2.2.5-r4)
=================================================================
System uname: 2.4.19-gentoo-r10 i686 Pentium II (Deschutes)
GENTOO_MIRRORS="http://www.ibiblio.org/pub/Linux/distributions/gentoo"
CONFIG_PROTECT="/etc /var/qmail/control /usr/share/config /usr/kde/2/share/confi
g /usr/kde/3/share/c
onfig /usr/share/config:/usr/X11R6/lib/X11/xkb:/usr/kde/3/share/config"
CONFIG_PROTECT_MASK="/etc/gconf /etc/env.d"
PORTDIR="/usr/portage"
DISTDIR="/usr/portage/distfiles"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR_OVERLAY=""
USE="x86 oss 3dnow apm avi crypt cups encode jpeg libg++ libwww mikmod mmx mpeg 
ncurses pdflib qtmt
quicktime spell truetype xml2 xmms xv arts berkdb cdr esd gdbm gif gnome-libs 
gpm gtk imlib java kde
 motif nls oggvorbis opengl pam perl png python qt readline scanner sdl slang 
ssl svga tcpd tiff X"
COMPILER=""
CHOST="i686-pc-linux-gnu"
CFLAGS="-march=i686 -O3 -pipe"
CXXFLAGS="-march=i686 -O3 -pipe"
ACCEPT_KEYWORDS="x86"
MAKEOPTS="-j2"
AUTOCLEAN="yes"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
FEATURES="sandbox ccache"

------- Comment #1 From Frédéric Point 2003-06-05 13:08:24 0000 -------
exactly the same bug for me !!! 

------- Comment #2 From Frédéric Point 2003-06-06 23:13:08 0000 -------
here is my patch : 
 
--- /etc/init.d/cupsd   2003-01-31 18:16:18.000000000 +0100 
+++ cupsd       2003-06-07 05:58:24.000000000 +0200 
@@ -10,6 +10,17 @@ 
 start() { 
        ebegin "Starting cupsd" 
        start-stop-daemon --start --quiet --background --exec /usr/sbin/cupsd 
+       retry=5 
+       while [ ${retry} -gt 0 ] 
+       do 
+        lpstat > /dev/null 2>&1 
+       if [ $? -eq 0 ] 
+       then 
+               break 1 
+       fi 
+       sleep 1 
+       retry=$((${retry} -1)) 
+       done 
        eend $? 
 } 
 
 
It check with lpstat if cupsd has started ... 
 
maybe i have to return a fail if he dant start after number of retry, but it's too late  
in the morning : i really have to get some sleep .... 

------- Comment #3 From Thomas Raschbacher 2003-06-19 04:01:03 0000 -------
will have a look .. sorry for the delay there was a problem with the mail alias
so i didn't get the Bugzilla mails

------- Comment #4 From Heinrich Wendel (RETIRED) 2003-06-28 14:05:45 0000 -------
deleting the --background from start-stop-daemon should do the trick

------- Comment #5 From Chris Paulson-Ellis 2003-07-09 13:01:22 0000 -------
Hi (from original bug reporter), 
 
Sorry for not trying your suggestions earlier. 
 
I removed the --background from the init script and the problem was solved. Boot time 
increased a bit, but hey, that was what was neccesary, right? 
 
Commit the change I say. 
 
Thanks a lot for your help, 
Chris. 

------- Comment #6 From Heinrich Wendel (RETIRED) 2003-07-16 08:09:17 0000 -------
fixed.

First Last Prev Next    No search results available      Search page      Enter new bug