cupsaddsmb cannot find cups printers

Markus Durzinsky mardur at gmx.net
Fri Jan 11 09:50:13 PST 2008


I have cups 1.3.5 running and working fine with some HP LaserJets. Now I want to setup samba 3.0.28 with automatic driver download for windows clients. Samba (compiled with cups-support) is running, added smbuser root, downloaded cups-ps files and adobe-ps files to cups/drivers. The smb.conf comes from the cupsaddsmb-manpage. Now I called cupsaddsmb:

========================================================================
durzinsk.xi ~ > + /opt/cups/sbin/cupsaddsmb -H xi -U root -v -a
Password for root required to access localhost via SAMBA:
Running command: smbclient //localhost/print$ -N -A /tmp/4787a6cf64596 -c 'mkdir W32X86;put /tmp/4787a6ca96df7 W32X86/adonis.ppd;put /opt/cups/share/cups/drivers/ps5ui.dll W32X86/ps5ui.dll;put /opt/cups/share/cups/drivers/pscript.hlp W32X86/pscript.hlp;put /opt/cups/share/cups/drivers/pscript.ntf W32X86/pscript.ntf;put /opt/cups/share/cups/drivers/pscript5.dll W32X86/pscript5.dll'
Domain=[XI] OS=[Unix] Server=[Samba 3.0.28]
NT_STATUS_OBJECT_NAME_COLLISION making remote directory \W32X86
putting file /tmp/4787a6ca96df7 as \W32X86/adonis.ppd (18514.7 kb/s) (average 18515.3 kb/s)
putting file /opt/cups/share/cups/drivers/ps5ui.dll as \W32X86/ps5ui.dll (20999.7 kb/s) (average 20171.8 kb/s)
putting file /opt/cups/share/cups/drivers/pscript.hlp as \W32X86/pscript.hlp (25425.3 kb/s) (average 20697.4 kb/s)
putting file /opt/cups/share/cups/drivers/pscript.ntf as \W32X86/pscript.ntf (35184.7 kb/s) (average 30657.5 kb/s)
putting file /opt/cups/share/cups/drivers/pscript5.dll as \W32X86/pscript5.dll (34192.1 kb/s) (average 31678.7 kb/s)

Running command: smbclient //localhost/print$ -N -A /tmp/4787a6cf64596 -c 'put /opt/cups/share/cups/drivers/cups6.ini W32X86/cups6.ini;put /opt/cups/share/cups/drivers/cupsps6.dll W32X86/cupsps6.dll;put /opt/cups/share/cups/drivers/cupsui6.dll W32X86/cupsui6.dll'
Domain=[XI] OS=[Unix] Server=[Samba 3.0.28]
putting file /opt/cups/share/cups/drivers/cups6.ini as \W32X86/cups6.ini (70.3 kb/s) (average 70.3 kb/s)
putting file /opt/cups/share/cups/drivers/cupsps6.dll as \W32X86/cupsps6.dll (6136.4 kb/s) (average 4114.6 kb/s)
putting file /opt/cups/share/cups/drivers/cupsui6.dll as \W32X86/cupsui6.dll (13350.3 kb/s) (average 6423.8 kb/s)

Running command: rpcclient localhost -N -A /tmp/4787a6cf64596 -c 'adddriver "Windows NT x86" "adonis:pscript5.dll:adonis.ppd:ps5ui.dll:pscript.hlp:NULL:RAW:pscript5.dll,adonis.ppd,ps5ui.dll,pscript.hlp,pscript.ntf,cups6.ini,cupsps6.dll,cupsui6.dll"'
Printer Driver adonis successfully installed.

Running command: smbclient //localhost/print$ -N -A /tmp/4787a6cf64596 -c 'mkdir WIN40;put /tmp/4787a6ca96df7 WIN40/adonis.PPD;put /opt/cups/share/cups/drivers/ADFONTS.MFM WIN40/ADFONTS.MFM;put /opt/cups/share/cups/drivers/ADOBEPS4.DRV WIN40/ADOBEPS4.DRV;put /opt/cups/share/cups/drivers/ADOBEPS4.HLP WIN40/ADOBEPS4.HLP;put /opt/cups/share/cups/drivers/ICONLIB.DLL WIN40/ICONLIB.DLL;put /opt/cups/share/cups/drivers/PSMON.DLL WIN40/PSMON.DLL;'
Domain=[XI] OS=[Unix] Server=[Samba 3.0.28]
NT_STATUS_OBJECT_NAME_COLLISION making remote directory \WIN40
putting file /tmp/4787a6ca96df7 as \WIN40/adonis.PPD (18514.7 kb/s) (average 18515.3 kb/s)
putting file /opt/cups/share/cups/drivers/ADFONTS.MFM as \WIN40/ADFONTS.MFM (35130.0 kb/s) (average 32506.8 kb/s)
putting file /opt/cups/share/cups/drivers/ADOBEPS4.DRV as \WIN40/ADOBEPS4.DRV (37219.6 kb/s) (average 35530.1 kb/s)
putting file /opt/cups/share/cups/drivers/ADOBEPS4.HLP as \WIN40/ADOBEPS4.HLP (31975.4 kb/s) (average 35168.7 kb/s)
putting file /opt/cups/share/cups/drivers/ICONLIB.DLL as \WIN40/ICONLIB.DLL (28839.1 kb/s) (average 34766.9 kb/s)
putting file /opt/cups/share/cups/drivers/PSMON.DLL as \WIN40/PSMON.DLL (27998.6 kb/s) (average 34558.7 kb/s)

Running command: rpcclient localhost -N -A /tmp/4787a6cf64596 -c 'adddriver "Windows 4.0" "adonis:ADOBEPS4.DRV:adonis.PPD:NULL:ADOBEPS4.HLP:PSMON.DLL:RAW:ADOBEPS4.DRV,adonis.PPD,ADOBEPS4.HLP,PSMON.DLL,ADFONTS.MFM,ICONLIB.DLL"'
Printer Driver adonis successfully installed.
========================================================================

So far, cupsaddsmb found the first printer 'adonis' and installed winxp and win98 drivers. But then is says:

========================================================================
Running command: rpcclient localhost -N -A /tmp/4787a6cf64596 -c 'setdriver adonis adonis'
result was WERR_INVALID_PRINTER_NAME

Unable to set Windows printer driver (1)!
========================================================================

Starting an infinite loop repeating everything (except password request). How did the driver install find adonis, when the printer install doesn't?

Calling "rpcclient -Uroot%password -c 'enumprinters' xi" just says "No printers returned."

Everytime when samba is started, I get the following lines in log/cups/access_log:

xi - - [11/Jan/2008:18:19:35 -0100] "POST / HTTP/1.1" 200 134 CUPS-Get-Printers client-error-bad-request
xi - - [11/Jan/2008:18:19:35 -0100] "POST / HTTP/1.1" 200 134 CUPS-Get-Classes client-error-bad-request
xi - - [11/Jan/2008:18:19:35 -0100] "POST / HTTP/1.1" 200 134 CUPS-Get-Printers client-error-bad-request
xi - - [11/Jan/2008:18:19:35 -0100] "POST / HTTP/1.1" 200 134 CUPS-Get-Classes client-error-bad-request

and those in log/cups/error_log:

E [11/Jan/2008:18:19:35 -0100] Unsupported character set "iso-8859-1"!
E [11/Jan/2008:18:19:35 -0100] Unsupported character set "iso-8859-1"!
E [11/Jan/2008:18:19:35 -0100] Unsupported character set "iso-8859-1"!
E [11/Jan/2008:18:19:35 -0100] Unsupported character set "iso-8859-1"!

Any idea how to resolve this?

=== my cups.conf =======================================================
LogLevel info
SystemGroup sw root
ServerName xi
ServerAdmin <some email address>
HostNameLookups On

Port 631
Browsing On
BrowseProtocols cups
BrowseAddress @LOCAL
BrowseOrder allow,deny
BrowseDeny All
DefaultAuthType Basic

<Location />
  Order deny,allow
  Deny from all
  Allow from localhost
  Allow from <some ip range>
  Allow from xi
</Location>

<Location /admin>
  Require user @SYSTEM
  Encryption Required
  Order deny,allow
  Deny from all
  Allow from localhost
  Allow from xi
</Location>

<Policy default>
  <Limit Send-Document Send-URI Hold-Job Release-Job Restart-Job Purge-Jobs Set-Job-Attributes Create-Job-Subscription Renew-Subscription Cancel-Subscription Get-Notifications Reprocess-Job Cancel-Current-Job Suspend-Current-Job Resume-Job CUPS-Move-Job>
    Require user @OWNER @SYSTEM
    Order deny,allow
  </Limit>

  <Limit CUPS-Add-Modify-Printer CUPS-Delete-Printer CUPS-Add-Modify-Class CUPS-Delete-Class CUPS-Set-Default>
    AuthType Default
    Require user @SYSTEM
    Order deny,allow
  </Limit>

  <Limit Pause-Printer Resume-Printer Enable-Printer Disable-Printer Pause-Printer-After-Current-Job Hold-New-Jobs Release-Held-New-Jobs Deactivate-Printer Activate-Printer Restart-Printer Shutdown-Printer Startup-Printer Promote-Job Schedule-Job-After CUPS-Accept-Jobs CUPS-Reject-Jobs>
    AuthType Default
    Require user @SYSTEM
    Order deny,allow
  </Limit>

  <Limit Cancel-Job CUPS-Authenticate-Job>
    Require user @OWNER @SYSTEM
    Order deny,allow
  </Limit>

  <Limit All>
    Require valid-user
    Order deny,allow
  </Limit>
</Policy>






More information about the cups mailing list