cupsaddsmb problem with Samba printer share with 'security = share' - solution updated

Paul McIlfatrick paul.mcilfatrick at bt.com
Wed May 14 07:43:23 PDT 2008


> I posted in this newsgroup because I believe that cupsaddsmb is a CUPS written tool but I eventually found the solution in a Samba newsgroup reply.

<snip>

> Suggestion:
>
> The man page for cupsaddsmb should be updated with this information as it seems that this has been a problem for a lot of people.


My earlier post on a solution was not totally correct in that two lines need to be added to the smb.comf file and nothing is needed to be added to the smbuser file (i.e. no 'foo = *').

The two lines that are needed in the smb.conf file (BTW user 'nobody' must exist in the /etc/passwd file):

guest account = nobody
map to guest = Bad User


Now I can create a new printer by using the Administration tab of the  printhost server's CUPS webpage from my PC (I have to give it the location of the new printer's ppd file) and then I open \\printhost from my PC and when the new printer appears in the window, run the cupsaddsmb tool for this new printer (it copies over the CUPS PostScript files and the various Windows PostScript files from the /usr/share/cups/drivers directory were I have copied them - see man page for cupsaddsmb for details) and it then completes successfully.

My working smb.conf file is appended.


After all this, when I right-click on the new printer in the \\printhost window on my PC and choose Connect it fails with the message "The server for the 'printer X' printer does not have the correct printer driver installed. If you ...".

So close!


Any help would be most appreciated in getting me over this final hurdle.



Thanks


Paul McIlfatrick


This is the working smb.conf file:

# Date: 2008-05-14
[global]
   workgroup = bec
   server string = Printhost01
   load printers = yes
   printing = cups
   printcap name = cups
   printcap cache time = 750
   cups options = raw
   security = user
   username map = /etc/samba/smbusers
   netbios aliases = printers
   netbios name = printhost01
   encrypt passwords = yes
   passdb backend = smbpasswd
#  wins server = 10.240.5.7 10.240.6.7
## wins server = 10.240.6.7
   wins support = no
   domain master = no
   guest account = nobody
   map to guest = Bad User

[printers]
   comment = All Printers
   path = /var/tmp
   browseable = no
   public = yes
   guest ok = yes
   printable = yes
   writable = yes

[print$]
   comment = Printer Drivers
   path = /etc/samba/drivers
   browseable = yes
   guest ok = no
   read only = yes
   write list = root





More information about the cups mailing list