Printing to a windows shared printer using Samba
I'm trying to print to a shared printer on my windows XP box using Samba. I just installed Slackware 10, and I don't know how to get it to work.
Here is what I did. First I checked to see what the XP box was sharing using the command: $ smbclient -L SONY It showed me that the printer I wish to print to was indeed shared Sharename Type Comment --------- ---- ------- HPDeskJe Printer HP DeskJet 820Cse so then I typed: lpadmin -p SONYPRINTER -v smb://SONY/HPDeskJe -P /root/HP-DeskJet 820C-pnm2ppa.ppd no problem there... then I typed: enable SONYPRINTER to which the prompt displayed: -su: enable: SONYPRINTER: not a shell builtin This doesn't seem right to me and this is probably why it doesn't work. next I typed: accept SONYPRINTER (no problem here either) My directions also said to type the following which also went without a problem: accept SONYPRINTER and after that it is supposed to print with a command such as lp ./doc.txt But it doesn't print instead it outputs to the shell: Status Information, attempt 1 of 3: sending job 'root@localhost+561' to SONYPRINTER@localhost connecting to 'localhost', attempt 1 cannot open connection to localhost - No such file or directory Make sure the remote host supports the LPD protocol Waiting 10 seconds before retry Thank you... |
I could be wrong but I don't think Linux can reliably print to Windows-shared printers. You need to hook up the printer to your Linux box, which can provide printing services to Windows clients. ("Make sure the remote host supports the LPD protocol" should be a good hint)
|
I WAS wrong. Install "Print Services for Unix" in "Optional Networking Components" on the windows box to enable printing from Linux to a Windows shared printer.
|
I know when I did this, I used cups to print, and it worked fine. Install the cups package and goto localhost:631 and configure it and see what you get.
IIRC lpr-cups was the command to print with that I had to switch to since I didnt have lpr linked to cups. |
I found this topic via google search. I see that it was resolved five years ago, but I felt it necessary to clarify something from the original post:
Quote:
Use 'which' or 'whereis' to find the path to the cups 'enable' command then execute it, for example: Code:
# which enable |
All times are GMT -5. The time now is 01:55 PM. |