Click to See Complete Forum and Search --> : Printing from Win clients to Linux server
FrogBear70
07-09-2003, 12:28 PM
Hello,
I have a small problem with Windows clients printing to an HP Laserjet 5. I've setup Samba as a PDC to the windows clients, which they use for file and print sharing. What happens is when they try to print large jobs to the printer shared off the Linux server the job takes forever. When its first submitted the printer says processing job but after a page or two it will stop and say processing job again. It will go on and on like that pausing in between every page or two.
What I'm wondering does the problem lie with the Linux drivers or the Windows clients. The workstations are WinXP and the Linux server is RH9. The driver for the LJ5 is hpijs, and when I install the printer on the workstations it says that the wrong driver is loaded and then I load the windows driver from the list. I figured that part would be normal since I'm using two different OS's and all.
Another question is are other people printing in this fashion in a production environment? I apologize for the long windedness but thanks in advance.
If you are using printcap in your samba config you should setup a RAW print queue in /etc/printcap similiar to this
LJ5:\
:lp=/dev/lp1:\
:rp=raw:\
:mx#0:\
:sh:\
:sd=/usr/spool/lpd/LJ5:
Then Share LJ5 in Samba. The windows drivers will be passed thru linux directly to the printer.
you are better off to go into Add/Remove Programs on the Windows boxes and add in UNIX Printing Support.
then creata a Unix Printer Port on the Windows boxes and point them to the name or ip and queue name on the linux server.
Printing to SAMBA printers is buggy, imho.
I didn't know you could add a unix printer port to windows, that's interesting but I have to disagree with the buggy statement...
One of linux / unix major drawbacks is lack of printing support. Many printers are not supported at all and you have to use generic drivers.
I have 2 networked printers that I print thru samba to raw queues and have never had a problem. Linux acts a spooler which is great. I've printed 300+ page docs w/o tying up my windows client thru my brother printer (no linux drivers, must use laserjet). Samba is just a vehicle to share the queue, it don't think it manipulates the data at all.
I also have no problems with my other printer, an hp952c inkjet.
FrogBear70
07-09-2003, 04:44 PM
I see that's probably my problem, I didn't set up the raw queue. I used printconf to install the printer on the Linux server. Then shared the /etc/printcap through Samba.
I'll try the raw print queue. Thanks a lot for your reply.
FrogBear70
07-09-2003, 09:17 PM
I'm now having a slight problem setting up my /etc/printcap. This is what I've been playing with.
#HP LaserJet 4
hplj4:\
:mx#0:\
:sh:\
:sf:\
:sd=/var/spool/lpd/hplj4:\
:rp=raw:\
:rm=192.168.1.51:
The printer has a Jetdirect card in it and it's not attached directly to the server. So I assume the lp= line won't work. Is there something else I need to add?
When I do a lpq it says unable to contact server. The connection to the Jetdirect is good I can ping and telnet to it, but I think that the printcap is setup wrong.
Originally posted by TomC
I didn't know you could add a unix printer port to windows, that's interesting but I have to disagree with the buggy statement...
One of linux / unix major drawbacks is lack of printing support. Many printers are not supported at all and you have to use generic drivers.
I have 2 networked printers that I print thru samba to raw queues and have never had a problem. Linux acts a spooler which is great. I've printed 300+ page docs w/o tying up my windows client thru my brother printer (no linux drivers, must use laserjet). Samba is just a vehicle to share the queue, it don't think it manipulates the data at all.
I also have no problems with my other printer, an hp952c inkjet.
it actually uses the wndows drivers when you do it the UNIX print service for Windows way. i've had samba printing problems in the past to that is why i shy away from it.
it was recommened in a "Linux Magazine" article this year - I forget the month though.
cowanrl
07-09-2003, 10:04 PM
I have an HP 890C attached to a D-Link print server. I also have it set up for a raw print queue so my Windows computers can print to it. I'm running Red Hat 7.2 on this machine. Here's the section from my /etc/printcap file for it:
HP890C:\
:sh:\
:ml=0:\
:mx=0:\
:sd=/var/spool/lpd/HP890C:\
:af=/var/spool/lpd/HP890C/HP890C.acct:\
:rm=10.10.1.15:\
:rp=PS-DLINK-P2:
As long as I set up raw print queues on my Linux machine for the Windows computers, I've never had any problem using them from Windows via Samba. It's usually very fast.
I use a printserver too, I don't know if the jetdirect has an IP of its own. Try the printcap "cowanrl" has for his d-link.
This is mine:
laser|Brother720
:rw
:sh
:rm=laser
:rp=lpt1
:sd=/var/spool/lpd/laser
:fx=flp
"laser" is defined in my hosts file.
:rm=laser could be :rm=192.168.0.2 or whatever the jetdirects IP is.
FrogBear70
07-10-2003, 08:43 AM
Thanks everyone for your posts, I really appreciate the help. I'm finally printing fine and everything seems to be going well. I think I had a couple more problems then I first realized.
I was trying to use CUPS and LPD. They didn't seem to want to play nice on the same server. So I removed cups and went with lpd and added an entry to my hosts file translating raw to my printers IP. Everything seems to be working fine. Thanks again for your posts and patience.