Edit the Samba configuration file smb.conf (usually located in /usr/local/etc/smb.conf) to add the new printer:
[sec PCL] comment = HP2200dn PCL in #123 printer name = sec path = /tmp printable = Yes use client driver = No printer admin = on, sanjeet, adul, root default devmode = No
The following works for Samba 3 and Windows XP only.
On a Windows XP machine, connect with and account that has Samba administrator privileges, in CSIM it should be "User Name: root" "Domain: SAMBA". Open Windows Explorer and go to the directory Printers and Faxes of the Samba server: \\banyan\Printers and Faxes
Right click on the background of Windows Explorer window and choose Server Properties from the contextual menu.
Select the tab Drivers and proceed to add a new drivers on the Samba server.
You will see that the files of the new driver are copied to \\banyan\print$\M32X86
On the Samba server, you can check that new files have been added to the directory defined in the path of the share print$. For Windows XP, the files are added in the subdirectory M32X86.
On the Samba server you can use the following command to get the list of installed drivers:
# rpcclient -U'root%******' -c 'enumdrivers' banyan [Windows NT x86] Printer Driver Info 1: Driver Name: [HP LaserJet P4010_P4510 Series PCL 6] Printer Driver Info 1: Driver Name: [HP LaserJet 4300 PS] Printer Driver Info 1: Driver Name: [HP LaserJet 4300 PCL 6] Printer Driver Info 1: Driver Name: [HP Universal Printing PS] #
On the Samba server, use the following command to assign one driver to one printer:
# rpcclient -U'root%*****' -c 'setdriver sec\ PCL HP\ LaserJet\ 4300\ PCL\ 6' banyan Successfully set sec PCL to driver HP LaserJet 4300 PCL 6. #
Note that if the name of the printer of the name of the driver contains any space, they are escaped with \.
To see if a driver has been configured, use the command:
# rpcclient -U'root%*****' -c 'getdriver sec\ PCL' banyan [...] #
It lists all the files corresponding to the driver or returns an error message.
On a Windows XP machine, connect with Samba administrator account, in CSIM it should be "User Name: root" "Domain: SAMBA". Open Windows Explorer and go to the directory Printers and Faxes of the samba server:\\banyan\Printers and Faxes
Right click on the name of the printer and select "Properties".
Configure the tab "Device Settings" and "Advanced/Printing Defaults".
Use Add Printer Wizard.