Tuesday, 18 November 2008

Samba with CUPS

Here we go again.... some notes on how to share your printer.. quick n dirty I would say.. but works.. what the hell :)

load printers = no
printing = cups
printcap name = cups
show add printer wizard = no
comment = All Printers
path = /var/spool/samba
valid users = root @samba
public = yes
guest ok = no
writable = no
printable = yes
name = HP-Laser
valid users = root @samba
public = yes
printable = yes
available = yes
printing = lprng
printer = HP-Laser
print command = /usr/bin/lpr -P%p -r %s
lpq command = /usr/bin/lpq -P%p
lprm command = /usr/bin/lprm -P%p %j
path = /var/spool/samba
use client driver = yes

done here... restart samba and lets go to CUPS (after you have configured your printer over there of course)



<Location />
Allow localhost
Allow 192.168.1.*
Order deny,allow

and finally...

edit mime.convs and uncomment this line:
application/octet-stream        application/vnd.cups-raw        0       -

restart cups server, go to your windows box and install the drivers for the network printer.

You are good to go :)