Discussion:
[OT] print to printer on winxp via cups samba smb
(too old to reply)
r***@newsguy.com
2006-09-13 16:59:47 UTC
Permalink
I need some help getting printing to work from my gentoo machine to an
HP 7410xi (one of those multi-function jobs).

No one is responding to a similar query on the cups list. So bringing
it here although it may be a little off topic.

The printer works from windows but not from gentoo through cups. What
is kind of baffling me is that the logs don't really show a clear
error and in fact appear to be saying that the print job was
successful, but nothing comes out of the printer.

My /etc/cups/printers.conf uses an smb:// addressing (xx'ed out in
this post):

<DefaultPrinter chub-print>
Info chub-print
Location chub
DeviceURI smb://reader:***@chub/chub-print)
State Stopped
StateMessage /usr/libexec/cups/backend/smb failed
StateTime 1157936264
Accepting Yes
Shared Yes
JobSheets none none
QuotaPeriod 0
PageLimit 0
KLimit 0
OpPolicy default
ErrorPolicy stop-printer
</Printer>


Log level in cupsd.conf is set to debug ... here is the error_log
output from one print attempt where user reader calls:

lp file
request id is chub-print-18 (1 file(s))

The only thing that looks like it might indicate an error is the line
saying:
cupsdAuthorize: No authentication data provided.

28 lines from error_log produced by above print attempt:
===================================
D [13/Sep/2006:11:53:26 -0500] cupsdAcceptClient: 5 from localhost:631 (IPv4)
D [13/Sep/2006:11:53:26 -0500] cupsdReadClient: 5 POST / HTTP/1.1
D [13/Sep/2006:11:53:26 -0500] cupsdAuthorize: No authentication data provided.
D [13/Sep/2006:11:53:26 -0500] CUPS-Get-Printers
D [13/Sep/2006:11:53:26 -0500] cupsdProcessIPPRequest: 5 status_code=0 (successful-ok)
D [13/Sep/2006:11:53:26 -0500] cupsdReadClient: 5 POST / HTTP/1.1
D [13/Sep/2006:11:53:26 -0500] cupsdAuthorize: No authentication data provided.
D [13/Sep/2006:11:53:26 -0500] CUPS-Get-Classes
D [13/Sep/2006:11:53:26 -0500] cupsdProcessIPPRequest: 5 status_code=0 (successful-ok)
D [13/Sep/2006:11:53:26 -0500] cupsdReadClient: 5 POST / HTTP/1.1
D [13/Sep/2006:11:53:26 -0500] cupsdAuthorize: No authentication data provided.
D [13/Sep/2006:11:53:26 -0500] CUPS-Get-Default
D [13/Sep/2006:11:53:26 -0500] cupsdProcessIPPRequest: 5 status_code=0 (successful-ok)
D [13/Sep/2006:11:53:26 -0500] cupsdCloseClient: 5
D [13/Sep/2006:11:53:26 -0500] cupsdAcceptClient: 5 from localhost:631 (IPv4)
D [13/Sep/2006:11:53:26 -0500] cupsdReadClient: 5 POST /printers/chub-print HTTP/1.1
D [13/Sep/2006:11:53:26 -0500] cupsdAuthorize: No authentication data provided.
D [13/Sep/2006:11:53:26 -0500] Print-Job ipp://localhost/printers/chub-print
D [13/Sep/2006:11:53:26 -0500] print_job: auto-typing file...
D [13/Sep/2006:11:53:26 -0500] print_job: request file type is text/plain.
D [13/Sep/2006:11:53:26 -0500] add_job: requesting-user-name="reader"
I [13/Sep/2006:11:53:26 -0500] Adding start banner page "none" to job 18.
D [13/Sep/2006:11:53:26 -0500] Discarding unused job-created event...
I [13/Sep/2006:11:53:26 -0500] Adding end banner page "none" to job 18.
I [13/Sep/2006:11:53:26 -0500] Job 18 queued on "chub-print" by "reader".
D [13/Sep/2006:11:53:26 -0500] Job 18 hold_until = 0
D [13/Sep/2006:11:53:26 -0500] cupsdProcessIPPRequest: 5 status_code=0 (successful-ok)
D [13/Sep/2006:11:53:26 -0500] cupsdCloseClient: 5
--
gentoo-***@gentoo.org mailing list
Mick
2006-09-13 20:04:51 UTC
Permalink
Post by r***@newsguy.com
I need some help getting printing to work from my gentoo machine to an
HP 7410xi (one of those multi-function jobs).
No one is responding to a similar query on the cups list. So bringing
it here although it may be a little off topic.
I'm afraid I can't answer your question directly because I do not use Samba,
but if you search this list you'll find an answer as to how to set your WinXP
box as a server for *nix machines and share the printer that way. The Samba
interface adds one more layer of complexity and probability for error.

Make sure you only allow the specific Linux box IP address to connect to your
WinXP box (set it up in the WinXP firewall).

If you get no Samba specific replies and you can't find the previous post then
ask again and I will spend sometime searching for it.
--
Regards,
Mick
r***@newsguy.com
2006-09-14 00:37:06 UTC
Permalink
Post by Mick
I'm afraid I can't answer your question directly because I do not use Samba,
but if you search this list you'll find an answer as to how to set your WinXP
box as a server for *nix machines and share the printer that way. The Samba
interface adds one more layer of complexity and probability for error.
Make sure you only allow the specific Linux box IP address to connect to your
WinXP box (set it up in the WinXP firewall).
I did find a previous post of yours alluding to an earlier post but
that post of yours does give sort of brief howto.
http://thread.gmane.org/gmane.linux.gentoo.user/166004/focus=166061

I'm going to pursue samba solutions first since I have done that
several times and it mostly just worked for me when I made a few
config settings.

I've never really had trouble getting printing to work thru samba
until now and have setup it up at least 5-6 times.

The method you propose in the URL above does sound interesting and I
may give it a try just to compare it to the samba approach.

Thanks
--
gentoo-***@gentoo.org mailing list
Richard Fish
2006-09-13 20:18:33 UTC
Permalink
Post by r***@newsguy.com
State Stopped
I'm guessing that this is your problem. What does "lpc status"
report? Does "cupsenable chub-print" help?

-Richard
--
gentoo-***@gentoo.org mailing list
r***@newsguy.com
2006-09-14 01:10:31 UTC
Permalink
Post by Richard Fish
Post by r***@newsguy.com
State Stopped
I'm guessing that this is your problem. What does "lpc status"
report? Does "cupsenable chub-print" help?
lpc status first reported:
chub-print:
printer is on device 'smb' speed -1
queuing is enabled
printing is disabled
no entries
daemon present

As you see, `disabled' but why would that be? My config doesn't
mention enable/disable and in the past I simply ran the cupsd service
or not to turn off/on. Something new?

So I thought it might just start working after:
cupsenable chub-print
But I guess it is not going to.

After running `cupsenable chub-print' and attempting to print a job
the log output in error_log contains thousands of lines of output from
just one attempt. Among them grepping for the Error lines I see stuff
indicating a connection was not allowed. That output in a moment.

First let me show that a connection is definately in working order:

smbclient -L //chub -Ureader |grep print

WARNING: The "printer admin" option is deprecated
Password:
Domain=[CHUB] OS=[Windows 5.1] Server=[Windows 2000 LAN Manager]
Domain=[CHUB] OS=[Windows 5.1] Server=[Windows 2000 LAN Manager]
print$ Disk Printer Drivers
chub-print Printer HP Officejet 7400 series

smbclient //chub/chub-print -U reader

WARNING: The "printer admin" option is deprecated
Password:
Domain=[CHUB] OS=[Windows 5.1] Server=[Windows 2000 LAN Manager]
smb: \>

The share is there and can be accessed with smbclient

After attempting to print, a few minutes pass and a new look with
lpc status: Shows printing is now disabled again.

Partial Error_log output follows:
grep ^E /var/log/cups/error_log

(Note: Many in-between lines are skipped and those printed are wrapped
for mail)

E [13/Sep/2006:19:44:53 -0500] [Job 24] Tree connect failed
(NT_STATUS_BAD_NETWORK_NAME)

E [13/Sep/2006:19:44:53 -0500] [Job 24] No ticket cache found for
userid=1000

E [13/Sep/2006:19:44:53 -0500] [Job 24] Can not get the ticket cache
for reader

E [13/Sep/2006:19:44:53 -0500] [Job 24] Session setup failed:
NT_STATUS_LOGON_FAILURE

E [13/Sep/2006:19:44:53 -0500] [Job 24] Tree connect failed
(NT_STATUS_BAD_NETWORK_NAME)

E [13/Sep/2006:19:44:53 -0500] [Job 24] Unable to connect to CIFS
host, will retry in 60 seconds...

E [13/Sep/2006:19:45:53 -0500] [Job 24] Tree connect failed
(NT_STATUS_BAD_NETWORK_NAME)

E [13/Sep/2006:19:45:53 -0500] [Job 24] No ticket cache found for
userid=1000

E [13/Sep/2006:19:45:53 -0500] [Job 24] Can not get the ticket cache
for reader

E [13/Sep/2006:19:45:53 -0500] [Job 24] Session setup failed:
NT_STATUS_LOGON_FAILURE

E [13/Sep/2006:19:45:53 -0500] [Job 24] Tree connect failed
(NT_STATUS_BAD_NETWORK_NAME)

E [13/Sep/2006:19:45:53 -0500] [Job 24] Unable to connect to CIFS
host, will retry in 60 seconds...

E [13/Sep/2006:19:46:53 -0500] [Job 24] Tree connect failed
(NT_STATUS_BAD_NETWORK_NAME)

E [13/Sep/2006:19:46:53 -0500] [Job 24] No ticket cache found for
userid=1000

E [13/Sep/2006:19:46:53 -0500] [Job 24] Can not get the ticket cache
for reader

E [13/Sep/2006:19:46:53 -0500] [Job 24] Session setup failed:
NT_STATUS_LOGON_FAILURE

E [13/Sep/2006:19:46:53 -0500] [Job 24] Tree connect failed
(NT_STATUS_BAD_NETWORK_NAME)

E [13/Sep/2006:19:46:53 -0500] [Job 24] Unable to connect to CIFS
host, will retry in 60 seconds...

E [13/Sep/2006:19:47:53 -0500] [Job 24] Unable to connect to CIFS host
after (tried 3 times)

E [13/Sep/2006:19:47:53 -0500] PID 15252
(/usr/libexec/cups/backend/smb) stopped with status 1!

E [13/Sep/2006:19:47:54 -0500] PID 15251
(/usr/libexec/cups/filter/foomatic-rip) stopped with status 9!
--
gentoo-***@gentoo.org mailing list
Richard Fish
2006-09-14 01:55:08 UTC
Permalink
Hmm, do you get something similar if you do:

DEVICE_URI=smb://reader:***@chub/chub-print
export DEVICE_URI
/usr/bin/smbspool 0 reader test 1 0 /etc/fstab

-Richard
--
gentoo-***@gentoo.org mailing list
r***@newsguy.com
2006-09-14 02:40:40 UTC
Permalink
Post by Richard Fish
export DEVICE_URI
/usr/bin/smbspool 0 reader test 1 0 /etc/fstab
Well, that tried to print something at least. Somekind of stepping
problem seems to have prevented a real print. I got 2 pages. one page
with the first and second line of fstab. The second line was indented
about half a page. Then a blank page.
--
gentoo-***@gentoo.org mailing list
Richard Fish
2006-09-14 04:27:03 UTC
Permalink
Post by r***@newsguy.com
Post by Richard Fish
export DEVICE_URI
/usr/bin/smbspool 0 reader test 1 0 /etc/fstab
Well, that tried to print something at least. Somekind of stepping
problem seems to have prevented a real print. I got 2 pages. one page
with the first and second line of fstab. The second line was indented
about half a page. Then a blank page.
Ok, that's good. The staircasing is easily explained/fixed, but not
really important. Mostly we are just interested in the fact that that
command did connect and try and print.

First, do an "ls -l /usr/libexec/cups/backend/smb" It should be a
symbolic link pointing to /usr/bin/smbspool.

If it is, then we need to see what the differences are between running
that command directly vs the way cups runs it. We can use some shell
script trickery to do this:

1. mv /usr/bin/smbspool /usr/bin/smbspool.bin
2. $EDITOR /usr/bin/smbspool
Make a new script that contains:
------
#!/bin/bash
tmpfile=/tmp/smbspool.$$
echo $0:$1:$2:$3:$4:$5:$6:$7 > $tmpfile
env >>$tmpfile

# this part is just a guess..
export DEVICE_URI=$0
/usr/bin/smbspool $1 $2 $3 $4 $5 $6 >>$tmpfile
------

3. chmod 755 /usr/bin/smbspool

Try printing again through cups. After the failure, you should have
one or more /tmp/smbspool.* files. Post one of those here, although
you may want to inspect it first and mask out anything that reveals
your password!

-Richard
--
gentoo-***@gentoo.org mailing list
r***@newsguy.com
2006-09-14 12:56:14 UTC
Permalink
Post by Richard Fish
Post by r***@newsguy.com
Post by Richard Fish
export DEVICE_URI
/usr/bin/smbspool 0 reader test 1 0 /etc/fstab
Well, that tried to print something at least. Somekind of stepping
problem seems to have prevented a real print. I got 2 pages. one page
with the first and second line of fstab. The second line was indented
about half a page. Then a blank page.
Ok, that's good. The staircasing is easily explained/fixed, but not
really important. Mostly we are just interested in the fact that that
command did connect and try and print.
First, do an "ls -l /usr/libexec/cups/backend/smb" It should be a
symbolic link pointing to /usr/bin/smbspool.
If it is, then we need to see what the differences are between running
that command directly vs the way cups runs it. We can use some shell
1. mv /usr/bin/smbspool /usr/bin/smbspool.bin
2. $EDITOR /usr/bin/smbspool
------
#!/bin/bash
tmpfile=/tmp/smbspool.$$
echo $0:$1:$2:$3:$4:$5:$6:$7 > $tmpfile
env >>$tmpfile
# this part is just a guess..
export DEVICE_URI=$0
/usr/bin/smbspool $1 $2 $3 $4 $5 $6 >>$tmpfile
------
3. chmod 755 /usr/bin/smbspool
Try printing again through cups. After the failure, you should have
one or more /tmp/smbspool.* files. Post one of those here, although
you may want to inspect it first and mask out anything that reveals
your password!
Something isn't working as planned. There were no files produced in
/tmp.

echo $DEVICE_URI
smb://reader:***@chub/chub-print

cat /usr/bin/smbspool
#!/bin/bash
tmpfile=/tmp/smbspool.$$
echo $0:$1:$2:$3:$4:$5:$6:$7 > $tmpfile
env >>$tmpfile

export DEVICE_URI=$0
/usr/bin/smbspool $1 $2 $3 $4 $5 $6 >>$tmpfile

ls -l /usr/bin/smbspool
-rwxr-xr-x 1 root root 161 Sep 14 07:33 /usr/bin/smbspool

lp file
request id is chub-print-40 (1 file(s))

ls /tmp/smb*
ls: cannot access /tmp/smb*: No such file or directory

=============================================

Printing failed as expected but nothing was produced in /tmp.

I don't see anything remarkable in the error_log either:

D [14/Sep/2006:07:54:26 -0500] cupsdAcceptClient: 6 from localhost:631 (IPv4)
D [14/Sep/2006:07:54:26 -0500] cupsdReadClient: 6 POST / HTTP/1.1
D [14/Sep/2006:07:54:26 -0500] cupsdAuthorize: No authentication data provided.
D [14/Sep/2006:07:54:26 -0500] CUPS-Get-Printers
D [14/Sep/2006:07:54:26 -0500] cupsdProcessIPPRequest: 6 status_code=0 (successful-ok)
D [14/Sep/2006:07:54:26 -0500] cupsdReadClient: 6 POST / HTTP/1.1
D [14/Sep/2006:07:54:26 -0500] cupsdAuthorize: No authentication data provided.
D [14/Sep/2006:07:54:26 -0500] CUPS-Get-Classes
D [14/Sep/2006:07:54:26 -0500] cupsdProcessIPPRequest: 6 status_code=0 (successful-ok)
D [14/Sep/2006:07:54:26 -0500] cupsdReadClient: 6 POST / HTTP/1.1
D [14/Sep/2006:07:54:26 -0500] cupsdAuthorize: No authentication data provided.
D [14/Sep/2006:07:54:26 -0500] CUPS-Get-Default
D [14/Sep/2006:07:54:26 -0500] cupsdProcessIPPRequest: 6 status_code=0 (successful-ok)
D [14/Sep/2006:07:54:26 -0500] cupsdCloseClient: 6
D [14/Sep/2006:07:54:26 -0500] cupsdAcceptClient: 6 from localhost:631 (IPv4)
D [14/Sep/2006:07:54:26 -0500] cupsdReadClient: 6 POST /printers/chub-print HTTP/1.1
D [14/Sep/2006:07:54:26 -0500] cupsdAuthorize: No authentication data provided.
D [14/Sep/2006:07:54:26 -0500] Print-Job ipp://localhost/printers/chub-print
D [14/Sep/2006:07:54:26 -0500] print_job: auto-typing file...
D [14/Sep/2006:07:54:26 -0500] print_job: request file type is text/plain.
D [14/Sep/2006:07:54:26 -0500] add_job: requesting-user-name="root"
I [14/Sep/2006:07:54:26 -0500] Adding start banner page "none" to job 40.
D [14/Sep/2006:07:54:26 -0500] Discarding unused job-created event...
I [14/Sep/2006:07:54:26 -0500] Adding end banner page "none" to job 40.
I [14/Sep/2006:07:54:26 -0500] Job 40 queued on "chub-print" by "root".
D [14/Sep/2006:07:54:26 -0500] Job 40 hold_until = 0
D [14/Sep/2006:07:54:26 -0500] cupsdProcessIPPRequest: 6 status_code=0 (successful-ok)
D [14/Sep/2006:07:54:26 -0500] cupsdCloseClient: 6
--
gentoo-***@gentoo.org mailing list
r***@newsguy.com
2006-09-14 13:56:59 UTC
Permalink
Post by r***@newsguy.com
Printing failed as expected but nothing was produced in /tmp.
Adding #!/bin/bash -x
to the smbspool script and I don't see any output when running
lp file

I'm not sure the output would be visible from -x in my tty but I'm
guessing smbspool is not being called.
--
gentoo-***@gentoo.org mailing list
Richard Fish
2006-09-15 07:40:01 UTC
Permalink
Post by r***@newsguy.com
Something isn't working as planned. There were no files produced in
/tmp.
Odd. Where does /usr/libexec/cups/backend/smb point to?

-Richard
--
gentoo-***@gentoo.org mailing list
r***@newsguy.com
2006-09-15 13:52:20 UTC
Permalink
Post by Richard Fish
Post by r***@newsguy.com
Something isn't working as planned. There were no files produced in
/tmp.
Odd. Where does /usr/libexec/cups/backend/smb point to?
I did check that as you suggested, before replacing smbspool.

ls -l /usr/libexec/cups/backend/smb
lrwxrwxrwx [...] /usr/libexec/cups/backend/smb -> /usr/bin/smbspool
--
gentoo-***@gentoo.org mailing list
Richard Fish
2006-09-15 16:55:27 UTC
Permalink
Post by Richard Fish
ls -l /usr/libexec/cups/backend/smb
lrwxrwxrwx [...] /usr/libexec/cups/backend/smb -> /usr/bin/smbspool
Ok. Are you specifying a ServerBin directory in /etc/cups/cupsd.conf?
It should point to /usr/libexec/cups if you are.

Also, I hope you fixed the bug in the script that I posted....the call
to /usr/bin/smbspool should of course be for smbspool.bin. :-(

-Richard
--
gentoo-***@gentoo.org mailing list
r***@newsguy.com
2006-09-15 17:56:21 UTC
Permalink
Post by Richard Fish
Post by Richard Fish
ls -l /usr/libexec/cups/backend/smb
lrwxrwxrwx [...] /usr/libexec/cups/backend/smb -> /usr/bin/smbspool
Ok. Are you specifying a ServerBin directory in /etc/cups/cupsd.conf?
It should point to /usr/libexec/cups if you are.
No. That stuff is commented out.
grep 'ServerBin' /etc/cups/cupsd.conf
# ServerBin: the root directory for the scheduler executables.
#ServerBin /usr/lib/cups
So that should default to the right place right?
Post by Richard Fish
Also, I hope you fixed the bug in the script that I posted....the call
to /usr/bin/smbspool should of course be for smbspool.bin. :-(
Egad, no I missed that.

contents of smb* files below. There were two. I've printed the first
one below. The second one is identicle except for the first line
which is shown in a diff at the end.

But it appears the main thing of note is this line:
cli_start_connection: failed to connect to CUPS<20> (0.0.0.0)
Which appears to show that cups is trying to connect 0.0.0.0 which is
usally interpreted as localhost I think. Is that wrong or indicating
some config problem further up the chain of command?

/tmp/smb.32258

/usr/libexec/cups/backend/smb:45:reader:file:1:job-uuid=urn:uuid:\
662a44c4-890f-32b0-7d15-3bb4b60e7fe1::
IPP_PORT=631
TMPDIR=/var/spool/cups/tmp
CUPS_FONTPATH=/usr/share/cups/fonts
CUPS_DOCROOT=/usr/share/cups/docs
USER=root
CUPS_SERVERROOT=/etc/cups
SOFTWARE=CUPS/1.2.3
CUPS_CACHEDIR=/var/cache/cups
DEVICE_URI=smb://reader:***@chub/chub-print)
PATH=/usr/libexec/cups/filter:/usr/bin:/usr/sbin:/bin:/usr/bin
CUPS_REQUESTROOT=/var/spool/cups
PWD=/
SERVER_ADMIN=***@reader.local.lan
PPD=/etc/cups/ppd/chub-print.ppd
LANG=en_US
CUPS_ENCRYPTION=IfRequested
SHLVL=1
CUPS_DATADIR=/usr/share/cups
PRINTER=chub-print
FINAL_CONTENT_TYPE=printer/chub-print
RIP_MAX_CACHE=8m
CONTENT_TYPE=text/plain
CUPS_SERVER=localhost
CHARSET=utf-8
CUPS_STATEDIR=/var/run/cups
CUPS_SERVERBIN=/usr/libexec/cups
_=/usr/bin/env
WARNING: The "printer admin" option is deprecated
added interface ip=192.168.0.4 bcast=192.168.0.255 nmask=255.255.255.0
cli_start_connection: failed to connect to CUPS<20> (0.0.0.0)
cli_start_connection: failed to connect to CUPS<20> (0.0.0.0)
cli_start_connection: failed to connect to CUPS<20> (0.0.0.0)
cli_start_connection: failed to connect to CUPS<20> (0.0.0.0)
cli_start_connection: failed to connect to CUPS<20> (0.0.0.0)
cli_start_connection: failed to connect to CUPS<20> (0.0.0.0)
cli_start_connection: failed to connect to CUPS<20> (0.0.0.0)
cli_start_connection: failed to connect to CUPS<20> (0.0.0.0)
cli_start_connection: failed to connect to CUPS<20> (0.0.0.0)

============================================================
# diff smbspool.32258 smbspool.32277
1c1
--
gentoo-***@gentoo.org mailing list
Richard Fish
2006-09-15 23:57:15 UTC
Permalink
And *now* see the problem.

There should absolutely positively *not* be a ')' at the end of this
line. You need to fix printers.conf to remove this. Sigh...so much
work for such a silly little problem.

-Richard
--
gentoo-***@gentoo.org mailing list
r***@newsguy.com
2006-09-17 02:09:59 UTC
Permalink
Post by Richard Fish
And *now* see the problem.
There should absolutely positively *not* be a ')' at the end of this
line. You need to fix printers.conf to remove this. Sigh...so much
work for such a silly little problem.
Richard, I'm sorry it seems I've really wasted lots of your time here.
However I don't think this is the only problem. I really hope there
is not some other moronic user miconfig...

It's really a kick in the pants that my very first post on this thread
Showed that stupid typo... I never would have seen it I guess, if you
had not. But it was there in my very first post... looking back it
appears glaringly right their in my posted `printers.conf'.

It seems bad to me that something in cups error output did not point
to that misconstrued URL. In fact, going further... I see literally
thousands of lines appear in error_log (in debug mode) that are not
error lines at all. Then the actual error lines are nearly useless
in tracking down a problem.

I'm still unable to print (EVEN WITH THAT CURSED URL FIXED).

It may be too much to expect you to still hang in there with this
problem so please tell me you've had enough if that is the case.

If you are still willing... (and I cannot guarantee there is not some
other horribly stupid user error) what can I post that will help diagnose
this inability to print?

I've posted below error_log excerpt, /tmp file content.
smbclient connection to chub-print (at the very end)

Why doesn't cups debug output give us some better diagnostic
information?

Can you see some other really stupid typo or something else in this
output?

Actual error lines from /var/log/cups/error_log:
[... skipped Four more of these Connect messages above]

E [16/Sep/2006:20:48:26 -0500] [Job 51] Unable to connect to CIFS
host, will retry in 60 seconds...

E [16/Sep/2006:20:49:26 -0500] [Job 51] Unable to connect to CIFS host
after (tried 3 times)

E [16/Sep/2006:20:49:26 -0500] PID 10109
(/usr/libexec/cups/backend/smb) stopped with status 1!

E [16/Sep/2006:20:49:27 -0500] PID 10108
(/usr/libexec/cups/filter/foomatic-rip) stopped with status 9!


After this attempt chub-print gets turned off as revealed by lpq:
# lpq
chub-print is not ready
Rank Owner Job File(s) Total Size
1st reader 51 file 2048 bytes

Turning printer off on error is not in my printers.conf (remvoed by
me)

The /tmp file from this print attempt:

/usr/libexec/cups/backend/smb:50:reader:file:1:job-uuid=urn:uuid:e3a19e12-d965-3164-57e1-f3f92cea54ec::
IPP_PORT=631
TMPDIR=/var/spool/cups/tmp
CUPS_FONTPATH=/usr/share/cups/fonts
CUPS_DOCROOT=/usr/share/cups/docs
USER=root
CUPS_SERVERROOT=/etc/cups
SOFTWARE=CUPS/1.2.3
CUPS_CACHEDIR=/var/cache/cups
DEVICE_URI=smb://reader:***@chub/chub-print
PATH=/usr/libexec/cups/filter:/usr/bin:/usr/sbin:/bin:/usr/bin
CUPS_REQUESTROOT=/var/spool/cups
PWD=/
SERVER_ADMIN=***@reader.local.lan
PPD=/etc/cups/ppd/chub-print.ppd
LANG=en_US
CUPS_ENCRYPTION=IfRequested
SHLVL=1
CUPS_DATADIR=/usr/share/cups
PRINTER=chub-print
FINAL_CONTENT_TYPE=printer/chub-print
RIP_MAX_CACHE=8m
CONTENT_TYPE=text/plain
CUPS_SERVER=localhost
CHARSET=utf-8
CUPS_STATEDIR=/var/run/cups
CUPS_SERVERBIN=/usr/libexec/cups
_=/usr/bin/env
WARNING: The "printer admin" option is deprecated
added interface ip=192.168.0.4 bcast=192.168.0.255 nmask=255.255.255.0
cli_start_connection: failed to connect to CUPS<20> (0.0.0.0)
cli_start_connection: failed to connect to CUPS<20> (0.0.0.0)
[... snipped 7 more identicle lines]

Note that smbclient can connect as user reader to chub-print with no
problem.
smbclient //chub/chub-print -Ureader
WARNING: The "printer admin" option is deprecated
Password: XXXXXX <enter>
Domain=[CHUB] OS=[Windows 5.1] Server=[Windows 2000 LAN Manager]
smb: \>
--
gentoo-***@gentoo.org mailing list
Richard Fish
2006-09-17 04:27:38 UTC
Permalink
Post by r***@newsguy.com
Richard, I'm sorry it seems I've really wasted lots of your time here.
However I don't think this is the only problem. I really hope there
is not some other moronic user miconfig...
np. I missed it too for several messages. :-)
Post by r***@newsguy.com
I'm still unable to print (EVEN WITH THAT CURSED URL FIXED).
I think the problem here is that my script is screwing things up. I
actually had no idea what $0 would be in this case (thus the note that
"this is just a guess" ;-)). It looks like when cups is calling
smbspool, $0 is the name of the program, and not the URI of the device
(see man smbspool to understand why I was uncertain here!). And I am
changing DEVICE_URI to be whatever $0 was...which is wrong.

So the fixed script should be

------
#!/bin/bash
tmpfile=/tmp/smbspool.$$
echo $0:$1:$2:$3:$4:$5:$6:$7 > $tmpfile
env >>$tmpfile

/usr/bin/smbspool.bin $1 $2 $3 $4 $5 $6 >>$tmpfile
------

But actually at this point I think you can just move smbspool.bin back
to smbspool, and things should work ok.

Cheers,
-Richard
--
gentoo-***@gentoo.org mailing list
r***@newsguy.com
2006-09-17 11:44:16 UTC
Permalink
Post by Richard Fish
Post by r***@newsguy.com
Richard, I'm sorry it seems I've really wasted lots of your time here.
However I don't think this is the only problem. I really hope there
is not some other moronic user miconfig...
np. I missed it too for several messages. :-)
Post by r***@newsguy.com
I'm still unable to print (EVEN WITH THAT CURSED URL FIXED).
I think the problem here is that my script is screwing things up. I
actually had no idea what $0 would be in this case (thus the note that
"this is just a guess" ;-)). It looks like when cups is calling
smbspool, $0 is the name of the program, and not the URI of the device
(see man smbspool to understand why I was uncertain here!). And I am
changing DEVICE_URI to be whatever $0 was...which is wrong.
So the fixed script should be
------
#!/bin/bash
tmpfile=/tmp/smbspool.$$
echo $0:$1:$2:$3:$4:$5:$6:$7 > $tmpfile
env >>$tmpfile
/usr/bin/smbspool.bin $1 $2 $3 $4 $5 $6 >>$tmpfile
------
But actually at this point I think you can just move smbspool.bin back
to smbspool, and things should work ok.
Ok... and away we go... printing works now.

Richard what do you make of the fact that I cannot connect to cups
with the normal http://locahost:631?

I've seen a few posts here from others who have noticed it too.

http://localhost:631/admin

or

http://localhost:631/help

Will get a connection, but in the past a simple:
http://localhost:631 was enough.

That now gets a 404 Not Found

error_log has this:

D [17/Sep/2006:06:40:22 -0500] cupsdReadClient: 7 Browser asked for language "en-us.utf-8"...
D [17/Sep/2006:06:40:22 -0500] cupsdAuthorize: No authentication data provided.
D [17/Sep/2006:06:40:22 -0500] cupsdSendError: 7 code=404 (Not Found)
D [17/Sep/2006:06:40:23 -0500] cupsdCloseClient: 7
D [17/Sep/2006:06:40:23 -0500] cupsdAcceptClient: 7 from localhost:631 (IPv4)
D [17/Sep/2006:06:40:23 -0500] cupsdReadClient: 7 GET /cups.css HTTP/1.1
D [17/Sep/2006:06:40:23 -0500] cupsdReadClient: 7 Browser asked for language "en-us.utf-8"...
D [17/Sep/2006:06:40:23 -0500] cupsdAuthorize: No authentication data provided.
D [17/Sep/2006:06:40:23 -0500] cupsdSendError: 7 code=404 (Not Found)
D [17/Sep/2006:06:40:23 -0500] cupsdCloseClient: 7
D [17/Sep/2006:06:40:23 -0500] cupsdAcceptClient: 7 from localhost:631 (IPv4)
D [17/Sep/2006:06:40:23 -0500] cupsdReadClient: 7 GET /favicon.ico HTTP/1.1
D [17/Sep/2006:06:40:23 -0500] cupsdReadClient: 7 Browser asked for language "en-us.utf-8"...
D [17/Sep/2006:06:40:23 -0500] cupsdAuthorize: No authentication data provided.
D [17/Sep/2006:06:40:23 -0500] cupsdSendError: 7 code=404 (Not Found)
D [17/Sep/2006:06:40:23 -0500] cupsdCloseClient: 7
--
gentoo-***@gentoo.org mailing list
Richard Fish
2006-09-17 15:21:34 UTC
Permalink
Post by r***@newsguy.com
Richard what do you make of the fact that I cannot connect to cups
with the normal http://locahost:631?
Actually, you "connect" to it fine, it just has nothing to show you...
Post by r***@newsguy.com
http://localhost:631 was enough.
That now gets a 404 Not Found
What is DocumentRoot set to in /etc/cups/cupsd.conf? Try setting it
to /usr/share/cups/html.

-Richard
--
gentoo-***@gentoo.org mailing list
r***@newsguy.com
2006-09-18 17:12:42 UTC
Permalink
Post by Richard Fish
Post by r***@newsguy.com
Richard what do you make of the fact that I cannot connect to cups
with the normal http://locahost:631?
Actually, you "connect" to it fine, it just has nothing to show you...
Post by r***@newsguy.com
http://localhost:631 was enough.
That now gets a 404 Not Found
What is DocumentRoot set to in /etc/cups/cupsd.conf? Try setting it
to /usr/share/cups/html.
Haa.. you nailed it again.
It comes set to /usr/share/cups/doc
But needs: /usr/share/cups/html

I guess that would be a tiny bug.
--
gentoo-***@gentoo.org mailing list
Continue reading on narkive:
Loading...