This is the personal website of John Watson: father, software developer, artist, guitar player. Follow me on Mastodon or Twitter or Twitch or itch.io or GitHub.

Printing from Linux to a Windows XP shared printer

After upgrading my daughter’s computer to Mandrake 10 official, I found that I could not print. No matter what I did, I always got the NT_STATUS_ACCESS_DENIED error message even though smbclient could see the shared printer (you can see the logs by running tail -f /var/log/messages /var/log/cups/error_log). The problem is that the configuration utility either creates the path incorrectly or Samba is interpreting it wrong. The workgroup ends up being in the wrong place in the URI. The solution is to enter a printer URI manually like this:

smb://workgroup/user:password@server/printer

Here’s mine using the guest account with no password:

smb://fdnet/guest@desktop/canons520

Or you can use the printer configuration utility and leave the workgroup field blank and instead put workgroup/user in the username field.

Comments

  1. Tim on 2004-11-22 18:14:00 wrote: Thank You! I was having the same problem and have been wrestling with this off and on for a week. I just found you post and bingo, works like a champ. Thanks again.

  2. Henry Andersen on 2004-11-24 16:25:59 wrote: Thanks for the excellent work-around!

  3. Lewis Witt on 2004-11-28 14:37:18 wrote: After working at this for a few days, your solution is more than a little appreciated. Thank you.

  4. Ernie on 2004-12-06 21:02:24 wrote: Dude! You rock! I was futzing aroudn with this for hours before I found your fix!

  5. Josh on 2004-12-31 14:53:18 wrote: Thanks a bunch! I had the same problem with SuSE 9.1, and the only way for it to work was to creat the guest account on my XP machine, and then enter the info as you described for a guest. Silly, but it works!

  6. Matt on 2005-11-26 12:17:00 wrote: Excellent info! Was struggling with this problem and all I had to do was enter ‘guest’ as user and ‘desktop’ as password! Thank you!

  7. Mladen Perisic on 2005-12-16 09:45:51 wrote: Hi! This solution is the best I get for free until now… But, it does not work good :( ! I have HP PSC 1315 printer. It is supported by the HPLIP drivers. I installed the drivers as mentioned in the documentation on the web. I added the printer like this: Started YaST (I’m using SUSE Linux 10.0)>Hardware>Printer. As type of connection I checked Other>URI and, as URI I entered this: smb://workgroup/guest@crni/printer (guest is the name of Windows XP Pro account, turned on; crni is the name of computer and printer is the shared name of HP PSC 1315) Testing the connection worked, but testing the print sample does not work in some way. This is the problem, after trying to print sample, the printer does initialise and just before it start to load the paper, nothing happens… The LED is blinking (it means that the printer is printing or processing document). Windows XP Pro Printer queue display:Document name:Remote Downlevel Document; Owner is Guest; Status is Printing; size is 64KB/2,32MB. I can not even delete the print job (it can not do it)… I think that the problem is in the driver or something becouse it process only 64KB of 2.32MB. I do not know where’s the problem. Anyone know how to resolve this problem?

  8. Richard Snow on 2006-01-12 13:58:17 wrote: I would appreciate any info on this too. I have a psc1410v, the printer starts but the light just keeps on blinking. I’m using Suse 10.0 and XP Pro.

  9. 虚拟主机 on 2006-06-29 00:24:20 wrote: After working at this for a few days, your solution is more than a little appreciated. Thank you

  10. anonymous on 2006-10-11 01:14:00 wrote: I have an HP PSC 1315 shared out of an xp machine on dapper drake all that’s needed is hplip-ppds, cups and samba I ended up fixing it by disabling bi-directional support on the XP machine, set it up through samba/gnome-cups-admin and you’re good to go!

  11. Shaun Bradley on 2006-10-26 01:10:41 wrote: Excellent, this worked as soon as I tried it. thankyou very much, now happily printing to a shared hp laserjet 4 which I originally thought was connected to an XP box, but have since realised its SAMBA hehe. thanks again

  12. Printer Review on 2006-12-09 17:40:31 wrote: Super just got this working for SuSE, simple when you know how I guess. Thanks for the tip. Jim