cannot detect scanner (hpaio) shared with saned daemon

Bug #1550744 reported by Antonin Vecera
This bug affects 3 people
Affects Status Importance Assigned to Milestone

Bug Description


I can't detect (scanimage -L) my scanner shared on network.
Here is description of my configuration:

I have in my network these devices:
1. All-in-one printer+scanner HP LaserJet Pro MFP M125nw connected with network cable
2. pc1 - Fedora server 23 with CUPS and saned daemon
3. pc2 - Fedora Workstation 23 where I want to use scanner shared on pc1

on pc1 (server) - everything is working as expected:
- in CUPS is defined printer with URI as hp:/net/HP_LaserJet_Pro_MFP_M125nw?hostname=mfp and I can print via CUPS
- scanner is detected and listed with "scanimage -L"
- I can scan images with "scanimage"

on pc2 (client):
- I can print via CUPS
- I can scan images but I MUST define used device (scanimage -d net:pc1:hpaio:/net/HP_LaserJet_Pro_MFP_M125nw?hostname=mfp >image.pnm)
- I CANNOT detect my scanner with "scanimage -L"

The problem is that I cannot see my scanner in detected devices on pc2.
The scanner is defined in CUPS on pc1 (server) and shared to my network with "saned" daemon.
But on pc2 (client) the scanner is not detected and every time I want to scan I must to explicitly define it on command line.


Additional info:

For testing purposes I enabled on pc1 (server) "sane-test" backend.
This virtual scanner was detected on pc1 and pc2 with no problem:

pc1:~$ scanimage -L
device `test:0' is a Noname frontend-tester virtual device
device `test:1' is a Noname frontend-tester virtual device
device `hpaio:/net/HP_LaserJet_Pro_MFP_M125nw?hostname=mfp' is a Hewlett-Packard HP_LaserJet_Pro_MFP_M125nw all-in-one

pc2:~$ scanimage -L
device `net:pc1:test:0' is a Noname frontend-tester virtual device
device `net:pc1:test:1' is a Noname frontend-tester virtual device

I think this proves that my configuration (iptables, CUPS, saned, ...) is OK.


So I think there could be a bug in hplip package.
I looked in sources and I found in file hplip-3.16.2/scan/sane/hpaio.c
that there is "DevDiscovery()" function where is:

    /* Look for Network Scan devices if localonly flag if FALSE. */
    if (!localOnly)
        /* Look for all-in-one scan devices for which print queue created */
        cnt = GetCupsPrinters(&cups_printer);

My opinion is you should not treat CUPS printers as non-local devices.
There should not be the condition for "localOnly" variable.

Actually a printer could be non-local (networked) but its (URI) definition is local (in CUPS).


Revision history for this message
Antonin Vecera (antonin.vecera) wrote :

The issue still remains. I tested it on Fedora 27 with 'hplip-3.17.11-4'.

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.