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 :)

smb.conf:
[gloabal]
load printers = no
printing = cups
printcap name = cups
show add printer wizard = no
[printers]
comment = All Printers
path = /var/spool/samba
valid users = root @samba
public = yes
guest ok = no
writable = no
printable = yes
[HP-Laser]
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)

cupsd.conf

add
Listen 192.168.1.1:631

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

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 :)

Popular Posts