X
Tap here to go to the mobile version of the site.

Support Forum

How can I stop firefox from auto discovering printers on fedora?

Posted

On Linux Fedora (19 & 20 at least, likely others) Firefox automatically finds network attached printers, completely independently of CUPS. The printer it finds for me is legitimate, but it doesn't install drivers to make it work correctly. If this printer is used, it will print out gibberish; sometimes PDF control language, other times total junk. It won't render the page right, and wastes tons of paper.

Thanks!

On Linux Fedora (19 & 20 at least, likely others) Firefox automatically finds network attached printers, completely independently of CUPS. The printer it finds for me is legitimate, but it doesn't install drivers to make it work correctly. If this printer is used, it will print out gibberish; sometimes PDF control language, other times total junk. It won't render the page right, and wastes tons of paper. Thanks!

Chosen solution

Thanks.

I have found that avahi-daemon is the culprit. I just did a fresh install of Fedora 20. I did not set up any printers, yet the "bad" printer showed up in the printer list in Firefox. After I stopped avahi-daemon and avahi-daemon.socket, the printer went away.

I also noticed with my Fedora 19 installation, the bad printer went away if I put my computer on a different subnet.

So next step is to figure out how to configure avahi to not behave this way when it is running.

I appreciate your help.

    • Post Script **

I looked at what documentation I could find on avahi, but there didn't seem to be any sort of setting to ignore a particular host. However, after some probing, I found the right setting on my Lexmark E260DN to change. Under TCP/IP settings, there is a check box for 'mDNS.' The default is on. Once I turned it off, that solved the problem, allowing me to safely re-enable avahi on my computer. I had looked for something like this earlier, but missed it, as I was looking for such things as 'bonjour', 'zeroconf', 'SD-DNS', or something similar.

Read this answer in context 1

Additional System Details

Installed Plug-ins

  • Shockwave Flash 11.9 r900
  • Google Update
  • Adobe PDF Plug-In For Firefox and Netscape 11.0.06
  • Next Generation Java Plug-in 10.45.2 for Mozilla browsers
  • NPRuntime Script Plug-in Library for Java(TM) Deploy
  • iTunes Detector Plug-in
  • 5.1.20913.0
  • RealPlayer(tm) LiveConnect-Enabled Plug-In
  • RealPlayer Download Plugin
  • RealNetworks(tm) RealDownloader Chrome Background Extension Plug-In
  • RealNetworks(tm) RealDownloader PepperFlashVideoShim Plug-In
  • RealNetworks(tm) RealDownloader HTML5VideoShim Plug-In
  • RealDownloader Plugin
  • Yahoo Application State Plugin version 1.0.0.7
  • Picasa plugin

Application

  • User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:26.0) Gecko/20100101 Firefox/26.0

More Information

guigs 1072 solutions 11697 answers

Hi beckolamuffin,

Thank you for posting your question. So, you would like to know why printers are found automatically and the drivers are not automatically installed and you would like to stop firefox from auto-discovering printers.

Questions:

Troubleshooting Firefox

  • Fix printing problems in Firefox
  • Preview the item before you print it, does the garbled info appear in the preview? View PDF files in Firefox
  • CUPS overrides the client.conf file for the printing preferences, is the CUPS server overiding preferences set in firefox? this would be checked in a new profile.
Hi beckolamuffin, Thank you for posting your question. So, you would like to know why printers are found automatically and the drivers are not automatically installed and you would like to stop firefox from auto-discovering printers. Questions: * Does this also occur in other applications that uses the printers? *Does the Configuration Tool help? : [http://fedoraproject.org/wiki/How_to_debug_printing_problems#Application] Troubleshooting Firefox *[[Fix printing problems in Firefox]] *Preview the item before you print it, does the garbled info appear in the preview? [[View PDF files in Firefox without downloading them]] *CUPS overrides the client.conf file for the printing preferences, is the CUPS server overiding preferences set in firefox? this would be checked in a new profile.

Question owner

Hi Guigs2:

Thanks for your reply and clarifying questions. Here are my answers:

  • Does this also occur in other applications?

Yes and no. Originally I thought only in Firefox this showed up, but just tried a few more programs. The "bad" printer does not show up in Google Chrome or in Libre Office. But it does show up in gedit.

  • Does the configuration tool help?

No. The "bad" printer doesn't show up in the fedora print configuration function (settings->printers-> etc). CUPS and lpstat are totally unaware of the bad printer.

  • Do the tips in fix printing problems in Firefox help?

No. The bad printer doesn't show up anywhere in the about:config settings, and neither resetting printer settings nor editing the prefs.js file make a difference.

  • Does print preview work OK?

Yes

  • Are the CUPS server overriding preferences set in firefox?

I don't think so. CUPS isn't aware of the bad printer. client.conf is empty. I don't see anything that indicates this is happening.

I am attaching a screen shot of what my printer list looks like in firefox (and gedit). The highlighted printer at the bottom is the good printer. The one above it is the bad printer.

Thanks again!

Erik

Hi Guigs2: Thanks for your reply and clarifying questions. Here are my answers: *Does this also occur in other applications? Yes and no. Originally I thought only in Firefox this showed up, but just tried a few more programs. The "bad" printer does not show up in Google Chrome or in Libre Office. But it does show up in gedit. *Does the configuration tool help? No. The "bad" printer doesn't show up in the fedora print configuration function (settings->printers-> etc). CUPS and lpstat are totally unaware of the bad printer. *Do the tips in fix printing problems in Firefox help? No. The bad printer doesn't show up anywhere in the about:config settings, and neither resetting printer settings nor editing the prefs.js file make a difference. *Does print preview work OK? Yes *Are the CUPS server overriding preferences set in firefox? I don't think so. CUPS isn't aware of the bad printer. client.conf is empty. I don't see anything that indicates this is happening. I am attaching a screen shot of what my printer list looks like in firefox (and gedit). The highlighted printer at the bottom is the good printer. The one above it is the bad printer. Thanks again! Erik
guigs 1072 solutions 11697 answers

Ok I looked for the driver for this printer, but you said they do not install correctly. I also found this Linux forum http://www.openprinting.org/printer/L.../Lexmark-E260dn but it was not listed in the driver listhttp://www.openprinting.org/drivers

I also found this printer works in LibreOffice but https://bugs.freedesktop.org/show_bug.cgi?id=33791 again not helpful.

The ppd file for your printer is below:

https://www.openprinting.org/ppd-o-matic.php?driver=Postscript&pr...

Manually adding the printer if it does not detect after the post script: Reference for technical instructions and example below: http://kb.mozillazine.org/PostScript_Module

(in about:config and prefs.js) and not a separate file.

To add a preference, you can use about:config or you can manually edit the prefs.js text file. Note that prefs.js is updated when Firefox shuts down, so you should close Firefox before editing it. Mine has this line:

user_pref("print_printer", "PDFCreator");

Ok I looked for the driver for this printer, but you said they do not install correctly. I also found this Linux forum [http://www.openprinting.org/printer/Lexmark/Lexmark-E260dn] but it was not listed in the driver list[http://www.openprinting.org/drivers] I also found this printer works in LibreOffice but [https://bugs.freedesktop.org/show_bug.cgi?id=33791] again not helpful. ***Then I found that a postscript is needed for this particular printer, instructions for this can be found [https://www.openprinting.org/driver/Postscript/] The ppd file for your printer is below: [https://www.openprinting.org/ppd-o-matic.php?driver=Postscript&printer=Lexmark-E260&.submit=Generate+PPD+file&show=1&.cgifields=show&.cgifields=shortgui] Manually adding the printer if it does not detect after the post script: Reference for technical instructions and example below: [http://kb.mozillazine.org/PostScript_Module] (in about:config and prefs.js) and not a separate file. To add a preference, you can use about:config or you can manually edit the prefs.js text file. Note that prefs.js is updated when Firefox shuts down, so you should close Firefox before editing it. Mine has this line: user_pref("print_printer", "PDFCreator");

Question owner

guigs2:

Thanks for your help on this. I think the problem is not with Firefox, since gedit also has the problem, but with a lower level. Either with gnome or dns-sd. I can install the correct printer drivers for my Lexmark, and get things to print correctly on the right printer entry. The problem is that if one accidentally uses the wrong printer entry, things don't work well, paper is wasted, and the printer can jam when trying to fix it. This is a small problem with a single-user system, but when wife and kids also use it, it is a bigger problem.

I have determined that the basic issue is that when the wrong printer entry is selected, the one that CUPS and the Gnome printer manager aren't aware of, the computer sends a raw PDF stream to the printer, and it can't interpret it. It tries to print as plain text, and a PDF stream usually has non-printing binary stuff in it. So this doesn't work. The printer expects to see one of the following:

  • Postscript
  • HP PCL
  • Plain ASCII text

A PDF stream is none of these.

I will change focus and see if there is a way to get DNS-SD (AVAHI?) to ignore the printer.

Thanks again!

guigs2: Thanks for your help on this. I think the problem is not with Firefox, since gedit also has the problem, but with a lower level. Either with gnome or dns-sd. I can install the correct printer drivers for my Lexmark, and get things to print correctly on the right printer entry. The problem is that if one accidentally uses the wrong printer entry, things don't work well, paper is wasted, and the printer can jam when trying to fix it. This is a small problem with a single-user system, but when wife and kids also use it, it is a bigger problem. I have determined that the basic issue is that when the wrong printer entry is selected, the one that CUPS and the Gnome printer manager aren't aware of, the computer sends a raw PDF stream to the printer, and it can't interpret it. It tries to print as plain text, and a PDF stream usually has non-printing binary stuff in it. So this doesn't work. The printer expects to see one of the following: *Postscript *HP PCL *Plain ASCII text A PDF stream is none of these. I will change focus and see if there is a way to get DNS-SD (AVAHI?) to ignore the printer. Thanks again!
guigs 1072 solutions 11697 answers

Helpful Reply

Not a problem, though I am not sure DNS-SD, try starting a new thread. Doing so will allow the Mozilla volunteers to give you solutions that are more helpful to you. This may help them to solve your problem faster and more efficiently.

Please, feel free to post the link to your thread on this thread for volunteers interested in assisting you.

Thank you.

Not a problem, though I am not sure DNS-SD, try starting a new thread. Doing so will allow the Mozilla volunteers to give you solutions that are more helpful to you. This may help them to solve your problem faster and more efficiently. Please, feel free to post the link to your thread on this thread for volunteers interested in assisting you. Thank you.

Chosen Solution

Thanks.

I have found that avahi-daemon is the culprit. I just did a fresh install of Fedora 20. I did not set up any printers, yet the "bad" printer showed up in the printer list in Firefox. After I stopped avahi-daemon and avahi-daemon.socket, the printer went away.

I also noticed with my Fedora 19 installation, the bad printer went away if I put my computer on a different subnet.

So next step is to figure out how to configure avahi to not behave this way when it is running.

I appreciate your help.

    • Post Script **

I looked at what documentation I could find on avahi, but there didn't seem to be any sort of setting to ignore a particular host. However, after some probing, I found the right setting on my Lexmark E260DN to change. Under TCP/IP settings, there is a check box for 'mDNS.' The default is on. Once I turned it off, that solved the problem, allowing me to safely re-enable avahi on my computer. I had looked for something like this earlier, but missed it, as I was looking for such things as 'bonjour', 'zeroconf', 'SD-DNS', or something similar.

Thanks. I have found that avahi-daemon is the culprit. I just did a fresh install of Fedora 20. I did not set up any printers, yet the "bad" printer showed up in the printer list in Firefox. After I stopped avahi-daemon and avahi-daemon.socket, the printer went away. I also noticed with my Fedora 19 installation, the bad printer went away if I put my computer on a different subnet. So next step is to figure out how to configure avahi to not behave this way when it is running. I appreciate your help. ** Post Script ** I looked at what documentation I could find on avahi, but there didn't seem to be any sort of setting to ignore a particular host. However, after some probing, I found the right setting on my Lexmark E260DN to change. Under TCP/IP settings, there is a check box for 'mDNS.' The default is on. Once I turned it off, that solved the problem, allowing me to safely re-enable avahi on my computer. I had looked for something like this earlier, but missed it, as I was looking for such things as 'bonjour', 'zeroconf', 'SD-DNS', or something similar.

Modified by beckolamuffin