Bugzilla will be upgraded to version 5.0 on a still to be determined date in the near future. The original upgrade date has been delayed.
Bug 104136 - SAMBA client working, printer configuration not working
SAMBA client working, printer configuration not working
Product: Red Hat Enterprise Linux 3
Classification: Red Hat
Component: samba (Show other bugs)
i686 Linux
medium Severity medium
: ---
: ---
Assigned To: Jay Fenlason
: 121290 (view as bug list)
Depends On:
Blocks: 132991
  Show dependency treegraph
Reported: 2003-09-10 09:58 EDT by Rick Graves
Modified: 2014-08-31 19:25 EDT (History)
12 users (show)

See Also:
Fixed In Version: samba-3.0.9-1.3E.1
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2005-03-01 11:46:20 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
CUPS error log file as requested (1.46 KB, text/plain)
2003-10-02 07:38 EDT, Rick Graves
no flags Details

External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2003:276 normal SHIPPED_LIVE Updated printer configuration tool fixes SMB problems 2003-09-17 00:00:00 EDT

  None (edit)
Description Rick Graves 2003-09-10 09:58:37 EDT
Description of problem:

Tim Waugh at RedHat suggested that I post the issue in bugzilla.

I want to print to an hp LaserJet 1200 on a Windows XP box.  

I can print calling the SAMBA client directly from a terminal window.  That 
works OK.

When I try to install the printer using the printer configuration, I only get 
the message:

Unable to connect to SAMBA host, will retry in 60 seconds...

So I cannot print in X/KDE (except from a terminal window by calling the SAMBA 
client directly).  

Version-Release number of selected component (if applicable):

How reproducible:
Problem occurs all the time continuously.

Steps to Reproduce:
1. Try to install the LaserJet 1200 (connected to a Windows XP box) using the 
printer configuration utility.
Actual results:
Printer configuration always says only this:

Unable to connect to SAMBA host, will retry in 60 seconds... 

Expected results:
Printer should install and be ready to print.

Additional info:
output of printconf-tui --Xexport

  <?xml version="1.0" ?> 
- <adm_context VERSION="0">
- <id NAME="local" SERIAL="1063073839">
  <null /> 
  <null /> 
- <datatree>
- <printconf TYPE="LIST">
- <print_queues TYPE="LIST">
  <alias_list ANONYMOUS="TRUE" TYPE="LIST" /> 
  <queue_description TYPE="STRING" VALUE="hp LaserJet 1200 on HeadOffice" /> 
- <lpoptions TYPE="LIST">
  <page-bottom TYPE="STRING" VALUE="36" /> 
  <cpi TYPE="STRING" VALUE="12" /> 
  <lpi TYPE="STRING" VALUE="7" /> 
  <scaling TYPE="STRING" VALUE="100" /> 
  <page-right TYPE="STRING" VALUE="36" /> 
  <page-left TYPE="STRING" VALUE="36" /> 
  <wrap TYPE="STRING" VALUE="true" /> 
  <page-top TYPE="STRING" VALUE="36" /> 
  <queue_type TYPE="STRING" VALUE="SMB" /> 
- <queue_data TYPE="LIST">
  <smb_share TYPE="STRING" VALUE="//HEADOFFICE/hpLJ1200" /> 
  <smb_ip TYPE="STRING" VALUE="" /> 
  <smb_workgroup TYPE="STRING" VALUE="ADVANCED" /> 
  <smb_user TYPE="STRING" VALUE="" /> 
  <smb_password TYPE="STRING" VALUE="" /> 
  <smb_translate TYPE="BOOL" VALUE="FALSE" /> 
- <filter_data TYPE="LIST">
- <flags TYPE="LIST">
  <assume_data_is_text TYPE="BOOL" VALUE="FALSE" /> 
  <rerender_Postscript TYPE="BOOL" VALUE="FALSE" /> 
  <convert_text_to_Postscript TYPE="BOOL" VALUE="TRUE" /> 
  <printer_id TYPE="STRING" VALUE="Generic-PostScript_Printer" /> 
  <gs_driver TYPE="STRING" VALUE="Postscript" /> 
  <foomatic_defaults ANONYMOUS="TRUE" TYPE="LIST" /> 
  <filter_type TYPE="STRING" VALUE="MAGICFILTER" /> 
Comment 1 Tim Waugh 2003-09-10 10:08:53 EDT
What does this say?:

smbclient //HEADOFFICE/hpLJ1200 -W ADVANCED -N -P -c quit
Comment 2 Rick Graves 2003-09-10 10:34:23 EDT

You asked, 

> What does this say?:

> smbclient //HEADOFFICE/hpLJ1200 -W ADVANCED -N -P -c quit

I got this command from my book "RedHat Linux 8 Bible".  That is the command I 
typed into the terminal window to test whether the SAMBA client is working.  

The printer is hpLJ1200, and HEADOFFICE is the host name (the name of the 
computer to which the hp LaserJet 1200 is attached). 
Hence //HEADOFFICE/hpLJ1200/ 

ADVANCED is the workgroup name for the Windows local area network.  

I will have to look up the other parameters tomorrow Hong Kong time (it is now 
10:30 PM here, and my Linux books for this are all at the office).  I think 
the name of the file to print should be on the command line, and is missing.  
From my recollection, I am not sure the line you asked about has the correct 

I will get back to you in 10 hours or so.  Thanks.
Comment 3 Rick Graves 2003-09-10 10:44:20 EDT

I take it back, the command I typed to the terminal window is this:

smbclient "\\\\headoffice\\hpLJ1200" -N -c "print tpr.txt"

(I looked up my August post in LinuxPrinting.org.)

You asked about:

smbclient //HEADOFFICE/hpLJ1200 -W ADVANCED -N -P -c quit

Where did this line come from?

So maybe I do not understand your question.

Thanks ... 
Comment 4 Tim Waugh 2003-09-10 10:47:33 EDT
I just need to see the output of it.  Thanks.
Comment 5 Rick Graves 2003-09-10 20:49:43 EDT

Here is the output of that command:

added interface ip= bcast= nmask=
Got a positive name query response from ( )
Domain=[ADVANCED] OS=[Windows 5.1] Server=[Windows 2000 LAN Manager]


Comment 6 Tim Waugh 2003-09-11 07:05:14 EDT
In /etc/cups/printers.conf, what does the DeviceURI line say?
Comment 7 Rick Graves 2003-09-11 07:18:06 EDT

I found this:

# DeviceURI: the device URI for this printer.

#DeviceURI parallel:/dev/plp
#DeviceURI serial:/dev/ttyd1?baud=38400+size=8+parity=none+flow=soft
#DeviceURI scsi:/dev/scsi/sc1d6l0
#DeviceURI socket://hostname:port
#DeviceURI tftp://hostname/path
#DeviceURI ftp://hostname/path
#DeviceURI http://hostname[:port]/path
#DeviceURI ipp://hostname/path
#DeviceURI smb://hostname/printer



Comment 8 Tim Waugh 2003-09-11 07:24:31 EDT
Not really. :-)  I need to see the one that doesn't start with '#'.
Comment 9 Rick Graves 2003-09-11 08:55:39 EDT

I will have to look again tomorrow (I am now at the flat). 

I assumed that all the lines with DeviceURI would be together, so I did not 
check after the block that I sent to you.  The lines that follow immediately 
after the block do not contain DeviceURI.  Because I assumed that all the 
lines with DeviceURI would be together, I assumed that there were no lines 
without the #, and that was the answer.  

Enough explanation -- I will look again tomorrow (Friday) morning (Thursday 
evening North Carolina time). 

Comment 10 Tim Waugh 2003-09-11 08:58:33 EDT
Okay.  I would also like to see the output of:

/usr/sbin/alternatives --display print
Comment 11 Rick Graves 2003-09-11 21:26:54 EDT
Good morning,

here is the line from printers.conf


here is the output of /usr/sbin/alternatives --display print

print - status is auto.
 link currently points to /usr/bin/lpr.cups
/usr/bin/lpr.cups - priority 40
 slave print-cancel: /usr/bin/cancel.cups
 slave print-lp: /usr/bin/lp.cups
 slave print-lpq: /usr/bin/lpq.cups
 slave print-lprm: /usr/bin/lprm.cups
 slave print-lpstat: /usr/bin/lpstat.cups
 slave print-lpc: /usr/sbin/lpc.cups
 slave print-cancelman: /usr/share/man/man1/cancel-cups.1.gz
 slave print-lpman: /usr/share/man/man1/lp-cups.1.gz
 slave print-lpqman: /usr/share/man/man1/lpq-cups.1.gz
 slave print-lprman: /usr/share/man/man1/lpr-cups.1.gz
 slave print-lprmman: /usr/share/man/man1/lprm-cups.1.gz
 slave print-lpstatman: /usr/share/man/man1/lpstat-cups.1.gz
 slave print-lpcman: /usr/share/man/man8/lpc-cups.8.gz
/usr/bin/lpr.LPRng - priority 30
 slave print-cancel: /usr/bin/cancel.LPRng
 slave print-lp: /usr/bin/lp.LPRng
 slave print-lpq: /usr/bin/lpq.LPRng
 slave print-lprm: /usr/bin/lprm.LPRng
 slave print-lpstat: /usr/bin/lpstat.LPRng
 slave print-lpc: /usr/sbin/lpc.LPRng
 slave print-cancelman: /usr/share/man/man1/cancel-LPRng.1.gz
 slave print-lpman: /usr/share/man/man1/lp-LPRng.1.gz
 slave print-lpqman: /usr/share/man/man1/lpq-LPRng.1.gz
 slave print-lprman: /usr/share/man/man1/lpr-LPRng.1.gz
 slave print-lprmman: /usr/share/man/man1/lprm-LPRng.1.gz
 slave print-lpstatman: /usr/share/man/man1/lpstat-LPRng.1.gz
 slave print-lpcman: /usr/share/man/man8/lpc-LPRng.8.gz
Current `best' version is /usr/bin/lpr.cups.

What next?


Comment 12 Tim Waugh 2003-09-12 06:40:48 EDT
Please fetch these packages:


and install them using RPM:

rpm -Fvh redhat-config-printer-**

Does that fix the problem?
Comment 13 Rick Graves 2003-09-12 20:55:31 EDT

I downloaded and installed the packages as you suggested -- they installed OK.

When I go into the printer configuration, I still only get the message:

Unable to connect to SAMBA host, will retry in 60 seconds...


What next?


Comment 14 Tim Waugh 2003-09-15 08:22:01 EDT
Okay, let's take another look at the DeviceURI line.  It should be different
this time.  You can get it using this (as root):

grep ^DeviceURI /etc/cups/printers.conf
Comment 15 Rick Graves 2003-09-15 21:06:28 EDT

Thanks for the grep command.  It says this:


Watch out for Isabelle!  Its coming your way.

Comment 16 Tim Waugh 2003-09-16 04:39:35 EDT
Hmm, well that's the same, and still wrong.

What does '/usr/sbin/printconf-backend --force-rebuild' say, when you run it as
Comment 17 Rick Graves 2003-09-16 04:52:24 EDT

> What does '/usr/sbin/printconf-backend --force-rebuild' say, when you run it as 

It did not say anything.  The hard drive was active for several seconds, and
then it stopped.  There was no text output to the terminal window.


Comment 18 Tim Waugh 2003-09-16 04:54:44 EDT
Hmm.  Try:

grep ^DeviceURI /etc/cups/printers.conf


Also, what does 'rpm -q redhat-config-printer' and 'rpm -V
redhat-config-printer' say?
Comment 19 Rick Graves 2003-09-16 20:29:45 EDT

Here are the outputs of the three commands:



SM5....T c /etc/alchemist/namespace/printconf/local.adl

I hope this is helpful.

Comment 20 Tim Waugh 2003-09-17 04:56:10 EDT
An errata has been issued which should help the problem described in this bug report. 
This report is therefore being closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files, please follow the link below. You may reopen 
this bug report if the solution does not work for you.

Comment 21 Rick Graves 2003-09-18 22:36:30 EDT

I filed a bug report against anaconda on the same computer, Bug 104686.

I hope everyone is hunkered down, and Isabel did not hit you and RedHat too hard.

Comment 22 Rick Graves 2003-09-18 22:37:30 EDT

Is this closed?  

Comment 23 Tim Waugh 2003-09-19 04:18:27 EDT
Yes -- reopen if printing is still not working.  The Device URI is now correct
and so at least one bug has been fixed here.
Comment 24 Rick Graves 2003-09-19 21:47:10 EDT

Sorry to be a pest, but I still cannot print from applications in the GUI

My goal is to move the whole office over to RedHat Linux, but this is obviously
a stumbling block.  

If you can bear it, I would appreciate your help to continue troubleshooting
this issue.


Comment 25 Rick Graves 2003-09-21 00:15:02 EDT

>>My goal is to move the whole office over to RedHat Linux, but this is 
obviously a stumbling block.  

It occured to me that my statement might not make sense.  

I have a step by step plan.  The person who "owns" the station where hp 
LaserJet 1200 is located will probably be the last to convert, or may never 
convert.  In the meantime, the Linux stations need to print to the hp printer.

The bottom line:  I would appreciate your help.


Comment 26 Tim Waugh 2003-09-29 03:22:19 EDT
Please set the LogLevel to Debug2 in the /etc/cups/cupsd.conf file, and restart
cups.  Then, note the time as reported by 'date' and submit another print job.

After a minute or so, take a copy of /var/log/cups/error_log and remove the
lines logged before the job was submitted.  Then attach it to this bug report,
and I'll take a look.

Comment 27 Rick Graves 2003-10-02 07:38:03 EDT
Created attachment 94875 [details]
CUPS error log file as requested


The file is attached, I hope it is helpful.


Comment 28 Tim Waugh 2003-10-02 07:58:50 EDT
And what does this say?:

smbspool smb://ADVANCED/HEADOFFICE/hpLJ1200 1 user title 1 '' /etc/crontab

It should try to print /etc/crontab.

I'd also like to see what this command does:

smbclient //HEADOFFICE/hpLJ1200 -W ADVANCED -N -c quit
Comment 29 Rick Graves 2003-10-03 06:03:35 EDT

[rick@magicpro rick]$ smbspool smb://ADVANCED/HEADOFFICE/hpLJ1200 1 user title 1
'' /etc/crontab
ERROR: Unable to connect to SAMBA host, will retry in 60 seconds...

[rick@magicpro rick]$ smbclient //HEADOFFICE/hpLJ1200 -W ADVANCED -N -c quit
added interface ip= bcast= nmask=
Got a positive name query response from ( )
Domain=[ADVANCED] OS=[Windows 5.1] Server=[Windows 2000 LAN Manager]
[rick@magicpro rick]$

Does this help?


Comment 30 Tim Waugh 2003-10-03 06:11:47 EDT
That *has* to be a samba bug.
Comment 31 Michael Kazanov 2003-10-03 16:06:13 EDT
Dear Tim and Rick,

I am experiencing the same problems. I installed RH 9 recently and installed all
updates. When I try to connect to WinXP shared printer (HP 2000D) it gives me
the same error message. I did one additional step -> I disabled "EASY FILE
SHARING" on WinXP as it was suggested on other IT Forum. However, it did not
help. So - there are no updates available and SMB printer sharing does not work
still. I am not very experienced in RH Linux - as a project I installed RH 9 to
make our people comfortable with it and I am planning in future to increase
Linux presence in our organization, but such problems cause difficulties for my
intend. I would be glad if we could clear this out. 
Comment 32 Tim Waugh 2003-10-03 16:48:08 EDT
Michael: are you sure this is the same problem?  Can you let us know the
DeviceURI from the /etc/cups/printers.conf file?  Use:

grep ^DeviceURI /etc/cups/printers.conf

Rick: can you try this please?:

smbspool smb://HEADOFFICE/hpLJ1200 1 user title 1 '' /etc/crontab

Comment 33 Michael Kazanov 2003-10-04 21:18:20 EDT
I made several experiments. I have Win2k Domain called STT, Sun Solaris Server
called assist workgroup STATISTICS, workstation zuo2 running WinXP, which has HP
printer attached locally. Also, we have several network printers and there are
shares for these printers on one of Win2k Domain Controllers and on Sun Solaris
machine as well.

I used "Printing" GUI

1) I tried to map network printer shared from Sun Solaris machine using
Networked Windows (SMB). When I clicked on ASSIST (SUN Machine in GUI I saw all
shared printers and I was able to map them. Here is URI:

DeviceURI smb://admin:mypassword@STATISTICS/ASSIST/a410-pr

It works fine.

2) I tried to map network printer shared from Win2k DC (called stt-dc-2) machine
using Networked Windows (SMB). I did not see it in GUI unless I entered info in
"Specify" menu. After that it appeared in GUI and I could select it.

DeviceURI smb://admin:mypassword@STT/stt-dc-2/a410-pr

Surprisingly enough, but it works fine today - no "Unable to connect to SAMBA
host, will retry in 60 seconds... " message any more - ??

AFTER that I tried to do the same procedure, but use not "admin" account, which
also presents on Sun Machine and has smbpasswd set up, but another account,
which is present only on Win2k Domain 

DeviceURI smb://adm:mypass@STT/stt-dc-2/a410-pr
DeviceURI smb://admin:mypassword@STT/stt-dc-2/a410-pr

It also worked.

Only when I used IP addresses instead of NetBios names, it failed with "Unable
to connect to SAMBA..." message.

Anyway, it is strange since I just repeated my previos steps and it works now,
but did not work before.. ??

3) I tried to map network printer shared from WinXP workstation (called zuo2)
machine using Networked Windows (SMB). I did not see it in GUI unless I entered
info in "Specify" menu. After that share \\zuo2\hpzuo appeared in GUI, but when
I tried to press "Forward" instead invitation to enter Authorization Info was
showed and it did not accept anything that I wrote. Now, instead of getting
"Unable to connect to SAMBA..." message, I cannot connect to that printer ??

Is that problem on Network with NetBios packets? Or something in RH ?

Comment 34 Michael Kazanov 2003-10-05 19:13:37 EDT
Today I tried to map printer connected to XP machine (3 case above).

It did not work with credentials of local administrator of XP machine (kept
asking to re-enter authentification credentials in GUI), however it worked with
my account information - this account is one on DC and included in local
administrators group of XP computer. Also the server in GUI (which performs
authentification) was specified to be local computer (not DC). 

DeviceURI smb://kazanov:mypass@STT/zuo2/hpzuo
DeviceURI smb://adm:mypass@STT/stt-dc-2/a410-pr
DeviceURI smb://admin:mypassword@STT/stt-dc-2/a410-pr

AFTER THAT I repeated the same procedure with my account again and I could not
succeed (kept asking to re-enter authentification credentials in GUI). 
I tried to map the same printer (attached to XP) machine with different accounts
using different authen. credentials, but it either asks me to re-enter this info
or shows at the bottom line printer "hpzuo (specified)" and when I click
"Forward" it asks me to re-enter authen. credentials...

I closed "Printing" GUI and opened it again. Then I repeated all above steps
again. The same picture - only after several tries it accepted authentification
credentials and printed test page fine.

DeviceURI smb://admin:mypassword@STT/zuo2/hpzuo
DeviceURI smb://kazanov:mypass@STT/zuo2/hpzuo
DeviceURI smb://adm:mypass@STT/stt-dc-2/a410-pr
DeviceURI smb://admin:mypassword@STT/stt-dc-2/a410-pr


So there is some inconsistency - the same authentification credentials sometimes
work sometimes not (they were always entered very accurately!!!). Does it look
like problem with "Printing" GUI ?
Comment 35 Rick Graves 2003-10-06 00:38:20 EDT

[root@magicpro root]# grep ^DeviceURI /etc/cups/printers.conf
[root@magicpro root]# smbspool smb://HEADOFFICE/hpLJ1200 1 user title 1 ''
ERROR: Unable to connect to SAMBA host, will retry in 60 seconds...

I was hoping to get some company from Michael, but maybe his problem fixed itself.


Comment 36 Gary Reeves 2003-10-06 14:37:56 EDT
I'm running RH 9 with all the latest patches on a home network sharing a cable
modem over a NetGear cable router. I can always print the CUPS Printer Test Page
on the first try to a Windows 2000 Pro station with a share on an HP OfficeJet
600.  Subsequent prints hang and Windows eventually generates an error about a
DOT 4 port.  If I reset the printer, it spits out the first 1/2 inch or so of
the hung second test page. I can then send another test page which prints OK,
but it once again hangs on subsequent print jobs.

Printing from kedit always hangs, even after a printer reset.  Test page thru
command center prints OK on first try, then hangs as before.

It's bugs like this that cause most I T Managers in legacy Windows environments
to consider Linux as "not quite ready for prime time."  sigh... Guess for now
I'll have to connect a printer direct or run sneakernet.  Any ideas would really
be appreciated.  I'm a Windows person in grad school and don't yet have much
experience with Linux.  Do prefer the g++ C++ compiler a light year beyond the
one in Microsoft Visual Studio, though!
Comment 37 Tim Waugh 2003-10-07 07:42:11 EDT
Gary: that is a different bug altogether.  Please file it as a new bug.  Thanks.
Comment 38 Tim Waugh 2003-10-07 07:46:05 EDT
Jay: this is looking like an smbspool bug to me.  Do you agree?  smbclient is
happy with the parameters from the (correct) URL given to smbspool, but smbspool
Comment 39 Adi Linden 2003-10-24 00:19:29 EDT
Hi Tim and Rick,

I have the identical problem. My wifes XP Home Edition box has an HP 6L attached
to it. I configured the printer using printtool and all it gives me is the
"Unable to connect to SAMBA host, will retry in 60 seconds..." error message no
print output at all. I also want to mention that I had been able to print to the
printer just fine with RedHat 8 and lpd (not cups). The problem didn't appear
until I installed RedHat 9 after a harddisk crash.

I suspect you'll be asking for this:

[root@mobile root]# grep ^DeviceURI /etc/cups/printers.conf
DeviceURI smb://MSHOME/JENN/hp

[root@mobile root]# smbspool smb://MSHOME/JENN/hp 1 user title 1 '' /etc/crontab 
ERROR: Unable to connect to SAMBA host, will retry in 60 seconds...

[root@mobile root]# smbclient //JENN/hp -W ADVANCED -N -c quit
added interface ip= bcast= nmask=
Got a positive name query response from ( )
Domain=[MSHOME] OS=[Windows 5.1] Server=[Windows 2000 LAN Manager]

Anything else I can provide to help? I'd love to be able to print again, soon. I
am saving lot of trees lately, though :)

Comment 41 Rick Graves 2003-10-24 23:30:34 EDT
Hello Adi,

It seemed that I was the only person on the planet with this problem.

It also seems the experts are stumped on this.

As a work around, I have collected several "junk" Pentium I's.  I doing my first
Debian install at this very moment.  I am going to experiment with using a
headless Debian Pentium I as a CUPS print server.  There is a Debian HOWTO that
covers this.  

I also plan on using some of the Pentiums as "roll your own" firewall PC's.  I
am currently reading a book put out by RedHat Press, "RedHat Linux Internet
Server".  One of the early chapters is about setting up a firewall.  The book
admits that even a 486 has enough horsepower to be a firewall for a medium-sized
office.  Here is the irony:  a 486 has enough horsepower to be a firewall, but
not enough to install RedHat in the first place.  

Sorry I cannot give you any other solution.

Comment 42 Stew Schneider 2003-10-25 14:43:46 EDT
I've followed the discussion throughout, and have the same problem on the office
RH 9 box, with a bit of a twist. Here, the office box is connected thru a
LinkSys to my secretary's machine which is running XP Pro and has a Lexmark
Optra T616 attached. I cannot print to it, just as discussed, with the same errors. 

At home, the RH 9 box is connected through a LinkSys to an XP Home Edition box
which has a Lexmark 3200 connected. I can print to that without problem from the
RH box.
Comment 43 Adi Linden 2003-11-14 16:21:06 EST
Yesterday I installed RedHat AS 3.0 on the notebook that has been
experiencing this printing problem. I cannot print with RedHat AS 3.0
with the exactly same symptoms as observered with RedHat 9.0. This is
becoming really frustrating!
Comment 44 Bill Keese 2003-11-19 01:49:35 EST
Hello everyone.  smbspool doesn't seem to prompt for username or
password, so don't you have to specify that in the URI?  I was getting
the same authentication errors from smbspool as people above:

# smbspool smb://SPRO/ntfsrv1/FXAbleMo.2 1 user title 1 '' /etc/motd
failed tcon_X with NT_STATUS_ACCESS_DENIED

And then I inserted the username / password into the URI and it worked

# smbspool smb://bill:myPasswd@SPRO/ntfsrv1/FXAbleMo.2 1 user title 1
'' /etc/motd

As for printing from application (via CUPS), that part isn't working
for me because (apparently) /usr/lib/cups/backend/smb doesn't exist. 
Where do I get that file?
Comment 45 Bill Keese 2003-11-19 02:44:06 EST
Nevermind, found the answer to my previous question:

You need to link /usr/lib/cups/backend/smb to smbspool.  Now I can at
least print text documents.  Postscript isn't working for some reason.
Comment 46 Tim Waugh 2003-11-19 05:12:45 EST
No, that should be done automatically when you install samba-client. 
If not something else is wrong (and a *separate* bug report should be
filed about it).
Comment 47 Tim Waugh 2003-11-19 05:15:39 EST
I really don't think this is to do with passwords in the URI.  See
this trace from comment #39, in which no password or username is
provided or requested for either method, yet only smbclient succeeds:

[root@mobile root]# smbspool smb://MSHOME/JENN/hp 1 user title 1 ''
ERROR: Unable to connect to SAMBA host, will retry in 60 seconds...

[root@mobile root]# smbclient //JENN/hp -W ADVANCED -N -c quit
added interface ip= bcast= nmask=
Got a positive name query response from ( )
Domain=[MSHOME] OS=[Windows 5.1] Server=[Windows 2000 LAN Manager]

Jay, can you please confirm that this is a samba bug?
Comment 48 mathew 2004-04-06 12:01:45 EDT
I have exactly the same problem: smbclient works, smbspool doesn't.

smbclient //server/printer connects and drops me to an smb prompt, and
I can use  print test.txt to print a test file.

smbspool //server/printer 1 user title 1 '' test.txt fails with:

failed tcon_X with NT_STATUS_ACCESS_DENIED
ERROR:  Connection failed with error NT_STATUS_ACCESS_DENIED
ERROR: Unable to connect to SAMBA host, will retry in 60 seconds...

smbclient -L server also works, and lists the printer spools. So it
seems to me that smbspool is fundamentally broken.

Is there any easy way to get cups to use smbclient instead of smbspool
for sending files, as a workaround?

Fedora Core 1, samba-common-3.0.2-7.FC1, samba-client-3.0.2-7.FC1.
Comment 49 mathew 2004-04-06 12:10:28 EDT
I've just tried installing the latest Samba RPMs from
http://us3.samba.org/samba/ftp/bin-pkgs/Fedora/RPMS/i386/core/1/ and
it's still broken in those. So, definitely looks like a Samba problem.
Comment 50 Nick Simicich 2004-04-20 02:17:28 EDT
I think I just submitted a duplicate of this bug against fedora 1 -
See 121290. I apologize, I searched for bugs within bugzilla and
thought I had searched exhaustively - when I googled the bugs showed
up. The workaround I found (which works reliably for me) is to specify
any old userid in the "URL".

That is, if you added the printer from CUPS, go into CUPS and change
the url that defines the printer to


Or if you added the printer from redhat-config-printer go in there and
specify any old userid on the screen where you specify userid.

It does not matter what the userid is, it can be anything.  This
change seems to make smbspool do the right thing.  I was able to
reproduce this from the command line with smbspool, so I really
believe that it is an smbspool issue and not one of links or
alternatives or other stuff.

In other words:

smbspool smb://work/system/queue 1 2 3 4 5 file 

fails and 

smbspool smb://zithead99@work/system/queue 1 2 3 4 5 file 

works, even though there is no such user on any system at my location
on any system, nor has there ever been.  (At least it returns without
hanging. This printer does not do so well on raw text, and test pages
print with the dummy user and fail without them.

I did a number of web searches, and I believe that this is a common
problem, by he way.  I searched on the keywords print and
NT_STATUS_ACCESS_DENIED and saw a lot of people asking this, or
dialogs about it. 

Anyway, I hope this helps.  I am going to add myself to the CC list -
let me know if this workaround works for you.  It looks almost like it
is supposed to be there if you make the userid "guest" :-)
Comment 52 labilabi 2004-05-21 23:43:01 EDT
in printer configuration. change to lower case
//HEADOFFICE/hpLJ1200 to //headoffice/hpLJ1200
Comment 53 labilabi 2004-05-21 23:48:33 EDT
5. Troubleshooting
5.1. Failing To Connect To Windows Printers

When smbspool, the smbclient utility CUPS uses, fails to connect
properly it emits error messages that are humorous but not very
helpful. One such message is Unable to connect to SAMBA host: Success.
Another sign of connection failures is when documents seem to get
stuck on the queue when printing to Windows printers.

View the most recent entries in the CUPS log with the following command:

/usr/bin/tail /var/log/cups/error_log

If you see a message similar to cli_connect() failed... then smbspool
could not find the Windows PC you are trying to connect to. Check the
spelling of the Windows PC's host name. Check that the Windows PC is
turned on and that its network connection is functioning properly.
Make sure you can connect to it using smbclient as shown in Section 3.1.

If you see a message similar to SMB tree connect failed: ERRSRV -
ERRinvnetname then smbclient connected to the Windows PC but could not
connect to the printer you requested. Check the spelling of the shared
printer using smbclient as shown in Section 3.1.
5.2. Other Failures

Other failures include being unable to print to a local printer and
having your print jobs disappear from the queue without being printed.
You may also see vague error messages such as Child process 2384
exited with status 32.

Increase CUPS' logging level to "debug" to see more messages about
what happened before the print job failed.


      Open the main CUPS configuration file /etc/cups/cupsd.conf in a
text editor.

      Change the line that reads "LogLevel warn" to "LogLevel debug".

      Save the configuration file and exit the text editor.

      Restart the CUPS server with the command:

/etc/init.d/cupsys restart

You can follow the CUPS log with the following command:

/usr/bin/tail -f /var/log/cups/error_log

You should see a line that reads Scheduler shutting down due to
SIGTERM. This indicates that the CUPS server was stopped successfully.

Send your print job again and watch for useful debug messages that
appear. One example of a useful debug message is GNU Ghostscript 7.05:
Can't start ijs server 'hpijs'. In this case the solution is to
install the "hpijs" package.

If you cannot determine the cause of the failure, do an Internet
search for key terms in error messages you see; it is likely that
someone has solved your problem before. You may also try upgrading the
packages listed in Section 2.2 to their latest versions. 
Comment 54 Rick Graves 2004-05-24 01:50:24 EDT
Hello labilabi,

When I discovered this problem, I had RedHat 9 installed at the
workstation.  I have since installed Fedora, and I have not bothered
to try to print to the hp LaserJet connected to the Windows PC.  

I have a spare hard drive.  I could reinstall RedHat 9 on the spare
drive, or I could try to connect from Fedora.  Oviously, connecting
from Fedora would be easier.  

I do not mind putting some effort into trying to solve this.

Please let me know.


Comment 55 Nick Simicich 2004-05-25 14:38:30 EDT
I'd be interested in knowing if the workaround I suggested in comment
50 (adding a random userid to the configuration) fixes your problem as
it fixed mine which had the exact same symptoms.

You can test it from the command line using the smbspool commands I
gave - if they work the way I indicated that they work for me then
changing your cups config to add a random userid will probably work.

And you can likely test that from Fedora.
Comment 56 mathew 2004-05-25 21:36:30 EDT
Fixed it for me (mathew).
Comment 57 Rick Graves 2004-05-31 22:02:30 EDT

"Zithead" works for me!  Thanks!!!!  Great job!!!

So if you ask me, this bug can be resolved as workaround-able.  But 
that is not an option in the pull down.  I guess "works for me" is 
close enough. 

This solution will help me take more steps away from that other 
operating system.  


Comment 58 Alan Heartfield 2004-07-30 00:58:58 EDT
I am experiencing the same problem with "unable to connect...6o 
seconds".  Linux is Redhat 9, the printer is an Epson 880, BUT I have 
3 XP boxes.  Two of them work just fine, the 880 installs in less 
than a minute and test pages all print.  The CUPS GUI doesn't even 
ask for a username or password.  The third won't work at all.  CUPS 
GUI asks for a username and password, but will accept none.  If I 
work-around this problem, then the error message.  So it HAS to be 
something in the XP box configuration.  Chasing Samba is a waste of 

Comment 64 Stew Schneider 2004-12-18 15:33:42 EST
I'm now printing successfully to a Lexmark Optra T616 connected to an
XP Pro machine from my FC2 desktop after I installed Samba
3.0.9-1.fc3. I added the Lexmark from the CUPS administration tool at
localhost:631. I included a random user@<workgroup> in the URL. Seems
to work fine, so far. My earlier RH9 system could not access this printer.

Comment 65 Stew Schneider 2004-12-18 15:42:46 EST
Oops! My FC3 desktop, rather.

Comment 66 Stew Schneider 2004-12-18 15:43:56 EST
Oops! My FC3 desktop, rather.

Comment 67 Roland Hammerle 2005-01-04 13:03:51 EST
This is a very interesting bug report. I have been pulling out my hair
today just to get printing with Samba/CUPS working. I do this on
ArchLinux but the problem of the original poster is exactly the same.

1) Experimenting with smbtool

I replaced smbtool with a small shell script that prints out some
information (environment, arguments, etc) and then runs smbtool. Even
though using the original smbtool never worked, running it from within
the shell script works! The DEVICE_URI is properly set as an
environment variable - at least from what I see in my shell script.
Once I switch back to the original smbtool, printing does not work.

2) Experimenting with DEVICE_URI

Guest account is not enabled. Roland is my user account on XP.

smb://WORKGROUP/ -> nope
smb://Guest@WORKGROUP/ -> nope
smb://Roland@WORKGROUP/ -> nope
smb://Roland:password@WORKGROUP/ -> nope

and finally

smb://Roland@password@WORKGROUP/ -> YES!

It would be interesting if that solves problems for other people as
well. But note 1) above. There I used DEVICE_URI =
Comment 69 Jay Fenlason 2005-03-01 11:46:20 EST
This was fixed in samba-3.0.9-1.3E.1.  The lastest up2date samba is 
Comment 70 John Thacker 2006-10-28 13:09:25 EDT
*** Bug 121290 has been marked as a duplicate of this bug. ***

Note You need to log in before you can comment on or make changes to this bug.