Welcome to the most active Linux Forum on the web.
Go Back > Forums > Linux Forums > Linux - Networking
User Name
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.


  Search this Thread
Old 09-07-2004, 04:43 PM   #1
LQ Newbie
Registered: Aug 2004
Location: MA
Distribution: Redhat, FreeBSD
Posts: 5

Rep: Reputation: 0
Question remote cups printing to a smb/cups print server?

Thanks in advance -

I'm working toward a print server via cups/samba for all os types... Basically printing raw, got the windows driver downloads to work, and printing works ok for those clients but now I need to get linux clients to print to the cups portion of the server remotely. I want to do something like this from a remote linux box:

lpr -P doc /etc/hosts

(doc is a printer configured and shared out via smb/cups to clients via:

lpadmin -p $smbptrname -D "printer description" -E -v socket:// -m $printer.ppd
cupsaddsmb -H -U root -h localhost -v $smbptrname

The idea here is to have the print jobs from different clients pipe through one raw queue.

so.... My question is:

How do I print from a remote Linux/*nix client to a smb/cups print server without using the smb-client?

- adam
Old 09-08-2004, 05:09 PM   #2
Registered: Jul 2004
Location: Netherlands
Distribution: fedora core 8, suse 10.3, ubuntu 7.10, kamikaze 7.09
Posts: 515

Rep: Reputation: 30
Use lpd.

Create on each unix client a remote printer queue and connect it to the (doc) queue on your printer server

Redhat 9 uses
to create new queue's
Old 09-15-2004, 08:31 AM   #3
LQ Newbie
Registered: Aug 2004
Location: MA
Distribution: Redhat, FreeBSD
Posts: 5

Original Poster
Rep: Reputation: 0
Thanks arno,

Actualy I've decided to just use a windows 2000 server as a print server, vith the unix and mac print services turned on... after all, who wants to admin printing, and printing has always been somthing windows has done better. As for my *nix clients I will use cups with a raw queue setup.

As for anyone browsing this post I thought it be nice to add a howto on implimenting samba/cups, and the ability to download printer drivers directly from samba to the windows clients via windows print wizard:

This is a howto for implimenting a printserver via samba-3.03-5/cups-1.1.20:

The Following packages will nee to be installed:

* Configuring Samba
1. Configure smb.conf;

------------------ begin --------------------
[root@prtsvr samba]# cat smb.conf
workgroup = aworkgroupname
load printers = yes
browseable = yes
printing = cups
printcap name = cups
#encrypt passwords = yes
#lock directory = /usr/local/samba/var/lock
#interfaces = eth0
security = user
#passdb backend = tdbsam

comment = PS Print Drivers
path = /etc/samba/drivers
guest ok = no
browseable = yes
read only = yes
write list = prtadmin,root

comment = HP LaserJet 5si/5si MX PS
printable = yes
path = /var/spool/samba
public = yes
guest ok = yes
printer admin = prtadmin,root

comment = HP Color LaserJet 8550 PS
printable = yes
path = /var/spool/samba
public = yes
guest ok = yes
printer admin = prtadmin,root

comment = All Printers
path = /var/spool/samba
browseable = no
public = yes
guest ok = yes
writable = no
printable = yes
printer admin = ptradmin,root
------------------- end ---------------------

2. adduser prtadmin
prtadmin:x:500:100:Print Server Admin:/home/prtadmin:/bin/bash

3. addsmb users
smbpasswd -a root
passwd = adecentpasswd

smbpasswd -a prtadmin
passwd = anotherdecentpasswd

* Configuring CUPS
4. Configure cups to do the following;

------------------ begin --------------------
AccessLog /var/log/cups/access_log
ErrorLog /var/log/cups/error_log
LogLevel info
MaxLogSize 0
Printcap /etc/printcap
PrintcapFormat BSD
MaxClients 100

<Location />
Order Deny,Allow
Deny From All
Allow From 192.168.0.*

<Location /admin>
AuthType Basic
AuthClass System
Order Deny,Allow
Deny From All
Allow From 192.168.0.*

<Location />
Order Deny,Allow
Deny From All
Allow From

Browsing On
BrowseProtocols cups
BrowseOrder Deny,Allow
BrowseAllow from @LOCAL
------------------- end ---------------------

5. vi /etc/cups/mime.convs

application/octet-stream application/vnd.cups-raw 0 -

vi /etc/cups/mime.types

6. install drivers in /usr/share/cups/drivers
a. Download and install (on Win) PS driver for windows from
b. Extract the Following via the Windows "Find files and folders" utility
c. scp these files to /usr/share/cups/drivers on the print server

7. install printer ppt:
download approprete ppt file from
cp them into /usr/share/cups/model/


Find one from pre-existing printer on Windows. (find for *.PPD (this is prob better))

8. restart smb & cups:
/etc/init.d/cups stop
/etc/init.d/smb stop
/etc/init.d/smb start
/etc/init.d/cups start

9. add the printers:
download $printer.ppt to /usr/share/cups/model/$printer.ppd (see step 7.)
add smb.conf printer def
/etc/init.d/smb restart
lpadmin -p $smbptrname -D "printer description" -E -v socket:// -m $printer.ppd
cupsaddsmb -H -U root -h localhost -v $smbptrname
give above smb root passwd

9.5. Configure cups-lpd to run out of xinet.d for printing like `lpr -P doc /etc/hosts`:
a. vi /etc/xinet.d/cups-lpd
b. change "disable = yes" to no
c. reboot

10. Add printer to Windows:
a. start -> search -> for files or folders...
b. "Search for other items:" Computers
c. Computer Name: prtsvr
d. select "ptrsvr"
e. right click and "connect" any printer


(prefered) Add printer to windows via APW:
a. start -> settings -> Printers...
b. Add Printer Wizard
c. Next
d. Network Printer
e. "Type the Printer Name" = \\prtsvr\printername


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
CUPS over SMB only printing one copy MikeBest Linux - Software 8 05-21-2010 03:08 AM
printing to remote cups server m00t00 Linux - General 3 01-22-2006 10:34 PM
Printing to FreeBSD print server running cups - odd problem Builder *BSD 6 03-18-2005 09:38 AM
Configuring CUPS printing through router w/ print server AIMath Linux - Networking 6 08-30-2004 11:51 PM
Cups and smb printing with RH 7.3 Sylhouette Linux - Software 0 05-13-2002 12:28 PM

All times are GMT -5. The time now is 01:38 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration