CUPS prints to an Ethernet-attached printer just fine if the output
comes from a (local) linux app. Print jobs from another machine
printed via Samba to the same CUPS printer never complete.


The HD on 'manticore', my file server / Linux-of-all-trades,
recently died ("billyuns and billyuns" of unreadable sectors). I
swapped some hardware around, loaded a copy of openSuSE 10.2 on a
fresh hard drive, and I'm busy trying to get everything running

The printer for Linux, the Win2K development machine, and my OS/2
system 'office' is an Ethernet-attached Brother MFC-420CN (printer /
FAX / scanner). Under SuSE 9.1 I used the Brother-supplied Linux
drivers with CUPS; the only problem was that CUPS seemed to "time
out" on the Samba interface and needed to be restarted, especially
if the printer was powered down at the time.

With openSuSE 10.2 and the "latest" CUPS and Brother software I can
print with no problems from "local" Linux apps (e.g. those running
on 'manticore') such as 'gedit' (Gnome text editor) or 'Inkscape'
(vector graphics drawing).

The software:

## uname -a
Linux manticore #1 SMP Mon Nov 27 11:46:27 UTC
2006 i686 athlon i386 GNU/Linux
## rpm -qa | grep 'cups\|MFC'

However, when I attempt to print from my 'office', my OS/2 machine,
every printout "hangs". The PostScript output (from an OS/2
Textronix Phaser 550 driver) makes it to 'manticore', a print job is
queued for the MFC420CN by CUPS, a spool file appears, the MFC420CN
reports "Receiving Data" on its LCD panel, and that's all.

This is not a Linux hang: 'manticore' keeps running. If I print
from 'office' to my CUPS PDF printer "PDFWriter" it works. When a
job is hung I can successfully cancel the job through the Firefox
(localhost:631); when I press the MFC420CN's (Stop) button and the
LCD reverts to its idle display.

However, until I do this, the print job hangs there, incomplete, for
as long as I care to wait. Restarting CUPS and pressing the
MFC-420CN's (Stop) button updates the CUPS Job timestamp and causes
the printer's LCD panel to blank, then go back to "Receiving Data"
again as the job is restarted.

Here's the CUPS admin description for a "hung" job:

mfc420cn (Default Printer) "Connected to brn_60fb75..."
Description: Brother MFC-420CN Printer / Scanner / FAX
Location: Computer Lab
Make and Model: Brother MFC-420CN CUPS v1.1
Printer State: processing, accepting jobs, published.
Device URI: socket://brn_60fb75:9100/

and here's the job description:

ID Name User Size Pages State
mfc420cn-27 smbprn.00000016 FRANK 279k 1 processing since
.Untitled Tue Jun 12 21:21:03

Now, if anyone out there happens to know _exactly_ what the problem
is and how to fix it, that would be wonderful. However, I'd
be more than happy to hear some clues on how to home in on whatever
is causing remote jobs to get hung up.


1) Is there any way to figure out what each party (CUPS, the
printer) thinks it's waiting on? I've set "LogLevel debug" in
my /etc/cups/cupsd.conf file, but that seems to fill the log
file up in a couple of minutes.

2) I'm assuming that CUPS' sending print data to the printer
indicates that the print stream from 'office' has been
completely received. The contents of a sample CUPS spool file
('d00027') _seems_ to agree with this assumption, as it begins

%%Title: .Untitled
%%Creator: Presentation Manager 2.40
%%CreationDate: 21:21 06/12/2007
%%DocumentProcSets: PM_1.2
%%DocumentSuppliedProcSets: PM_1.2
%%PrinterName: MFC420CN
%%PrinterRect: 10 15 600 775

and ends with

%%+ font Courier Bold

Is this all CUPS should need? Or is something missing?

3) While both the local app printout stream and the remote print
stream from 'office' are aimed at the same CUPS queue, the
_contents_ of a spool file from each source is likely to be at
least _slightly_ different. What differences might be
significant? That is, what spool contents might cause a "hang"
in the flow between CUPS and a printer? Between CUPS and a
network printer?

4) The spool file for a job from 'office' contains a large hex
section that starts

/UniqueID 263788 def
/FontBBox { -50 -288 746 848 } readonly def
currentdict end
currentfile eexec
a1d6d02b8937de195ee7ac8982eb2d8b0810a4ef164f32a7ee 723429bc8a3ed7

and the section seems to end with

00000000000000000000000000000000000000000000000000 00000000000000

A sample spool file for a local print job does not seem to have
this. Any change it's relevant to the problem? (If not, I
apologize to those reading this via dialup).

Finally, I'm appending a section of my CUPS error_log file that
may or may not be useful (I've deleted the timestamps, which
run from "12/Jun/2007:21:34:35" to "12/Jun/2007:21:34:44"):

Any clues, hints, or suggestions will be appreciated.


Frank McKenney
We the willing, led by the unknowing, are doing the impossible
for the ungrateful. We have been doing so much with so little
for so long that we're now qualified to do anything with nothing.
-- Attr. various armed forces over the centuries.

I [] Listening to on fd 0...
E [] Unable to open listen socket for address :::631 - Address
family not supported by protocol.
I [] Listening to /var/run/cups/cups.sock on fd 2...
D [] Discarding unused printer-state-changed event...
D [] job-sheets=none,none
D [] banner_page = 0
D [] [Job 27] argv[0]="mfc420cn"
D [] [Job 27] argv[1]="27"
D [] [Job 27] argv[2]="FRANK"
D [] [Job 27] argv[3]="smbprn.00000016 .Untitled"
D [] [Job 27] argv[4]="1"
D [] [Job 27] argv[5]="job-uuid=urn:uuid:09c6cb55-45d5-3784-
D [] [Job 27] argv[6]="/var/spool/cups/d00027-001"
D [] [Job 27] envp[0]="CUPS_CACHEDIR=/var/cache/cups"
D [] [Job 27] envp[1]="CUPS_DATADIR=/usr/share/cups"
D [] [Job 27] envp[2]="CUPS_DOCROOT=/usr/share/doc/packages/cups"
D [] [Job 27] envp[3]="CUPS_FONTPATH=/usr/share/cups/fonts"
D [] [Job 27] envp[4]="CUPS_REQUESTROOT=/var/spool/cups"
D [] [Job 27] envp[5]="CUPS_SERVERBIN=/usr/lib/cups"
D [] [Job 27] envp[6]="CUPS_SERVERROOT=/etc/cups"
D [] [Job 27] envp[7]="CUPS_STATEDIR=/var/run/cups"
D [] [Job 27] envp[8]="PATH=/usr/lib/cups/filter:/usr/bin:
D [] [Job 27] envp[9]=""
D [] [Job 27] envp[10]="SOFTWARE=CUPS/1.2.7"
D [] [Job 27] envp[11]="TMPDIR=/var/spool/cups/tmp"
D [] [Job 27] envp[12]="USER=root"
D [] [Job 27] envp[13]="CUPS_SERVER=/var/run/cups/cups.sock"
D [] [Job 27] envp[14]="CUPS_ENCRYPTION=IfRequested"
D [] [Job 27] envp[15]="IPP_PORT=631"
D [] [Job 27] envp[16]="CHARSET=utf-8"
D [] [Job 27] envp[17]="LANG=en"
D [] [Job 27] envp[18]="PPD=/etc/cups/ppd/mfc420cn.ppd"
D [] [Job 27] envp[19]="RIP_MAX_CACHE=8m"
D [] [Job 27] envp[20]="CONTENT_TYPE=application/vnd.cups-raw"
D [] [Job 27] envp[21]="DEVICE_URI=socket://brn_60fb75:9100/"
D [] [Job 27] envp[22]="PRINTER=mfc420cn"
I [] Started backend /usr/lib/cups/backend/socket (PID 1319) for
job 27.
D [] Discarding unused job-state event...
D [] Discarding unused printer-state-changed event...
D [] [Job 27] Connected to (IPv4)...
D [] Discarding unused job-progress event...
D [] [Job 27] backendRunLoop(print_fd=4, device_fd=5, use_bc=1)
D [] [Job 27] Read 8192 bytes of print data...
D [] [Job 27] Wrote 8192 bytes of print data...
D [] [Job 27] Read 8192 bytes of print data...
D [] Discarding unused printer-state-changed event...
D [] cupsdNetIFUpdate: "lo" = localhost...
D [] cupsdNetIFUpdate: "eth0" =
D [] [Job 27] Wrote 8192 bytes of print data...
## 19 similar pairs of these Reads & Wrotes actually appear in the file.
D [] [Job 27] Wrote 8192 bytes of print data...
D [] [Job 27] Read 8192 bytes of print data...
D [] cupsdAcceptClient: 7 from localhost:631 (IPv4)
D [] cupsdReadClient: 7 GET /printers/mfc420cn HTTP/1.1
D [] cupsdReadClient: 7 Browser asked for language "en-us.utf-8"...
D [] cupsdAuthorize: No authentication data provided.
D [] CGI /usr/lib/cups/cgi-bin/printers.cgi started - PID = 1320

Frank McKenney, McKenney Associates
Richmond, Virginia / (804) 320-4887
Munged E-mail: frank uscore mckenney ayut minds pring dawt cahm (y'all)