Web lists-archives.com

Re: lp printing doesn't work

On 08/29/2017 06:02 AM, Brian wrote:
On Sun 27 Aug 2017 at 17:19:51 -0700, Gary Roach wrote:

Debian Stretch
KDE Desktop
HP Officejet Pro 8600 printer
Wireless connection

For some reason, my lp print command doesn't work. My lpoptions file in
/etc/cups/lpoptions is:

Default Officejet_Pro_8600_N911a media=DRAFT  page-bottom=54 page-left=54 page-right=54 page-top=54

This is the system's file, not yours.

If I run lpoptions on the command line I get:

Run as a user?

  copies=1 device-uri=socket:// finishings=3 fitplot=true
job-cancel-after=10800 job-hold-until=no-hold job-priority=50
job-sheets=none,none marker-change-time=0 media=DRAFT number-up=1
page-bottom=54 page-left=54 page-right=54 page-top=54
printer-commands=AutoConfigure,Clean,PrintSelfTestPage printer-info='HP
Officejet Pro 8600' printer-is-accepting-jobs=true printer-is-shared=false
printer-location='Local Printer' printer-make-and-model='HP Officejet Pro
8600, hpcups 3.16.11' printer-state=3 printer-state-change-time=1503877259
printer-state-reasons=none printer-type=10522652

This display is for a default printer. In your case it would be expected
to be the system default.

A you can see, my printer is specifically called out. But if I run lp <file>
I get:

lp: Error - no default destination available.

Contradicts what is above.

I've tried to reinstall cups_client but that didn't help.

I have an almost identical system that is setup the same way and is not
having the problem.

Anyone have an idea what's causing this.

Not a clue! I do not experience it myself. What does 'lpstat -t' give?
Does 'lp -d Officejet_Pro_8600_N911a <file>' print? You could compare
logs for the "good" and "bad" systems: 'strace lp <file>'. Both systems
have the same cupsd.conf and both run cups-browsed?

Thank you for the response

lpstat -t gives:
scheduler is running
system default destination: Officejet_Pro_8600_N911a
device for Officejet_Pro_8600_N911a: socket://
Officejet_Pro_8600_N911a accepting requests since Mon 28 Aug 2017 05:24:28 PM PDT printer Officejet_Pro_8600_N911a is idle. enabled since Mon 28 Aug 2017 05:24:28 PM PDT

Yes 'lp -d Officejet_Pro_8600_N911a <file>' prints.
Just lp <file> gives: lp:Error - no default destination aviilable

running lpoptions print out, lists the proper url and name of the printer.

I have a virtual machine - also Debian Stretch - that acts the exact same way.

I have another computer with Stretch installed that works fine.

Vary confused.

Gary R