GNOME Bugzilla – Bug 648784
entering ip address of network printer does nothing
Last modified: 2013-03-20 14:56:52 UTC
When I try to add a new network printer by ip address it does nothing when I click Add.
Is the printer shared by a CUPS server? If yes, does it have accessible PPD file (wget "ip-address/printers/printer.ppd") ?
Not sure, it is a HP/Jetdirect printer. Adding it with system-config-printers worked fine.
I had a similar problem. I wasn't able to add my network printer through the gnome-control-center but system-config printers worked fine. The printer is a Epson Stylus Office BX610FW. When trying to add it this was written to my CUPS access_log file localhost - - [29/Apr/2011:14:13:16 +0200] "POST / HTTP/1.1" 200 323 Create-Printer-Subscription successful-ok localhost - - [29/Apr/2011:14:13:26 +0200] "POST / HTTP/1.1" 401 75 CUPS-Get-Devices successful-ok localhost - root [29/Apr/2011:14:13:26 +0200] "POST / HTTP/1.1" 200 1875 CUPS-Get-Devices - localhost - - [29/Apr/2011:14:15:30 +0200] "POST / HTTP/1.1" 200 303 CUPS-Get-PPDs - localhost - - [29/Apr/2011:14:15:30 +0200] "POST / HTTP/1.1" 200 303 CUPS-Get-PPDs -
I have a LaserJet 5 network printer (it was not shared by a cups server) and, like Jan's comment #3, was unable to add it using gnome-control-center but was able to do it with system-config-printer or the cups web interface.
Hi, could you send me result of "lpinfo -l -v" (under root)? It is enough to cut the part which contains the requested printer. Regards Marek
[root@kusanagi jeff]# lpinfo -l -v Périphérique : uri = usb://Samsung/SCX-4x26%20Series class = direct info = Samsung SCX-4x26 Series make-and-model = Samsung SCX-4x26 Series device-id = MFG:Samsung;CMD:PCL5E,PCL6,GDI,FAX2,FWV;MDL:SCX-4x26 Series;CLS:PRINTER;MODE:FAX2;STATUS:BUSY; location = Périphérique : uri = http class = network info = Internet Printing Protocol (http) make-and-model = Unknown device-id = location = Périphérique : uri = scsi class = direct info = Imprimante SCSI make-and-model = Unknown device-id = location = Périphérique : uri = https class = network info = Internet Printing Protocol (https) make-and-model = Unknown device-id = location = Périphérique : uri = ipp class = network info = Internet Printing Protocol (ipp) make-and-model = Unknown device-id = location = Périphérique : uri = socket class = network info = AppSocket/HP JetDirect make-and-model = Unknown device-id = location = Périphérique : uri = lpd class = network info = Hôte ou imprimante LPD/LPR make-and-model = Unknown device-id = location = Périphérique : uri = socket://192.168.1.200 class = network info = HP LaserJet 5 make-and-model = HP LaserJet 5 device-id = MANUFACTURER:Hewlett-Packard;COMMAND SET:PJL,MLC,PCL,PCLXL;MODEL:HP LaserJet 5;CLASS:PRINTER;DESCRIPTION:Hewlett-Packard Lase location = (note that the laserjet and samsung printers are both currently set up correctly, don't know if this can affect this command's output)
Hi Jean, which version of gnome-control-center do you have? Does the printer show up even if you don't check the "Search by Address" button? It adds the HP LaserJet 5 successfully with control-center-3.0.1.1-6.fc15 for me. Marek
I'm having this problem as well with an HP PhotoSmart Premium printer. When I to go add the printer through the GNOME Control Center, I select "Network" and type the IP address and press Add and it simply returns me to the control panel. If I do it a few times the Control Center will crash. This is dumped to the console: ** GLib:ERROR:gvarianttypeinfo.c:186:g_variant_type_info_check: assertion failed: (0 <= index && index < 24) (Unsure if I should report this as a separate bug.) I attempted the wget command mentioned in comment #1: jim:~$ wget "192.168.1.10/printers/printer.ppd" --2011-05-13 12:14:43-- http://192.168.1.10/printers/printer.ppd Connecting to 192.168.1.10:80... connected. HTTP request sent, awaiting response... 404 Not Found 2011-05-13 12:14:43 ERROR 404: Not Found. And my result for lpinfo -l -v: Device: uri = scsi class = direct info = SCSI Printer make-and-model = Unknown device-id = location = Device: uri = ipp class = network info = Internet Printing Protocol (ipp) make-and-model = Unknown device-id = location = Device: uri = lpd class = network info = LPD/LPR Host or Printer make-and-model = Unknown device-id = location = Device: uri = http class = network info = Internet Printing Protocol (http) make-and-model = Unknown device-id = location = Device: uri = socket class = network info = AppSocket/HP JetDirect make-and-model = Unknown device-id = location = Device: uri = https class = network info = Internet Printing Protocol (https) make-and-model = Unknown device-id = location = I should also mention that when I attempt to add a printer, I'm only offered two choices in the list on the right: Local and Network. When I select Network the window on the right remains empty. It makes no difference if I select "Search by Address" or not.
Hi Jim, I see that your printer should be capable of publishing itself by mDNS protocol. Do you have avahi-daemon running? If not, could you start it and try adding the printer again? (just run "service avahi-daemon status" under root and if it is inactive then run "service avahi-daemon start"). Another problem is that g-c-c is not able to add HP/JetDirect printer if it is not published by the mDNS protocol. I work on it. Regards Marek
@Marek in comment #7: > Which version of gnome-control-center do you have? Same as yours, control-center-3.0.1.1-6.fc15 >Does the printer show up even if you don't check the "Search by Address" button? No, it never shows up under any circumstances.
Marek, After posting my comment I tried running system-config-printers and got the printer registered and working. One important thing happened that might have some bearing on this: When I ran system-config-printers, it reported that it needed to punch a hole in my firewall (of course, it didn't use this terminology). Once I agreed, it found the printer and I got it configured. When I returned to the GNOME control center, it showed the printer and I was able to configure it. I don't know that the firewall thing is the missing puzzle piece here, but it sure seems relevant. -- Jim
I was going to say that I think this (turning on mdns) is better off in a 'privacy and sharing' panel, but the designers seem to think that printer sharing/discovery is not really in scope for that, see https://live.gnome.org/Design/SystemSettings/PrivacyAndSharing so maybe it _would_ be ok to just turn it on from the printer panel when necessary. Would still be good to get some design input on how that might look in detail (warning or not, what to say, etc...)
*** Bug 652208 has been marked as a duplicate of this bug. ***
I have a similar problem with a HP Laserjet 3390. I can add it, but in the Control Center panel on IP Address field, it's write "Localhost".
Created attachment 190347 [details] [review] enable services on firewall Hi, this patch implements enabling of required services on firewall. It enables mdns, ipp, ipp-client and samba-client services for 5 minutes just for detection. After that, it enables services needed by added printer permanently. It informs user about these steps. It is implemented using DBus API of FirewallD, which is not default firewall yet, so you have to install it and enable it. This is just a proposal, it needs some work still (e.g. improvement of texts, asynchronous DBus calls, ...). Don't review the code yet. Regards Marek
Created attachment 190921 [details] screenshots Hi, I've created few screenshots to show how does it work. The upper right screenshot and lower left screenshot show the situation when the FirewallD is available and no required service is enabled. It tells you that it enables these services temporarily (for 5 minutes) before getting devices and that it enables the requested services permanently after the user selects a printer and press Add. The lower right screenshot show the situation when FirewallD is not installed (or running). It informs you that you need to enable the listed services. Suggestions are welcomed. Marek
My immediate reaction is that we probably want to avoid the dialog-on-top-of-dialog-on-top-of-window situation, and maybe just show the information in the status area of the dialog, where you already have a spinner. Plus, the generic warning icon does stick out a bit. Anyway, just quick impressions.
Maybe we need a Cancel button somewhere so the user can stop enabling those services on firewall (it doesn't ask me for a password here...).
Created attachment 191090 [details] [review] modified patch
Created attachment 191091 [details] screenshot of warning about missing firewalld
Created attachment 191092 [details] screenshot of notification about enablement of mDNS service on firewall
Some feedback on the first screenshot: - there should be some padding around the text, not sure about the exact amount - there's also some missing padding between the grey/white box and the address entry - the background of the right hand side should be white not grey - I also wonder if the address entry and checkbox should be insensitive if search is not possible - we can find out if the required services are running, right ?
Adding to Matthias' comments: - there should be a shadow around the scrolled areas for increased contrast/cleanliness. Something like gtk.ScrolledWindow.set_shadow_type(gtk.SHADOW_IN) (I know this is python, but just for the sake of the example) - The "Address" label shoud probably be "Address:" and left-aligned, while the text entry expands
Created attachment 191960 [details] firewall warning Hi, this picture shows a modified version of the patch. The text is shown in a new GtkTextView so it can have padding and is on white background. I didn't place there the Address thing since we need to tell this to user and showing a mix of warning and discovered printers would be confusing. But this forces user to use firewalld as a firewall solution. Another thing is that we can not find out whether there is a firewall configured since we don't have permissions to view the configuration. Hence I can not say whether the computer has a firewall or not (except for the firewalld). Regards Marek
Created attachment 191962 [details] picture showing padding This picture shows added vertical padding and setting of alignment for the "Address" label.
These look much better, thanks.
When I'm thinking more about this, I see that the warning should be just informational and shouldn't block showing of discovered printers :(. Since we tell user that we need those services enabled on firewall, he can do it manually and then he expects to be able to add new printers. Maybe we need an "OK" button which will remove the warning (but this makes it similar to the GtkMessageDialog, only embedded) or a GtkCheckBox "Don't show me again" (but we have to solve storing of the information between runs of the Control Center). What do you think? Regards Marek
(In reply to comment #27) > What do you think? > I think closing the dialog and trying again should be good enough for the 'opened firewall manually' case.
Created attachment 192456 [details] [review] patch enabling services on firewall + showing warning message if needed Hi, this is a patch which I would like to commit to master. It enables services mdns, ipp, ipp-client and samba-client on firewall for 5 minutes for detection. It enables required services permanently for printers selected by user for addition then. It shows a notification for the permanent enable only. It uses firewalld, so if it is not installed or running it shows a warning message to the user in the place where discovered printers will be shown (both local and network). The warning disappears after the finish of printers discovery (but not from network part if no printer was found). Regards Marek
Review of attachment 192456 [details] [review]: Looks good enough to commit with the _() additions below. ::: panels/printers/pp-new-printer-dialog.c @@ +1632,3 @@ + g_str_has_prefix (pp->devices[device_id].device_uri, "mdns:")) + { + show_notification ("Enabling service mDNS on firewall", Needs _() ? Also, the wording could be improved. I don't have a concrete proposal, though. One thing that occurs to me is that it would be slightly more natural to have the firewall service itself show a notification when a hole gets opened programmatically (of course, you don't want to see those bubbles when you are using s-c-firewall to configure your firewall). For now, keeping the notifications here is certainly ok. @@ +1641,3 @@ + if (g_strrstr (pp->devices[device_id].device_uri, "smb:") != NULL) + { + show_notification ("Enabling service Samba Client on firewall", Same here: _(), again the wording could be improved. 'Allowing outgoing Samba connections' ? @@ +1652,3 @@ + show_notification ("Enabling services IPP and IPP Client on firewall", + NULL, + "dialog-information-symbolic"); Again: _(). Wording could be improved. 'Opening firewall for IPP connections' ?
Hi, thank you for your comment Matthias. I made the changes you've mentioned and committed the patch to master. I used the "Opening firewall for * connections" form of notifications. It appears best to me. Regards Marek
I'm closing this bug, since entering IP address of network printer adds printer now. If it doesn't work for you then open a new bug please. Marek
What version is it fixed in? It didn't work for me in F16.
Does it show you the message with FirewallD when you are adding the printer?
Does it show the printer which you want to add in the list of available printers?
Discussed this with Marek. I think we need to remove all the poking of firewalls and warning about firewalld from the code. We need to ensure that distros don't ship broken firewall rules. Or that when you enable a service you also enable it at the firewall. We have another bug for improving the design of the add printer dialog. Probably can close this once we remove that code, right?
I think we should probably do this together with the other printer panel design improvements in 3.5. 3.4 is pretty much done at this point.
Hi everyone, Same problem with Ubuntu Gnome Remix 12.10 64 bits + Gnome 3 ppa. Indeed, I've never been able to add my old HP Deskjet 815C connected to my wireless router to Gnome with the printer applet. And also for me, system-config-printers works just fine.
(In reply to comment #36) > Discussed this with Marek. I think we need to remove all the poking of > firewalls and warning about firewalld from the code. We need to ensure that > distros don't ship broken firewall rules. Or that when you enable a service you > also enable it at the firewall. > > We have another bug for improving the design of the add printer dialog. > > Probably can close this once we remove that code, right? The code for poking firewall was removed and the new design has been implemented in 3.6.0. I'm closing this. Thank you all for your help