PDA

View Full Version : SLES 12 SP1 Print jobs to AppSocket/JetDirect printer hang in queue



afairch
06-Feb-2018, 19:51
I have added a network (AppSocket/JetDirect) printer using YaST2, the connection test succeeds, and I can telnet to the printer on port 9100, but any jobs submitted using 'lp', 'lpr', or the 'Print test page' function in YaST just sit in the queue and never print. Running tcpdump to show traffic between the server and the printer only shows a couple of SNMP packets, and no other traffic. This doesn't seem to be a network connectivity issue, because I am able to cat a file and pipe that to netcat and send it to port 9100 and it prints - albeit with the stair-stepping effect.

malcolmlewis
06-Feb-2018, 21:16
I have added a network (AppSocket/JetDirect) printer using YaST2, the connection test succeeds, and I can telnet to the printer on port 9100, but any jobs submitted using 'lp', 'lpr', or the 'Print test page' function in YaST just sit in the queue and never print. Running tcpdump to show traffic between the server and the printer only shows a couple of SNMP packets, and no other traffic. This doesn't seem to be a network connectivity issue, because I am able to cat a file and pipe that to netcat and send it to port 9100 and it prints - albeit with the stair-stepping effect.
Hi and welcome to the Forum :)
That sounds like the cups service is not running.... can you login to the cups interface on the host, localhost:631

ab
06-Feb-2018, 21:18
Once or twice I have seen printers get suspended, or equivalent, within my
laptop. Is it possible that the state of the printer within your computer
is suspended?

On 02/06/2018 11:54 AM, afairch wrote:
>
> I have added a network (AppSocket/JetDirect) printer using YaST2, the
> connection test succeeds, and I can telnet to the printer on port 9100,
> but any jobs submitted using 'lp', 'lpr', or the 'Print test page'
> function in YaST just sit in the queue and never print. Running tcpdump
> to show traffic between the server and the printer only shows a couple
> of SNMP packets, and no other traffic. This doesn't seem to be a network
> connectivity issue, because I am able to cat a file and pipe that to
> netcat and send it to port 9100 and it prints - albeit with the
> stair-stepping effect.
>
>

--
Good luck.

If you find this post helpful and are logged into the web interface,
show your appreciation and click on the star below.

If you want to send me a private message, please let me know in the
forum as I do not use the web interface often.

afairch
08-Feb-2018, 19:51
Hi and welcome to the Forum :)
That sounds like the cups service is not running.... can you login to the cups interface on the host, localhost:631

I can log in to the cups interface. Additionally 'systemctl status cups.service' shows that the service is Active and running.

malcolmlewis
08-Feb-2018, 20:31
On Thu 08 Feb 2018 06:54:02 PM CST, afairch wrote:

malcolmlewis;50909 Wrote:
> Hi and welcome to the Forum :)
> That sounds like the cups service is not running.... can you login to
> the cups interface on the host, localhost:631

I can log in to the cups interface. Additionally 'systemctl status
cups.service' shows that the service is Active and running.




Hi
So when you run your command (example of this?) do you see the job
appear in the CUPS interface (paused?), then can you send the job to the
printer, or it doesn't even get there?

Is this ipv4 or ipv6?

--
Cheers Malcolm °¿° SUSE Knowledge Partner (Linux Counter #276890)
openSUSE Leap 42.3|GNOME 3.20.2|4.4.104-39-default
If you find this post helpful and are logged into the web interface,
please show your appreciation and click on the star below... Thanks!

afairch
08-Feb-2018, 21:54
Once or twice I have seen printers get suspended, or equivalent, within my
laptop. Is it possible that the state of the printer within your computer
is suspended?

On 02/06/2018 11:54 AM, afairch wrote:
>
> I have added a network (AppSocket/JetDirect) printer using YaST2, the
> connection test succeeds, and I can telnet to the printer on port 9100,
> but any jobs submitted using 'lp', 'lpr', or the 'Print test page'
> function in YaST just sit in the queue and never print. Running tcpdump
> to show traffic between the server and the printer only shows a couple
> of SNMP packets, and no other traffic. This doesn't seem to be a network
> connectivity issue, because I am able to cat a file and pipe that to
> netcat and send it to port 9100 and it prints - albeit with the
> stair-stepping effect.
>
>

--
Good luck.

If you find this post helpful and are logged into the web interface,
show your appreciation and click on the star below.

If you want to send me a private message, please let me know in the
forum as I do not use the web interface often.

Printer is not suspended, and this is not limited to just one printer, I have added another printer and am seeing the same behavior.

afairch
08-Feb-2018, 22:06
Hi
So when you run your command (example of this?) do you see the job
appear in the CUPS interface (paused?), then can you send the job to the
printer, or it doesn't even get there?

Is this ipv4 or ipv6?

--
Cheers Malcolm °¿° SUSE Knowledge Partner (Linux Counter #276890)
openSUSE Leap 42.3|GNOME 3.20.2|4.4.104-39-default
If you find this post helpful and are logged into the web interface,
please show your appreciation and click on the star below... Thanks!

In the CUPS Jogs page, the job shows as completed, but with the message "Unable to write print data: Broken pipe", the Printers page shows the queue status as 'Idle - "Waiting for printer to finish."'

jmozdzen
09-Feb-2018, 14:39
Hi,

> any jobs submitted using 'lp', 'lpr', or the 'Print test page' function in YaST just sit in the queue and never print.
> Printer is not suspended, and this is not limited to just one printer, I have added another printer and am seeing the same behavior.

What's in cups' (error) log, see /var/log/cups/* ? Anything suspicious in the output from "lpc status"?

Might be some filter issue, but hopefully the error log will provide more details.

Regards,
J

afairch
09-Feb-2018, 15:32
Hi,

> any jobs submitted using 'lp', 'lpr', or the 'Print test page' function in YaST just sit in the queue and never print.
> Printer is not suspended, and this is not limited to just one printer, I have added another printer and am seeing the same behavior.

What's in cups' (error) log, see /var/log/cups/* ? Anything suspicious in the output from "lpc status"?

Might be some filter issue, but hopefully the error log will provide more details.

Regards,
J

Output of 'lpc status' is normal. Since I have LogLevel set to debug, the error_log contains a LOT of information, but this snippet contains the error:


D [09/Feb/2018:14:22:16 +0000] [Job 53] backendRunLoop(print_fd=0, device_fd=6, snmp_fd=5, addr=0x7f817a9b5f58, use_bc=1, side_cb=0x7f817a53f410)
D [09/Feb/2018:14:22:16 +0000] [Job 53] Read 8192 bytes of print data...
D [09/Feb/2018:14:22:16 +0000] [Job 53] PID 14874 (/usr/lib/cups/filter/hpps) exited with no errors.
D [09/Feb/2018:14:22:16 +0000] [Job 53] Wrote 5840 bytes of print data...
D [09/Feb/2018:14:22:16 +0000] [Job 53] Error reading back-channel data: Connection reset by peer
E [09/Feb/2018:14:22:16 +0000] [Job 53] Unable to write print data: Broken pipe
D [09/Feb/2018:14:22:16 +0000] cupsdMarkDirty(---J-)
D [09/Feb/2018:14:22:16 +0000] cupsdSetBusyState: newbusy="Printing jobs and dirty files", busy="Printing jobs and dirty files"
D [09/Feb/2018:14:22:16 +0000] [Job 53] Set job-printer-state-message to "Unable to write print data: Broken pipe", current level=ERROR
I [09/Feb/2018:14:22:16 +0000] [Job 53] Waiting for printer to finish.
D [09/Feb/2018:14:22:16 +0000] Discarding unused job-progress event...
D [09/Feb/2018:14:22:16 +0000] Discarding unused printer-state-changed event...
D [09/Feb/2018:14:22:16 +0000] [Job 53] PID 14875 (/usr/lib/cups/backend/socket) exited with no errors.
D [09/Feb/2018:14:22:16 +0000] [Job 53] time-at-completed=1518186136
D [09/Feb/2018:14:22:16 +0000] Discarding unused job-completed event...
I [09/Feb/2018:14:22:16 +0000] [Job 53] Job completed.
D [09/Feb/2018:14:22:16 +0000] cupsdMarkDirty(---J-)
D [09/Feb/2018:14:22:16 +0000] cupsdSetBusyState: newbusy="Printing jobs and dirty files", busy="Printing jobs and dirty files"
D [09/Feb/2018:14:22:16 +0000] cupsdSetBusyState: newbusy="Printing jobs and dirty files", busy="Printing jobs and dirty files"
D [09/Feb/2018:14:22:16 +0000] Discarding unused printer-state-changed event...
D [09/Feb/2018:14:22:17 +0000] [Job 53] Unloading...

jmozdzen
09-Feb-2018, 16:06
Hi,

you said you had checked network traffic via tcpdump, but only got SNMP packets - so assuming you have not missed any packets (you might re-run this with filter "port 9100" just to be sure), this would imply that CUPS didn't even attempt to connect to the printer. Have you triple-checked your printer definition, i.e. in /etc/cups/printers.conf (DeviceURI) - any typos within the printer address (DNS name or IP) or port number, and if configured by name, does the host name resolve to the proper address (c&p the host name, don't retype, when checking... it's surprising how the human brain will auto-correct typos. Been there :-[ ).

Regards,
J

afairch
12-Feb-2018, 17:19
Hi,

you said you had checked network traffic via tcpdump, but only got SNMP packets - so assuming you have not missed any packets (you might re-run this with filter "port 9100" just to be sure), this would imply that CUPS didn't even attempt to connect to the printer. Have you triple-checked your printer definition, i.e. in /etc/cups/printers.conf (DeviceURI) - any typos within the printer address (DNS name or IP) or port number, and if configured by name, does the host name resolve to the proper address (c&p the host name, don't retype, when checking... it's surprising how the human brain will auto-correct typos. Been there :-[ ).

Regards,
J

In the course of troubleshooting, the issue has shifted somewhat, but is still not resolved (I wish I knew which thing I did caused the change). Packet captures do now show traffic to port 9100 on the printer, but all jobs result in the error "Unable to write print data: Broken pipe" in /var/log/cups/error_log.

The printers.conf entries were not added by me, but by the Yast2 printers module, so they are not subject to my horrible typing skills, and the "Test connection" option in Yast2 succeeds, so I am able to make a network connection to the printer.

Thanks