Bug 2950 - Problems in adding printers using add printer script
Problems in adding printers using add printer script
Status: RESOLVED INVALID
Product: Samba 3.0
Classification: Unclassified
Component: Printing
3.0.13
All Windows 2000
: P3 normal
: none
Assigned To: Gerald (Jerry) Carter
Samba QA Contact
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2005-08-02 08:24 UTC by Guruswamy
Modified: 2005-09-27 09:24 UTC (History)
0 users

See Also:


Attachments
The "addprinter command" script (2.26 KB, text/plain)
2005-08-02 08:24 UTC, Guruswamy
no flags Details
smb.conf file (1.17 KB, text/plain)
2005-08-02 08:26 UTC, Guruswamy
no flags Details
The log file (34.97 KB, text/plain)
2005-08-02 08:26 UTC, Guruswamy
no flags Details
The vb script file run from windows 2003 server (443 bytes, text/plain)
2005-08-02 08:28 UTC, Guruswamy
no flags Details
A more complete samba.log file (54.62 KB, text/plain)
2005-08-10 07:42 UTC, Guruswamy
no flags Details
A new level 10 log when adding a new printer through scruipt failed (77.31 KB, text/plain)
2005-08-22 07:44 UTC, Guruswamy
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Guruswamy 2005-08-02 08:24:00 UTC
I am using samba version 3.0.13. 

The windows server is windows 2003 server.

I had been trying to install a printer from the server by running the
addprinter.vbs script(written by calling functions in prnadmin.dll). Though the
printer is added, drivers that are specified are not added.

I am also using a "addprinter command" script. I have attached the vb script run
from the server, the "addprinter command" script, the smb.conf file and logs.

Please let me know if I am doing something wrong.
Comment 1 Guruswamy 2005-08-02 08:24:56 UTC
Created attachment 1350 [details]
The "addprinter command" script
Comment 2 Guruswamy 2005-08-02 08:26:09 UTC
Created attachment 1351 [details]
smb.conf file
Comment 3 Guruswamy 2005-08-02 08:26:29 UTC
Created attachment 1352 [details]
The log file
Comment 4 Guruswamy 2005-08-02 08:28:44 UTC
Created attachment 1353 [details]
The vb script file run from windows 2003 server
Comment 5 Gerald (Jerry) Carter 2005-08-02 10:39:27 UTC
There's no spoolss traffic in this log file.  Can you attach a full
level 10 trace of the script failure.
Comment 6 Guruswamy 2005-08-10 07:42:20 UTC
Created attachment 1363 [details]
A more complete samba.log file
Comment 7 Gerald (Jerry) Carter 2005-08-12 12:34:21 UTC
It looks like the log you uploaded is for winbindd
and not smbd.  After reading your comments again
and looking at the vb script, I think there may be 
some confusion.

You have to install the driver on the samba server prior 
to calling AddPrinter().  It seems you are assuming that
creating the printer should add the driver automatically.
But unless there is something else in you code that will 
do this automatically for you, adding the printer will fail 
with WERR_UNKNOWN_PRINTER_DRIVER.
Comment 8 Guruswamy 2005-08-22 07:44:23 UTC
Created attachment 1395 [details]
A new level 10 log when adding a new printer through scruipt failed

I tried adding a printer whose printer is already installed in the Samba
Server. Even then, the same problem re-occurs. Also, the same back-end script
works correctly when created with APW.
Comment 9 Guruswamy 2005-08-22 21:53:27 UTC
Comment on attachment 1395 [details]
A new level 10 log when adding a new printer through scruipt failed

I tried adding a printer whose printer driver is already installed in the Samba
Server. Even then, the same problem re-occurs. Also, the same back-end script
works correctly when a printer is created with APW.
Comment 10 Gerald (Jerry) Carter 2005-09-27 09:24:50 UTC
My guess is that your addprinter command is not actually 
succeeeding but retuning 0 indicating success.
The ACCESS_DENIED is due to the fact that smbd cannot find the 
new printer

Also note that

  printer admin = @printeradmin

has been deprecated in favor of the SePrintOperatorPrivilege.
So you should move to this to ensure that the add printer 
command is run with the appropriate rights (i.e. as root).

So this all looks like a configuration issue and not a Samba bug.