Network printer suddenly stopped working, cannot be accessed using zeroconf anymore

Bug #1959850 reported by Frantisek Fuka
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
cups (Ubuntu)
New
Undecided
Unassigned

Bug Description

I have a HP OfficeJet 9022e network printer which worked flawlessly until recently. Today I found out that I am no longer able to print on it from both my Xubuntu PCs. I removed the printer and I tried to add it again but this also did not work. Regardless of the way I tried adding it (GUI / command line / CUPS web interface), the printer either could not be added or could not be printed to. During further research I narrowed the problem down :

Entering this command:

driverless

...produces the following correct output:

ipp://BonjourHPOfficeJetPro9022e._ipp._tcp.local/

However, subsequently entering this command:

avahi-resolve -n ipp://BonjourHPOfficeJetPro9022e._ipp._tcp.local/

...produces this error:

Failed to resolve host name 'ipp://BonjourHPOfficeJetPro9022e._ipp._tcp.local/': DNS failure: NXDOMAIN

Manually adding the printer by its IP address (currently 192.168.69.245) worked flawlessly.

Scanning from the printer using simple-scan still worked flawlessly, as it did before. In simple-scan, the printer shows as "ESCL BonjourHPOfficeJetPro9022e".

What I did between the time the printer worked flawlessly and today:

* I updated both my PCs to the latest XUbuntu LTS version (20.04.1)
* I updated, factory reset and reconfigured my home router (Turris Omnia). However, the IP address range is the same as before (192.168.69.xxx) and the IP address of the printer is still assigned dynamically, the same way as it was before (when the printer worked)

SOLUTION: After several hours I found the following solution of the problem:

In the /etc/nsswitch.conf file, I had to change the line beginning with "hosts: files" to this:

hosts: files mymachines mdns4_minimal [NOTFOUND=return] resolve [!UNAVAIL=return] dns mdns4 myhostname

This line originally looked like this:

hosts: files mdns4_minimal [NOTFOUND=return] dns

Then, I had to create the (non-existent) file /etc/mdns.allow with these 2 lines:

.local.
.local

Then I restarted the avahi-daemon service and printing works flawlessly again.

Note that until today, I had no idea that /etc/nsswitch.conf file exists and that avahi-daemon service somehow relates to printing. I have no idea why this solution works and whether it's the best solution, but it was the first workable solution I found after 4 hours of Googling.

Tags: bot-comment
Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote :

Thank you for taking the time to report this bug and helping to make Ubuntu better. It seems that your bug report is not filed about a specific source package though, rather it is just filed against Ubuntu in general. It is important that bug reports be filed about source packages so that people interested in the package can find the bugs about it. You can find some hints about determining what package your bug might be about at https://wiki.ubuntu.com/Bugs/FindRightPackage. You might also ask for help in the #ubuntu-bugs irc channel on Freenode.

To change the source package that this bug is filed about visit https://bugs.launchpad.net/ubuntu/+bug/1959850/+editstatus and add the package name in the text box next to the word Package.

[This is an automated message. I apologize if it reached you inappropriately; please just reply to this message indicating so.]

tags: added: bot-comment
affects: ubuntu → cups (Ubuntu)
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.