Network connection not detected

Bug #2028367 reported by Emiliano Brunetti
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
HPLIP
New
Undecided
Unassigned

Bug Description

Hi, I'm using a HP Laser Jet Pro MFP m28a Printer and Scanner.
The printer works well but the scanner needs plugin.
When i type the command "hp-plugin -i" it report the bug: "Network connection not detected"
My O.S. is Ubuntu Mate 22.10

This is the "hp-check -t" output:

[code]hp-check -t
Saving output in log file: /home/emiliano/hp-check.log

HP Linux Imaging and Printing System (ver. 3.23.5)
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

-Traceback (most recent call last):
  File "/usr/bin/hp-check", line 861, in <module>
    dep.core.init()
  File "/usr/share/hplip/installer/core_install.py", line 523, in init
    self.get_distro()
  File "/usr/share/hplip/installer/core_install.py", line 661, in get_distro
    if 'MX' in distro_release_name:
NameError: name 'distro_release_name' is not defined
[/code]

I send you also the "hp-plugin -i -g" outoput:

[code]
HP Linux Imaging and Printing System (ver. 3.23.5)
Plugin Download and Install Utility ver. 2.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.

HP Linux Imaging and Printing System (ver. 3.23.5)
Plugin Download and Install Utility ver. 2.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.

hp-plugin[7636]: debug: Locking: /home/emiliano/.hplip/hp-plugin.lock
hp-plugin[7636]: debug: Unable to open file /var/lib/hp/hplip.state for reading.
hp-plugin[7636]: debug: Unable to open file /var/lib/hp/hplip.state for reading.
(Note: Defaults for each question are maked with a '*'. Press <enter> to accept the default.)

-----------------------------------------
| PLUG-IN INSTALLATION FOR HPLIP 3.23.5 |
-----------------------------------------

  Option Description
  ---------- --------------------------------------------------
  d Download plug-in from HP (recommended)
  p Specify a path to the plug-in (advanced)
  q Quit hp-plugin (skip installation)

Enter option (d=download*, p=specify path, q=quit) ? d

-------------------
| DOWNLOAD PLUGIN |
-------------------

Checking for network connection...
hp-plugin[7636]: debug: /usr/bin/wget --cache=off --tries=3 --timeout=60 --output-document=- http://www.hp.com --spider -S
hp-plugin[7636]: debug: Spider mode enabled. Check if remote file exists.
--2023-07-21 14:36:33-- http://www.hp.com/
Resolving www.hp.com (www.hp.com)... 2a02:26f0:df::212:fed3, 2a02:26f0:df::212:fed8, 173.222.106.180, ...
Connecting to www.hp.com (www.hp.com)|2a02:26f0:df::212:fed3|:80... connected.
HTTP request sent, awaiting response...
  HTTP/1.1 503 Service Unavailable
  Server: AkamaiGHost
  Mime-Version: 1.0
  Content-Type: text/html
  Content-Length: 176
  Expires: Fri, 21 Jul 2023 12:36:32 GMT
  Date: Fri, 21 Jul 2023 12:36:32 GMT
  Connection: keep-alive
  Set-Cookie: aka_client_code=IT-
  Akamai-GRN: 0.cffe1202.1689942992.cce050b
  Server-Timing: ak_p; desc="469428_34799311_214828299_34_9184_18_-_-";dur=1
Remote file does not exist -- broken link!!!

hp-plugin[7636]: debug: wget returned: 8
hp-plugin[7636]: debug: /usr/bin/curl --output - --connect-timeout 5 --max-time 10 http://www.hp.com --head
hp-plugin[7636]: debug: Traceback (most recent call last):
  File "/usr/bin/hp-plugin", line 354, in <module>
    ok = utils.check_network_connection()
  File "/usr/share/hplip/base/utils.py", line 2294, in check_network_connection
    status = download_via_curl(url, head=True)
  File "/usr/share/hplip/base/utils.py", line 2272, in download_via_curl
    status, output = run(cmd)
  File "/usr/share/hplip/base/utils.py", line 1295, in run
    child = pexpect.spawnu(cmd, timeout=timeout)
  File "/usr/share/hplip/base/pexpect/__init__.py", line 1755, in __init__
    super(spawnu, self).__init__(*args, **kwargs)
  File "/usr/share/hplip/base/pexpect/__init__.py", line 486, in __init__
    self._spawn(command, args)
  File "/usr/share/hplip/base/pexpect/__init__.py", line 637, in _spawn
    os.execv(self.command, self.args)
PermissionError: [Errno 13] Permission denied
Error in sys.excepthook:
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 128, in apport_excepthook
    increment_crash_counter(pr, pr_filename)
  File "/usr/lib/python3/dist-packages/apport/fileutils.py", line 355, in increment_crash_counter
    fd = os.open(filename, os.O_NOFOLLOW | os.O_RDONLY | os.O_NONBLOCK)
PermissionError: [Errno 13] Permission denied: '/var/crash/_usr_share_hplip_plugin.py.1000.crash'

Original exception was:
Traceback (most recent call last):
  File "/usr/bin/hp-plugin", line 354, in <module>
    ok = utils.check_network_connection()
  File "/usr/share/hplip/base/utils.py", line 2294, in check_network_connection
    status = download_via_curl(url, head=True)
  File "/usr/share/hplip/base/utils.py", line 2272, in download_via_curl
    status, output = run(cmd)
  File "/usr/share/hplip/base/utils.py", line 1295, in run
    child = pexpect.spawnu(cmd, timeout=timeout)
  File "/usr/share/hplip/base/pexpect/__init__.py", line 1755, in __init__
    super(spawnu, self).__init__(*args, **kwargs)
  File "/usr/share/hplip/base/pexpect/__init__.py", line 486, in __init__
    self._spawn(command, args)
  File "/usr/share/hplip/base/pexpect/__init__.py", line 637, in _spawn
    os.execv(self.command, self.args)
PermissionError: [Errno 13] Permission denied

hp-plugin[7636]: debug: curl returned: 1
hp-plugin[7636]: debug: /usr/bin/ping -c1 -W1 -w10 www.hp.com
hp-plugin[7636]: debug: Traceback (most recent call last):
  File "/usr/bin/hp-plugin", line 354, in <module>
    ok = utils.check_network_connection()
  File "/usr/share/hplip/base/utils.py", line 2296, in check_network_connection
    status = check_network_via_ping(ping_server)
  File "/usr/share/hplip/base/utils.py", line 2285, in check_network_via_ping
    status, output = run(cmd)
  File "/usr/share/hplip/base/utils.py", line 1295, in run
    child = pexpect.spawnu(cmd, timeout=timeout)
  File "/usr/share/hplip/base/pexpect/__init__.py", line 1755, in __init__
    super(spawnu, self).__init__(*args, **kwargs)
  File "/usr/share/hplip/base/pexpect/__init__.py", line 486, in __init__
    self._spawn(command, args)
  File "/usr/share/hplip/base/pexpect/__init__.py", line 637, in _spawn
    os.execv(self.command, self.args)
PermissionError: [Errno 13] Permission denied
Error in sys.excepthook:
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 128, in apport_excepthook
    increment_crash_counter(pr, pr_filename)
  File "/usr/lib/python3/dist-packages/apport/fileutils.py", line 355, in increment_crash_counter
    fd = os.open(filename, os.O_NOFOLLOW | os.O_RDONLY | os.O_NONBLOCK)
PermissionError: [Errno 13] Permission denied: '/var/crash/_usr_share_hplip_plugin.py.1000.crash'

Original exception was:
Traceback (most recent call last):
  File "/usr/bin/hp-plugin", line 354, in <module>
    ok = utils.check_network_connection()
  File "/usr/share/hplip/base/utils.py", line 2296, in check_network_connection
    status = check_network_via_ping(ping_server)
  File "/usr/share/hplip/base/utils.py", line 2285, in check_network_via_ping
    status, output = run(cmd)
  File "/usr/share/hplip/base/utils.py", line 1295, in run
    child = pexpect.spawnu(cmd, timeout=timeout)
  File "/usr/share/hplip/base/pexpect/__init__.py", line 1755, in __init__
    super(spawnu, self).__init__(*args, **kwargs)
  File "/usr/share/hplip/base/pexpect/__init__.py", line 486, in __init__
    self._spawn(command, args)
  File "/usr/share/hplip/base/pexpect/__init__.py", line 637, in _spawn
    os.execv(self.command, self.args)
PermissionError: [Errno 13] Permission denied

hp-plugin[7636]: debug: ping returned: 1
error: Network connection not detected.
hp-plugin[7636]: debug: Unlocking: /home/emiliano/.hplip/hp-plugin.lock
[/code]

Thank you for your disposal.
I hope you can fix my problem.
Good bye.

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.