[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#883554: cups keeps breaking network printer with implicitclass:



On Tue, Dec 12, 2017 at 08:01:44PM +0000, Brian Potkin wrote:
> You cannot have two PPDs for the same queue.
> 
>  Canon_BJC-2100_remote.ppd 2015-11-29 00:33:04.432331311 -0600
> 
> is redundant; possibly a leftover from something. Move it out of the way
> or delete it.

I assumed it was left over, removed.

>  Canon_BJC-2100.ppd  2017-12-05 09:35:07.689792328 -0600
> 
> is probably the working PPD. Let's try
> 
> > > > > lpstat -t
> > > > > scheduler is running
> > > > > system default destination: Canon_BJC-2100
> > > > > device for Canon_BJC-2100: implicitclass:Canon_BJC-2100
> > > > > Canon_BJC-2100 accepting requests since Tue Dec  5 19:19:12 2017
> > > > > printer Canon_BJC-2100 is idle.  enabled since Tue Dec  5 19:19:12 2017
> > > > > 
> > > > > How about this sequence, I go through the web interface, change it to
> > > > > the ipps URI that works.  Verify in the browser it is the ipps URI,
> > > > > verify with `lpstat -t` it is ipps URI, wait until
> > > > > /etc/cups/printers.conf has the ipps DeviceURI, then.
> > > > > systemctl stop cups-browsed.service
> > > > > systemctl start cups-browsed.service
> > > > > and the browser immediately lists implicitclass:Canon_BJC-2100
> > > > 
> > > > I can now reproduce your observations, apart from the non-printing
> > > > aspect.
> > 
> > Do you get implicitclass:Canon_BJC-2100 ?
> 
> Yes, but only after restarting cups-browsed. And I still had printing.
> 
> [Snip]
> 
> Let's try this:
> 
> 1. Stop cups-browsed. 'systemctl stop cups-browsed'.
> 
> 2. 'lpadmin -x Canon_BJC-2100'.
lpadmin: The printer or class does not exist.
I'm thinking this is expected.

> 3. /etc/cups/ppd should now be empty and 'lpstat -t' should show no
>    print queues. Hopefully, the client is cleared of all knowledge
>    of the server.

Correct, /etc/cups/ppd is empty, web interface says no printers,
lpstat -t
scheduler is running
no system default destination
lpstat: No destinations added.
lpstat: No destinations added.
lpstat: No destinations added.
lpstat: No destinations added.

> 4. Restart cups-browsed. 'systemctl start cups-browsed'.

> 5. 'lpstat -t' should show a print queue with an implicitclass URI
>    which has automatically been set up by cups-browsed, There
>    should be a non-empty PPD in /etc/cups/ppd and you should be able
>    to print to the queue.

Does not print.

Correct it lists, implicitclass URI,
-rw-r----- 1 root lp 123838 Dec 14 01:13 /etc/cups/ppd/Canon_BJC-2100.ppd
echo "." | lpr -PCanon_BJC-2100

web interface:
State:
pending since
Thu Dec 14 01:45:13 2017 
"No destination host name supplied by cups-browsed for printer
"Canon_BJC-2100", is cups-browsed running?"	

==> /var/log/syslog <==
Dec 14 01:40:32 Homer systemd[1]: Started Make remote CUPS printers available locally.
Dec 14 01:40:32 Homer colord[682]: failed to get session [pid 27885]: No such device or address
Dec 14 01:42:37 Homer systemd[1]: Stopping Make remote CUPS printers available locally...
Dec 14 01:42:37 Homer systemd[1]: Stopped Make remote CUPS printers available locally.
Dec 14 01:43:41 Homer systemd[1]: Started Make remote CUPS printers available locally.
Dec 14 01:43:42 Homer colord[682]: failed to get session [pid 27885]: No such device or address

==> /var/log/cups/access_log <==
localhost - - [14/Dec/2017:01:43:41 -0600] "POST / HTTP/1.1" 200 349 Create-Printer-Subscriptions successful-ok
localhost - - [14/Dec/2017:01:43:41 -0600] "POST / HTTP/1.1" 200 176 Create-Printer-Subscriptions successful-ok
localhost - - [14/Dec/2017:01:43:42 -0600] "POST /admin/ HTTP/1.1" 401 124395 CUPS-Add-Modify-Printer successful-ok
localhost - root [14/Dec/2017:01:43:42 -0600] "POST /admin/ HTTP/1.1" 200 124395 CUPS-Add-Modify-Printer successful-ok
localhost - root [14/Dec/2017:01:43:42 -0600] "POST /admin/ HTTP/1.1" 200 187 CUPS-Add-Modify-Printer successful-ok
localhost - - [14/Dec/2017:01:45:13 -0600] "POST /printers/Canon_BJC-2100 HTTP/1.1" 200 354 Create-Job successful-ok
localhost - - [14/Dec/2017:01:45:13 -0600] "POST /printers/Canon_BJC-2100 HTTP/1.1" 200 243 Send-Document successful-ok

==> /var/log/cups/error_log <==
W [14/Dec/2017:01:43:42 -0600] CreateProfile failed: org.freedesktop.ColorManager.AlreadyExists:profile id \'Canon_BJC-2100-Gray..\' already exists
W [14/Dec/2017:01:43:42 -0600] CreateProfile failed: org.freedesktop.ColorManager.AlreadyExists:profile id \'Canon_BJC-2100-RGB..\' already exists
E [14/Dec/2017:01:45:34 -0600] [Job 1403] No destination host name supplied by cups-browsed for printer \"Canon_BJC-2100\", is cups-browsed running?

> 6. Now set up this queue:
>      lpadmin -p 2100 -v ipp://server_ip/print/queue_name -E -m raw

lpadmin -p ipps_Canon_BJC-2100 -v ipps://<server hostname>.local:631/printers/Canon_BJC-2100 -E -m raw

> 7. You should be able to print to both queues.

implicitclass is failing, ipps_Canon_BJC-2100 is printing.

ipps_Canon_BJC-2100 is working.  I'll have to try again tomorrow.

> [Snip]
> 
> I understand. Don't rush. If there is a bug it appears to be in
> cups-browsed. But I don't experience it - so I hope you can see
> my quandry.

As a data point, my dad has been finding out that it prints for a
little bit of time after he reboots the client.  I would assume it is
using the implicitclass entry, at least it only has the one queue when
I look at it and he's not going to be adding/removing printers.


Question, do you have the Canon BJC-2100 model printer?  We're running
with the replacement BC-20 ink cartridge, that's a black only
cartridge.  CUPS prints slow, as in the speed of printing only using
the nozzles of a color cartridge.  The default options in general is
Color Model: Grayscale, printer Features Common, Ink Type: Black, Ink
Set: Black.  Is there anything I'm missing?

lprng, magicfilter, and gs prints much faster, here's the line.
/etc/magicfilter/bj800-filter
filter  /usr/bin/gs  -q -dSAFER -dNOPAUSE -r360 -sDEVICE=bjc800 -dMonochromePrint=true -sOutputFile=- - -c quit

-- 
David Fries <david@fries.net>


Reply to: