Page 2 of 5 FirstFirst 1234 ... LastLast
Results 11 to 20 of 49

Thread: Configuring the firewall so that hp-setup can find network printers

  1. #11
    Join Date
    Jun 2020
    Posts
    25

    Default Re: Configuring the firewall so that hp-setup can find network printers

    Quote Originally Posted by deano_ferrari View Post
    Try adding the following direct rule for IPv4 multicast packets...
    Code:
    sudo firewall-cmd --permanent --direct --add-rule ipv4 filter INPUT 0 -m pkttype --pkt-type multicast -j ACCEPT
    sudo firewall-cmd --reload
    Thank you. Yes, I saw that other thread (I linked to it in my initial post). There the solution was to open a hard firewall exception for a single IP address, in a home setting that's probably fine, but I'm moving from network to network (and from printer to printer) and I would prefer to get it working as intended

    I was also thinking that maybe multicast (which I know almost nothing about) is the issue, however that doesn't seem to work - hp-setup still does not see the printer not using mDNS or SLP, only using "avahi":

    Code:
    # hp-setup
    
    HP Linux Imaging and Printing System (ver. 3.19.12)
    Printer/Fax Setup Utility ver. 9.0
    
    Copyright (c) 2001-18 HP Development Company, LP
    This software comes with ABSOLUTELY NO WARRANTY.
    This is free software, and you are welcome to distribute it
    under certain conditions. See COPYING file for more details.
    
    QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root'
    Searching... (bus=net, timeout=5, ttl=4, search=(None) desc=0, method=slp)
    error: No devices found on bus: net
    error:  HPLIP cannot detect printers in your network.  This may be due to existing firewall settings blocking the required ports.
                    When you are in a trusted network environment, you may open the ports for network services like mdns and slp in the firewall. For detailed steps follow the link.
                     http://hplipopensource.com/node/374  
    Searching... (bus=net, timeout=5, ttl=4, search=(None) desc=0, method=mdns)
    error: No devices found on bus: net
    error:  HPLIP cannot detect printers in your network.  This may be due to existing firewall settings blocking the required ports.
                    When you are in a trusted network environment, you may open the ports for network services like mdns and slp in the firewall. For detailed steps follow the link.
                     http://hplipopensource.com/node/374  
    Searching... (bus=net, timeout=5, ttl=4, search=(None) desc=0, method=avahi)
      
    Done.
    
    Here is my firewall configuration:

    Code:
    # firewall-cmd --list-all
    home (active)
      target: default
      icmp-block-inversion: no
      interfaces: wlan0
      sources:  
      services: dhcpv6-client mdns samba-client slp ssh
      ports: 5353/udp
      protocols: igmp
      masquerade: no
      forward-ports:  
      source-ports:  
      icmp-blocks:  
      rich rules: 
    # firewall-cmd --direct --get-all-rules
    ipv4 filter INPUT 0 -m pkttype --pkt-type multicast -j ACCEPT
    ipv6 filter INPUT 0 -m pkttype --pkt-type multicast -j ACCEPT
    
    Interesting that mDNS in hp-setup doesn't work, but Avahi does:
    Code:
    # avahi-browse -at  
    +  wlan0 IPv6 HP OfficeJet Pro 8710 [AD5ECE]                _uscans._tcp         local
    +  wlan0 IPv4 HP OfficeJet Pro 8710 [AD5ECE]                _uscans._tcp         local
    +  wlan0 IPv6 HP OfficeJet Pro 8710 [AD5ECE]                _privet._tcp         local
    +  wlan0 IPv4 HP OfficeJet Pro 8710 [AD5ECE]                _privet._tcp         local
    +  wlan0 IPv6 HP OfficeJet Pro 8710 [AD5ECE]                Secure Internet Printer local
    +  wlan0 IPv4 HP OfficeJet Pro 8710 [AD5ECE]                Secure Internet Printer local
    +  wlan0 IPv6 HP OfficeJet Pro 8710 [AD5ECE]                _uscan._tcp          local
    +  wlan0 IPv4 HP OfficeJet Pro 8710 [AD5ECE]                _uscan._tcp          local
    +  wlan0 IPv6 HP OfficeJet Pro 8710 [AD5ECE]                _http-alt._tcp       local
    +  wlan0 IPv4 HP OfficeJet Pro 8710 [AD5ECE]                _http-alt._tcp       local
    +  wlan0 IPv6 HP OfficeJet Pro 8710 [AD5ECE]                _scanner._tcp        local
    +  wlan0 IPv4 HP OfficeJet Pro 8710 [AD5ECE]                _scanner._tcp        local
    +  wlan0 IPv6 HP OfficeJet Pro 8710 [AD5ECE]                Web Site             local
    +  wlan0 IPv4 HP OfficeJet Pro 8710 [AD5ECE]                Web Site             local
    +  wlan0 IPv6 HP OfficeJet Pro 8710 [AD5ECE]                Internet Printer     local
    +  wlan0 IPv4 HP OfficeJet Pro 8710 [AD5ECE]                Internet Printer     local
    +  wlan0 IPv6 HP OfficeJet Pro 8710 [AD5ECE]                PDL Printer          local
    +  wlan0 IPv4 HP OfficeJet Pro 8710 [AD5ECE]                PDL Printer          local
    +  wlan0 IPv6 HP OfficeJet Pro 8710 [AD5ECE]                UNIX Printer         local
    +  wlan0 IPv4 HP OfficeJet Pro 8710 [AD5ECE]                UNIX Printer         local
    (some other devices omitted)
    I wonder whethere there is some more SLP-specific multicast configuration I need to do, or am I missing something in my firewall config?

  2. #12
    Join Date
    Jun 2008
    Location
    Auckland, NZ
    Posts
    21,948
    Blog Entries
    1

    Default Re: Configuring the firewall so that hp-setup can find network printers

    Quote Originally Posted by rxmd View Post
    Thank you. Yes, I saw that other thread (I linked to it in my initial post). There the solution was to open a hard firewall exception for a single IP address, in a home setting that's probably fine, but I'm moving from network to network (and from printer to printer) and I would prefer to get it working as intended

    I was also thinking that maybe multicast (which I know almost nothing about) is the issue, however that doesn't seem to work - hp-setup still does not see the printer not using mDNS or SLP, only using "avahi":
    DNS-SD (same port as mDNS) is used by many printers to advertise their presence in a network. All part of the Avahi implementation. The 'avahi-browse' output shows that it is working, so not a firewall issue at all. You don't need to include port 5353 explicitly, as the 'mdns' firewalld service provides that configuration, and is all that should be needed. (SLP should not really be required at all.)
    openSUSE Leap 15.2; KDE Plasma 5

  3. #13
    Join Date
    Jun 2008
    Location
    Auckland, NZ
    Posts
    21,948
    Blog Entries
    1

    Default Re: Configuring the firewall so that hp-setup can find network printers

    It would be interesting to see if the network printer is enumerated using DNS-SD via these two commands...
    Code:
    sudo lpinfo -l -v
    Code:
    sudo hp-check -t
    openSUSE Leap 15.2; KDE Plasma 5

  4. #14
    Join Date
    Jun 2020
    Posts
    25

    Default Re: Configuring the firewall so that hp-setup can find network printers

    [QUOTE=deano_ferrari;2939053]It would be interesting to see if the network printer is enumerated using DNS-SD via these two commands...
    Code:
    sudo lpinfo -l -v
    Here it is enumerated, but that may be because hp-setup has set up a print queue for it?

    Code:
    $sudolpinfo -l -v
    Gerät: URI = beh
           Klasse = network
           Info = Backend Error Handler
           Hersteller-und-Modell = Unknown
           Geräte-ID =  
           Standort =  
    Gerät: URI = beh.pl
           Klasse = network
           Info = Backend Error Handler
           Hersteller-und-Modell = Unknown
           Geräte-ID =  
           Standort =  
    Gerät: URI = pipe
           Klasse = direct
           Info = Forward print job data like a pipe to another command
           Hersteller-und-Modell = Unknown
           Geräte-ID =  
           Standort =  
    Gerät: URI = ipp
           Klasse = network
           Info = Internet Printing Protocol (ipp)
           Hersteller-und-Modell = Unknown
           Geräte-ID =  
           Standort =  
    Gerät: URI = hp
           Klasse = direct
           Info = HP Printer (HPLIP)
           Hersteller-und-Modell = Unknown
           Geräte-ID =  
           Standort =  
    Gerät: URI = smb
           Klasse = network
           Info = Windows Printer via SAMBA
           Hersteller-und-Modell = Unknown
           Geräte-ID =  
           Standort =  
    Gerät: URI = lpd
           Klasse = network
           Info = LPD/LPR-Host oder -Drucker
           Hersteller-und-Modell = Unknown
           Geräte-ID =  
           Standort =  
    Gerät: URI = https
           Klasse = network
           Info = Internet Printing Protocol (https)
           Hersteller-und-Modell = Unknown
           Geräte-ID =  
           Standort =  
    Gerät: URI = http
           Klasse = network
           Info = Internet Printing Protocol (http)
           Hersteller-und-Modell = Unknown
           Geräte-ID =  
           Standort =  
    Gerät: URI = ipps
           Klasse = network
           Info = Internet Printing Protocol (ipps)
           Hersteller-und-Modell = Unknown
           Geräte-ID =  
           Standort =  
    Gerät: URI = socket
           Klasse = network
           Info = AppSocket/HP JetDirect
           Hersteller-und-Modell = Unknown
           Geräte-ID =  
           Standort =  
    Gerät: URI = hpfax
           Klasse = direct
           Info = HP Fax (HPLIP)
           Hersteller-und-Modell = Unknown
           Geräte-ID =  
           Standort =  
    Gerät: URI = dnssd://HP%20OfficeJet%20Pro%208710%20%5BAD5ECE%5D._ipp._tcp.local/?uuid=1c852a4d-b800-1f08-abcd-b4b686ad5ece
           Klasse = network
           Info = HP OfficeJet Pro 8710 [AD5ECE]
           Hersteller-und-Modell = HP OfficeJet Pro 8710
           Geräte-ID = MFG:HP;MDL:OfficeJet Pro 8710;CMD:PCL,JPEG,URF,PWG;
           Standort =  
    Gerät: URI = ipp://HP%20OfficeJet%20Pro%208710%20%5BAD5ECE%5D._ipp._tcp.local/
           Klasse = network
           Info = HP OfficeJet Pro 8710 (driverless)
           Hersteller-und-Modell = HP OfficeJet Pro 8710
           Geräte-ID = MFG:HP;MDL:OfficeJet Pro 8710;CMD:PCLM,PCL,PWGRaster,AppleRaster,JPEG,URF,PWG;
           Standort =  
    Should I remove the two CUPS print queues for it (for printing and fax) and try again?

    Quote Originally Posted by deano_ferrari View Post
    Code:
    sudo hp-check -t
    Here I get a bunch of error messages related to missing libraries:

    Code:
    $sudohp-check -t                                                                                                     
    /usr/bin/hp-check:685: SyntaxWarning: "is not" with a literal. Did you mean "!="?
      if 'getfacl' not in g and '' is not g and 'file' not in g:
    Saving output in log file: /home/reichmuth/hp-check.log
    
    HP Linux Imaging and Printing System (ver. 3.19.12)
    Dependency/Version Check Utility ver. 15.1
    
    Copyright (c) 2001-18 HP Development Company, LP
    This software comes with ABSOLUTELY NO WARRANTY.
    This is free software, and you are welcome to distribute it
    under certain conditions. See COPYING file for more details.
    
    Note: hp-check can be run in three modes:
    1. Compile-time check mode (-c or --compile): Use this mode before compiling the HPLIP supplied tarball (.tar.gz or .run) to  
    determine if the proper dependencies are installed to successfully compile HPLIP.                                             
    2. Run-time check mode (-r or --run): Use this mode to determine if a distro supplied package (.deb, .rpm, etc) or an already
    built HPLIP supplied tarball has the proper dependencies installed to successfully run.                                       
    3. Both compile- and run-time check mode (-b or --both) (Default): This mode will check both of the above cases (both         
    compile- and run-time dependencies).                                                                                          
    
    Check types:                                                                                                                  
    a. EXTERNALDEP - External Dependencies                                                                                        
    b. GENERALDEP - General Dependencies (required both at compile and run time)                                                  
    c. COMPILEDEP - Compile time Dependencies                                                                                     
    d. [All are run-time checks]                                                                                                  
    PYEXT SCANCONF QUEUES PERMISSION                                                                                              
    
    Status Types:
        OK
        MISSING       - Missing Dependency or Permission or Plug-in
        INCOMPAT      - Incompatible dependency-version or Plugin-version
    
    warning: 3-20200621 version is not supported. Using 3-15.1 versions dependencies to verify and install...
    
    ---------------
    | SYSTEM INFO |
    ---------------
    
     Kernel: 5.7.1-1-default #1 SMP Wed Jun 10 11:53:46 UTC 2020 (6a549f6) GNU/Linux
     Host: calypso
     Proc: 5.7.1-1-default #1 SMP Wed Jun 10 11:53:46 UTC 2020 (6a549f6) GNU/Linux
     Distribution: 3 20200621
     Bitness: 64 bit
    
    
    -----------------------
    | HPLIP CONFIGURATION |
    -----------------------
    
    HPLIP-Version: HPLIP 3.19.12
    HPLIP-Home: /usr/share/hplip
    warning: HPLIP-Installation: Auto installation is not supported for 3 distro  20200621 version  
    
    Current contents of '/etc/hp/hplip.conf' file:
    # hplip.conf.  Generated from hplip.conf.in by configure.
    
    [hplip]
    version=3.19.12
    
    [dirs]
    home=/usr/share/hplip
    run=/var/run
    ppd=/usr/share/cups/model/manufacturer-PPDs/hplip
    ppdbase=/usr/share/cups/model/manufacturer-PPDs
    doc=/usr/share/doc/packages/hplip
    html=/usr/share/doc/packages/hplip
    icon=/usr/share/applications
    cupsbackend=/usr/lib/cups/backend
    cupsfilter=/usr/lib/cups/filter
    drv=/usr/lib/cups/driver
    bin=/usr/bin
    apparmor=/etc/apparmor.d
    # Following values are determined at configure time and cannot be changed.
    [configure]
    network-build=yes
    libusb01-build=no
    pp-build=no
    gui-build=yes
    scanner-build=yes
    fax-build=yes
    dbus-build=yes
    cups11-build=no
    doc-build=yes
    shadow-build=no
    hpijs-install=yes
    foomatic-drv-install=no
    foomatic-ppd-install=yes
    foomatic-rip-hplip-install=no
    hpcups-install=yes
    cups-drv-install=no
    cups-ppd-install=yes
    internal-tag=3.19.12
    restricted-build=no
    ui-toolkit=qt5
    qt3=no
    qt4=no
    qt5=yes
    policy-kit=no
    lite-build=no
    udev_sysfs_rules=no
    hpcups-only-build=no
    hpijs-only-build=no
    apparmor_build=no
    class-driver=no
    
    
    Current contents of '/var/lib/hp/hplip.state' file:
    Plugins are not installed. Could not access file: No such file or directory
    
    Current contents of '~/.hplip/hplip.conf' file:
    warning: Could not access file: No such file or directory
     <Package-name>        <Package-Desc>      <Required/Optional> <Min-Version> <Installed-Version> <Status>   <Comment>
    
    -------------------------
    | External Dependencies |
    -------------------------
    
     cups                 CUPS - Common Unix Printing System                           REQUIRED        1.1             2.3       
          OK         'CUPS Scheduler is running'
     gs                   GhostScript - PostScript and PDF language interpreter and previewer REQUIRED        7.05            9.5
    2            OK         -
     error: xsane         xsane - Graphical scanner frontend for SANE                  OPTIONAL        0.9             -         
          MISSING    'xsane needs to be installed'
     scanimage            scanimage - Shell scanning program                           OPTIONAL        1.0             1.0.29    
          OK         -
     error: dbus          DBus - Message bus system                                    REQUIRED        -               1.12.16   
          MISSING    'DBUS may not be installed or not running'
     policykit            PolicyKit - Administrative policy framework                  OPTIONAL        -               0.116     
          OK         -
     network              network -wget                                                OPTIONAL        -               1.20.3    
          OK         -
     avahi-utils          avahi-utils                                                  OPTIONAL        -               0.7       
          OK         -
    
    ------------------------
    | General Dependencies |
    ------------------------
    
     error: libjpeg       libjpeg - JPEG library                                       REQUIRED        -               -         
          MISSING    'libjpeg needs to be installed'
     error: cups-devel    CUPS devel- Common Unix Printing System development files    REQUIRED        -               2.3       
          MISSING    'cups-devel needs to be installed'
     error: cups-image    CUPS image - CUPS image development files                    REQUIRED        -               2.3       
          MISSING    'cups-image needs to be installed'
     libpthread           libpthread - POSIX threads library                           REQUIRED        -               b'2.31'   
          OK         -
     error: libusb        libusb - USB library                                         REQUIRED        -               1.0       
          MISSING    'libusb needs to be installed'
     sane                 SANE - Scanning library                                      REQUIRED        -               -         
          OK         -
     error: sane-devel    SANE - Scanning library development files                    REQUIRED        -               -         
          MISSING    'sane-devel needs to be installed'
     error: libnetsnmp-devel libnetsnmp-devel - SNMP networking library development files REQUIRED        5.0.9           5.8    
             MISSING    'libnetsnmp-devel needs to be installed'
     error: libcrypto     libcrypto - OpenSSL cryptographic library                    REQUIRED        -               1.1.1     
          MISSING    'libcrypto needs to be installed'
     python3X             Python 2.2 or greater - Python programming language          REQUIRED        2.2             3.8.3     
          OK         -
     error: python3-notify2 Python libnotify - Python bindings for the libnotify Desktop notifications OPTIONAL        -         
          -               MISSING    'python3-notify2 needs to be installed'
    Traceback (most recent call last):
      File "/usr/bin/hp-check", line 862, in <module>
        num_errors, num_warns = dep.validate(time_flag, is_quiet_mode)
      File "/usr/bin/hp-check", line 367, in validate
        self.__update_deps_info(supported_distro_vrs, dep,
      File "/usr/bin/hp-check", line 210, in __update_deps_info
        installed_ver = self.core.version_func[deps_info[6]]()
      File "/usr/share/hplip/installer/dcheck.py", line 303, in get_pyQt4_version
        from PyQt4 import QtCore
    ImportError: cannot import name 'QtCore' from 'PyQt4' (unknown location)
    

  5. #15
    Join Date
    Jun 2008
    Location
    Auckland, NZ
    Posts
    21,948
    Blog Entries
    1

    Default Re: Configuring the firewall so that hp-setup can find network printers

    Quote Originally Posted by rxmd View Post

    Code:
    
    Gerät: URI = dnssd://HP%20OfficeJet%20Pro%208710%20%5BAD5ECE%5D._ipp._tcp.local/?uuid=1c852a4d-b800-1f08-abcd-b4b686ad5ece
           Klasse = network
           Info = HP OfficeJet Pro 8710 [AD5ECE]
           Hersteller-und-Modell = HP OfficeJet Pro 8710
           Geräte-ID = MFG:HP;MDL:OfficeJet Pro 8710;CMD:PCL,JPEG,URF,PWG;
           Standort =  
    Gerät: URI = ipp://HP%20OfficeJet%20Pro%208710%20%5BAD5ECE%5D._ipp._tcp.local/
           Klasse = network
           Info = HP OfficeJet Pro 8710 (driverless)
           Hersteller-und-Modell = HP OfficeJet Pro 8710
           Geräte-ID = MFG:HP;MDL:OfficeJet Pro 8710;CMD:PCLM,PCL,PWGRaster,AppleRaster,JPEG,URF,PWG;
           Standort =  
    Ok, so the CUPS backends have picked up the printer, including the dnssd backend.

    Should I remove the two CUPS print queues for it (for printing and fax) and try again?
    I doubt that would change anything.
    openSUSE Leap 15.2; KDE Plasma 5

  6. #16
    Join Date
    Jun 2008
    Location
    Auckland, NZ
    Posts
    21,948
    Blog Entries
    1

    Default Re: Configuring the firewall so that hp-setup can find network printers

    Does hp-probe find the printer?
    Code:
    hp-probe -m mdns
    openSUSE Leap 15.2; KDE Plasma 5

  7. #17
    Join Date
    Jun 2020
    Posts
    25

    Default Re: Configuring the firewall so that hp-setup can find network printers

    Quote Originally Posted by deano_ferrari View Post
    Does hp-probe find the printer?
    Code:
    hp-probe -m mdns
    No:

    Code:
    $hp-probe -m mdns
    
    HP Linux Imaging and Printing System (ver. 3.19.12)
    Printer Discovery Utility ver. 4.1
    
    Copyright (c) 2001-18 HP Development Company, LP
    This software comes with ABSOLUTELY NO WARRANTY.
    This is free software, and you are welcome to distribute it
    under certain conditions. See COPYING file for more details.
    
    
    --------------------
    | DEVICE DISCOVERY |
    --------------------
    
    Probing network for printers. Please wait, this will take approx. 10 seconds...
    
    -warning: No devices found on the 'net' bus. If this isn't the result you are expecting,
    warning: check your network connections and make sure your internet
    warning: firewall software is disabled.
    
    Done.
    

  8. #18
    Join Date
    Jun 2008
    Location
    Podunk
    Posts
    29,413
    Blog Entries
    15

    Default Re: Configuring the firewall so that hp-setup can find network printers

    Hi
    Shouldn't it be -bnet?

    Code:
    hp-probe -bnet
    
    HP Linux Imaging and Printing System (ver. 3.19.12)
    Printer Discovery Utility ver. 4.1
    
    Copyright (c) 2001-18 HP Development Company, LP
    This software comes with ABSOLUTELY NO WARRANTY.
    This is free software, and you are welcome to distribute it
    under certain conditions. See COPYING file for more details.
    
    
    --------------------
    | DEVICE DISCOVERY |
    --------------------
    
    Probing network for printers. Please wait, this will take approx. 10 seconds...
    
      Device URI                                                Model                             Name         
      --------------------------------------------------------  --------------------------------  -------------
      hp:/net/HP_LaserJet_Professional_P_1102w?ip=xxx.xxx.xxx.xxx  HP_LaserJet_Professional_P_1102w  printer-name
    
    Found 1 printer(s) on the 'net' bus.
    
    
    Done.
    No firewall running though....

    This should provide the information on ports to open....
    https://support.hp.com/us-en/document/c02480766
    Cheers Malcolm °¿° SUSE Knowledge Partner (Linux Counter #276890)
    SUSE SLE, openSUSE Leap/Tumbleweed (x86_64) | GNOME DE
    If you find this post helpful and are logged into the web interface,
    please show your appreciation and click on the star below... Thanks!

  9. #19
    Join Date
    Jun 2008
    Location
    Auckland, NZ
    Posts
    21,948
    Blog Entries
    1

    Default Re: Configuring the firewall so that hp-setup can find network printers

    Quote Originally Posted by malcolmlewis View Post
    No firewall running though....

    This should provide the information on ports to open....
    https://support.hp.com/us-en/document/c02480766
    It's also described here
    https://developers.hp.com/hp-linux-i...nFirewall.html

    However, OP has done this (re their firewall output earlier in this thread).
    openSUSE Leap 15.2; KDE Plasma 5

  10. #20
    Join Date
    Jun 2008
    Location
    Podunk
    Posts
    29,413
    Blog Entries
    15

    Default Re: Configuring the firewall so that hp-setup can find network printers

    Quote Originally Posted by deano_ferrari View Post
    It's also described here
    https://developers.hp.com/hp-linux-i...nFirewall.html

    However, OP has done this (re their firewall output earlier in this thread).
    Hi
    I would turn the firewall off, add the printer and re-enable.....
    Cheers Malcolm °¿° SUSE Knowledge Partner (Linux Counter #276890)
    SUSE SLE, openSUSE Leap/Tumbleweed (x86_64) | GNOME DE
    If you find this post helpful and are logged into the web interface,
    please show your appreciation and click on the star below... Thanks!

Page 2 of 5 FirstFirst 1234 ... LastLast

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •