Visit Jeremy's Blog.
Go Back > Forums > Linux Forums > Linux - Software
User Name
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.


  Search this Thread
Old 08-28-2009, 09:29 AM   #1
Registered: Jul 2007
Location: WI, USA
Distribution: Debian, Lenny
Posts: 111

Rep: Reputation: 19
Printing from my Debian box to a printer on Windows XP

I tried Google, but I'm finding little useful information. I found a walkthrough from 2006 (, but I'm hoping there's simpler ways to do this now.

As stated in the title, I'm trying to print across the network from my Debian Lenny box to a printer connected to my mother's XP box. A friend told me I needed to use CUPS to do that, but I don't have any experience with printers in Linux in general yet. I'm expecting this project to have a steep learning curve, but that's what makes Linux all worthwhile. Even if you can just give me a good link to look at, it would be much appreciated.

As a side note: I have little idea how a printer/spooler works, but would it be possible to ssh a postscript file to, say, a print spooler directory on Windows? Even if I could just make some .ps files and send 'em over, that would work fine for my purposes. I don't currently require full compatibility.
Old 08-28-2009, 03:16 PM   #2
Senior Member
Registered: Jan 2005
Location: Melbourne, Australia
Distribution: Debian Buster (Fluxbox WM)
Posts: 1,390
Blog Entries: 52

Rep: Reputation: 359Reputation: 359Reputation: 359Reputation: 359
The steps are roughly these:

1. Have a look for the windows printer shares (for this you will need the smbclient installed). Even if you know the machine name of the printer already, this step will make sure you have samba client access working.
smbclient -L <WinXP box IP address>
2. Use the CUPS GUI (for this you will need cupsys and cupsys-client installed). Open a browser, and load the address "http://localhost:631/", since CUPS provides a webpage interface on port 631.

3. Add a printer, give it a name (no spaces), a location, and a description. You will need the root password to do this.

4. Set the device type to "Windows Printer via SAMBA".

5. Set the URI which includes the name that was listed earlier by smbclient, for example something like "smb://". If the printer is passworded, you would use something like "smb://username:password@".

6. Set up the make and manufacturer information (so that it knows how to format jobs for this printer). If you can't find your printer, you might be able to use a postscript driver instead. Some printer drivers are in separate packages (eg hp-ppd).

7. You can now test the printer.

This can be done in other ways (for example, a Windows server can provide support for TCP/IP based printing by adding in the "Print Services for Unix" network component, which means you can use the 'lpd:' protocol instead of 'smb:').

If the windows box does not have a fixed ip address, you can set up winbind (install winbind, and add "wins" to the end of the hosts line in "/etc/nsswitch.conf"). This will enable you to use the server name rather than IP address.

Last edited by neonsignal; 08-28-2009 at 03:29 PM.


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
Re: Printing to Windows Printer from Debian Computer matsyuf Linux - Hardware 8 03-17-2008 07:29 PM
printing to a debian printer from windows xp home utanja Linux - Networking 9 11-14-2005 12:17 AM
Linx Laptop printing with Windows box printer --Help please 1kyle SUSE / openSUSE 1 09-16-2005 07:04 PM
Printing from RedHat box to Windows printer... notoneword Linux - Networking 1 11-29-2002 07:52 PM
Trouble printing from Win2K to printer on linux box cboyd Linux - Networking 0 03-03-2002 05:41 PM > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 01:05 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
Open Source Consulting | Domain Registration