LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Mageia
User Name
Password
Mageia This forum is for the discussion of Mageia Linux.

Notices


Reply
  Search this Thread
Old 03-28-2021, 03:06 PM   #1
coyotl
Member
 
Registered: Oct 2010
Posts: 48

Rep: Reputation: 3
Unhappy scanning does not work with HP Deskjet F300


This is an old printer but drivers are still in most distros (CUPS).

It works for printing but the scanner is not found by scanning frontends.

Distro is not Mageia but ALT Linux, (rpm based and originally based on Mandrake Linux)

Just wondered what could be missing to cause this?
 
Old 03-29-2021, 03:14 AM   #2
ferrari
LQ Guru
 
Registered: Sep 2003
Location: Auckland, NZ
Distribution: openSUSE Leap
Posts: 5,803

Rep: Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140
Are you using HPLIP drivers? Please show configured CUPS printer backend...
Code:
lpstat -t
The hpaio scanner backend relies on the appropriate printer configuration.
 
1 members found this post helpful.
Old 03-29-2021, 08:01 AM   #3
coyotl
Member
 
Registered: Oct 2010
Posts: 48

Original Poster
Rep: Reputation: 3
~]$ lpstat -t
scheduler is running
system default destination: HP-Deskjet-F300-series
device for HP-Deskjet-F300-series: hp:/usb/Deskjet_F300_series?serial=CN73DGW0WC04KH
HP-Deskjet-F300-series accepting requests since Fri 26 Feb 2021 12:28:15 PM CET
printer HP-Deskjet-F300-series is idle. enabled since Fri 26 Feb 2021 12:28:15 PM CET
~]$

Ok now get output from ubuntu, got to reboot
 
Old 03-29-2021, 09:41 AM   #4
kilgoretrout
Senior Member
 
Registered: Oct 2003
Posts: 2,987

Rep: Reputation: 388Reputation: 388Reputation: 388Reputation: 388
According to Open Printing, you need the HPLIP driver for the scanner to work:

https://www.openprinting.org/printer/HP/HP-DeskJet_F300

The HPIJS driver will only give basic printer functionality.
 
2 members found this post helpful.
Old 03-29-2021, 10:54 AM   #5
coyotl
Member
 
Registered: Oct 2010
Posts: 48

Original Poster
Rep: Reputation: 3
Thanks. Installing the HP hplip package is not for everyone.. looked into it, compilation failed because of something that could not be found in Synaptic in ALT. The distribution specific packages ask for distro specific stuff and refuse to continue if that stuff is installed but has a different name in your distro (the distro list is ridic, outdated)
Ok so then I try the hplip driver available in ALT or find and copy over the PPD I guess. In ALT I have hpijs driver.

Ubuntu output here (scanning works just fine)
lpstat -t
scheduler is running
system default destination: Deskjet-F300-series
device for Deskjet-F300-series: hp:/usb/Deskjet_F300_series?serial=CN73DGW0WC04KH
Deskjet-F300-series accepting requests since sų. 28. mars 2021 kl. 15.13 +0200
printer Deskjet-F300-series is idle. enabled since sų. 28. mars 2021 kl. 15.13 +0200

CUPS driver info ubuntu:

Description: HP Deskjet F300 series
Location: arcadia
Driver: HP Deskjet f300 Series, hpcups 3.20.3 (color, 2-sided printing)
Connection: hp:/usb/Deskjet_F300_series?serial=CN73DGW0WC04KH
Defaults: job-sheets=none, none media=iso_a4_210x297mm sides=one-sided
 
Old 03-29-2021, 11:01 AM   #6
shruggy
Senior Member
 
Registered: Mar 2020
Posts: 3,670

Rep: Reputation: Disabled
Both ALT Sisyphos and ALT P9 provide the latest HPLIP 3.21.2 (arranged into several hplip-* packages). What you need is probably hplip-sane.

Last edited by shruggy; 03-29-2021 at 11:09 AM.
 
1 members found this post helpful.
Old 03-29-2021, 11:41 AM   #7
ferrari
LQ Guru
 
Registered: Sep 2003
Location: Auckland, NZ
Distribution: openSUSE Leap
Posts: 5,803

Rep: Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140
Ok, so the lpstat output shows the expected HPLIP printer URI at least...
Code:
device for Deskjet-F300-series: hp:/usb/Deskjet_F300_series?serial=CN73DGW0WC04KH
Check that /etc/sane.d/dll.conf contains an uncommented 'hpaio' entry. As user shruggy already mentioned, check that 'hplip-sane' is installed. There may be other missing supporting libraries. HPLIP provides diagnostic tools including 'hp-doctor' which can be used to get an idea about what may be missing.
 
1 members found this post helpful.
Old 03-29-2021, 01:18 PM   #8
coyotl
Member
 
Registered: Oct 2010
Posts: 48

Original Poster
Rep: Reputation: 3
ALT output. Lots of code below, the output from hp-doctor is not helpful as to missing stuff as it does not recognize the distro.
But the errors about permissions suggest that may be the problem.
ALT has the newest hplip but maybe not too well integrated.
Also I'm using a SySV based starterkit and those are very barebones, have to add most stuff afterwards.

[@comp-pentium-cpu-142909 sane.d]$ lpstat -t
scheduler is running
no system default destination
device for HP_Deskjet_F300_series: hp:/usb/Deskjet_F300_series?serial=CN73DGW0WC04KH
HP_Deskjet_F300_series accepting requests since sų. 28. mars 2021 kl. 15.02 +0200
printer HP_Deskjet_F300_series is idle. enabled since sų. 28. mars 2021 kl. 15.02 +0200
[@comp-pentium-cpu-142909 sane.d]$
... Driver: HP Deskjet 400, hpcups 3.21.2 (color)
Connection: hp:/usb/Deskjet_F300_series?serial=CN73DGW0WC04KH

hp-doctor:
warning: starter distro is not found in AUTH_TYPES


Checking for Deprecated items....
error: This distro (i.e unknown p9) is either deprecated or not yet supported.
The diagnosis is limited on unsupported platforms. Do you want to continue?(y=yes*, n=no):

hp-doctor

HP Linux Imaging and Printing System (ver. 3.21.2)
Self Diagnse Utility and Healing Utility ver. 1.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.


HP Linux Imaging and Printing System (ver. 3.21.2)
Self Diagnse Utility and Healing Utility ver. 1.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.

warning: starter distro is not found in AUTH_TYPES


Checking for Deprecated items....
error: This distro (i.e unknown p9) is either deprecated or not yet supported.
The diagnosis is limited on unsupported platforms. Do you want to continue?(y=yes*, n=no):y


Checking for HPLIP updates....
error: Failed to locate hp-upgrade utility


Checking for Dependencies....
warning: unknown-p9 version is not supported. Using unknown-0 versions dependencies to verify and install...

---------------
| SYSTEM INFO |
---------------

Kernel: 5.4.81-std-def-alt1 #1 SMP Fri Dec 4 09:57:57 UTC 2020 GNU/Linux
Host: comp-pentium-cpu-142909
Proc: 5.4.81-std-def-alt1 #1 SMP Fri Dec 4 09:57:57 UTC 2020 GNU/Linux
Distribution: unknown p9
Bitness: 64 bit


-----------------------
| HPLIP CONFIGURATION |
-----------------------

HPLIP-Version: HPLIP 3.21.2
HPLIP-Home: /usr/share/hplip
warning: HPLIP-Installation: Auto installation is not supported for unknown distro p9 version

Current contents of '/etc/hp/hplip.conf' file:
# hplip.conf. Generated from hplip.conf.in by configure.

[hplip]
version=3.21.2

[dirs]
home=/usr/share/hplip
run=/var/run
ppd=/usr/share/ppd/HP
ppdbase=/usr/share/ppd
doc=/usr/share/doc/hplip-3.21.2
html=/usr/share/doc/hplip-3.21.2
icon=/usr/share/applications
cupsbackend=/usr/lib/cups/backend
cupsfilter=/usr/lib/cups/filter
drv=/usr/share/cups/drv/hp
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=yes
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=yes
foomatic-ppd-install=yes
foomatic-rip-hplip-install=no
hpcups-install=yes
cups-drv-install=yes
cups-ppd-install=yes
internal-tag=3.21.2
restricted-build=no
ui-toolkit=qt5
qt3=no
qt4=no
qt5=yes
policy-kit=yes
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:
[installation]
date_time = 03/29/21 20:03:49
version = 3.21.2


<Package-name> <Package-Desc> <Required/Optional> <Min-Version> <Installed-Version> <Status> <Comment>

-------------------------
| External Dependencies |
-------------------------

error: cups CUPS - Common Unix Printing System REQUIRED 1.1 - INCOMPAT 'CUPS may not be installed or not running'
gs GhostScript - PostScript and PDF language interpreter and previewer REQUIRED 7.05 9.27 OK -
xsane xsane - Graphical scanner frontend for SANE OPTIONAL 0.9 0.999 OK -
scanimage scanimage - Shell scanning program OPTIONAL 1.0 1.0.32 OK -
error: dbus DBus - Message bus system REQUIRED - 1.12.16 MISSING 'DBUS may not be installed or not running'
error: policykit PolicyKit - Administrative policy framework OPTIONAL - 0.116 MISSING 'policykit needs to be installed'
network network -wget OPTIONAL - 1.20.3 OK -
avahi-utils avahi-utils OPTIONAL - 0.8 OK -

------------------------
| General Dependencies |
------------------------

libjpeg libjpeg - JPEG library REQUIRED - - OK -
cups-devel CUPS devel- Common Unix Printing System development files REQUIRED - - OK -
cups-image CUPS image - CUPS image development files REQUIRED - - OK -
libpthread libpthread - POSIX threads library REQUIRED - b'2.27' OK -
libusb libusb - USB library REQUIRED - 1.0 OK -
sane SANE - Scanning library REQUIRED - 1.0.32 OK -
sane-devel SANE - Scanning library development files REQUIRED - 1.0.32 OK -
libavahi-dev libavahi-dev REQUIRED - - OK -
libnetsnmp-devel libnetsnmp-devel - SNMP networking library development files REQUIRED 5.0.9 5.8 OK -
libcrypto libcrypto - OpenSSL cryptographic library REQUIRED - 1.1.1 OK -
python3X Python 2.2 or greater - Python programming language REQUIRED 2.2 3.7.4 OK -
python3-notify2 Python libnotify - Python bindings for the libnotify Desktop notifications OPTIONAL - - OK -
error: python3-pyqt4-dbus PyQt 4 DBus - DBus Support for PyQt4 OPTIONAL 4.0 4.12.1 MISSING 'python3-pyqt4-dbus needs to be installed'
python3-pyqt4 PyQt 4- Qt interface for Python (for Qt version 4.x) REQUIRED 4.0 4.12.1 OK -
python3-dbus Python DBus - Python bindings for DBus REQUIRED 0.80.0 1.2.12 OK -
python3-xml Python XML libraries REQUIRED - 2.2.10 OK -
python3-devel Python devel - Python development files REQUIRED 2.2 3.7.4 OK -
python3-pil PIL - Python Imaging Library (required for commandline scanning with hp-scan) OPTIONAL - 5.2.0 OK -
python3-reportlab Reportlab - PDF library for Python OPTIONAL 2.0 3.4.0 OK -

--------------
| COMPILEDEP |
--------------

libtool libtool - Library building support services REQUIRED - 2.4.6 OK -
gcc gcc - GNU Project C and C++ Compiler REQUIRED - 8.4.1 OK -
make make - GNU make utility to maintain groups of programs REQUIRED 3.0 4.2.1 OK -

---------------------
| Python Extentions |
---------------------

cupsext CUPS-Extension REQUIRED - 3.21.2 OK -
hpmudext IO-Extension REQUIRED - 3.21.2 OK -

----------------------
| Scan Configuration |
----------------------

hpaio HPLIP-SANE-Backend REQUIRED - 3.21.2 OK 'hpaio found in /etc/sane.d/dll.conf'
scanext Scan-SANE-Extension REQUIRED - 3.21.2 OK -

------------------------------
| DISCOVERED SCANNER DEVICES |
------------------------------

No Scanner found.

--------------------------
| DISCOVERED USB DEVICES |
--------------------------

No devices found.

---------------------------------
| INSTALLED CUPS PRINTER QUEUES |
---------------------------------


HP_Deskjet_F300_series
----------------------
Type: Printer
Device URI: hp:/usb/Deskjet_F300_series?serial=CN73DGW0WC04KH
PPD: /etc/cups/ppd/HP_Deskjet_F300_series.ppd
warning: Failed to read /etc/cups/ppd/HP_Deskjet_F300_series.ppd ppd file
PPD Description:
Printer status: printer HP_Deskjet_F300_series is idle. enabled since sų. 28. mars 2021 kl. 15.02 +0200
error: Unable to communicate with device (code=12): hp:/usb/Deskjet_F300_series?serial=CN73DGW0WC04KH
error: Device not found
error: Communication status: Failed


--------------
| PERMISSION |
--------------



Checking Permissions....


Checking for Configured Queues....
warning: Fail to read ppd=/etc/cups/ppd/HP_Deskjet_F300_series.ppd file
warning: Insufficient permission to access file /etc/cups/ppd/HP_Deskjet_F300_series.ppd
warning: Could not complete Queue(s) configuration check


Checking for HP Properitery Plugin's....
No plug-in printers are configured.


Checking for Printer Status....
error: 'HP_Deskjet_F300_series' Printer is either Powered-OFF or Failed to communicate.
Turn On Printer and re-run hp-doctor

Diagnose completed...
 
Old 03-29-2021, 01:25 PM   #9
coyotl
Member
 
Registered: Oct 2010
Posts: 48

Original Poster
Rep: Reputation: 3
Ok, tried Xsane as root. Yelled some crap about how dangerisk to run as root but found scanner. So, confirmed its about permissions I guess, got to look into that.
 
Old 03-29-2021, 01:40 PM   #10
ferrari
LQ Guru
 
Registered: Sep 2003
Location: Auckland, NZ
Distribution: openSUSE Leap
Posts: 5,803

Rep: Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140
Quote:
Originally Posted by coyotl View Post
Ok, tried Xsane as root. Yelled some crap about how dangerisk to run as root but found scanner. So, confirmed its about permissions I guess, got to look into that.
Add the user to the 'lp' group for USB-connected scanners.
 
1 members found this post helpful.
Old 03-29-2021, 01:53 PM   #11
uteck
Senior Member
 
Registered: Oct 2003
Location: Elgin,IL,USA
Distribution: Ubuntu based stuff for the most part
Posts: 1,173

Rep: Reputation: 501Reputation: 501Reputation: 501Reputation: 501Reputation: 501Reputation: 501
There is also be a 'scan' group you need to be added to. I think the lp group is just to control print jobs, not scanning.
 
1 members found this post helpful.
Old 03-29-2021, 02:01 PM   #12
coyotl
Member
 
Registered: Oct 2010
Posts: 48

Original Poster
Rep: Reputation: 3
Thank y'all fixed now
Yes, there is a 'scanner' group but I was already added to that by the system. Not so with 'lp' but done now.
 
Old 03-29-2021, 02:04 PM   #13
ferrari
LQ Guru
 
Registered: Sep 2003
Location: Auckland, NZ
Distribution: openSUSE Leap
Posts: 5,803

Rep: Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140
Yes, the 'scanner' group is historic, but contemporary udev rules generally set USB scanner device nodes to group 'lp'.

The permissions for USB device nodes can be checked with something like...
Code:
ls -lR /dev/bus/usb/
Anyway, glad to read that it is now solved.

Last edited by ferrari; 03-29-2021 at 02:07 PM.
 
1 members found this post helpful.
Old 03-29-2021, 02:06 PM   #14
ferrari
LQ Guru
 
Registered: Sep 2003
Location: Auckland, NZ
Distribution: openSUSE Leap
Posts: 5,803

Rep: Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140Reputation: 1140
Quote:
Originally Posted by uteck View Post
There is also be a 'scan' group you need to be added to. I think the lp group is just to control print jobs, not scanning.
No, CUPS printer access is generally ACL controlled for USB devices. Scanner udev rules (for USB-connected devices) usually set r/w access explicitly for the 'lp' group.
 
Old 03-30-2021, 11:01 AM   #15
uteck
Senior Member
 
Registered: Oct 2003
Location: Elgin,IL,USA
Distribution: Ubuntu based stuff for the most part
Posts: 1,173

Rep: Reputation: 501Reputation: 501Reputation: 501Reputation: 501Reputation: 501Reputation: 501
Quote:
Originally Posted by ferrari View Post
No, CUPS printer access is generally ACL controlled for USB devices. Scanner udev rules (for USB-connected devices) usually set r/w access explicitly for the 'lp' group.
Good to know. It has been years since I last setup a scanner, and I have not kept up with changes.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] raspbian buster issue with scanning on hp deskjet 2544 in raspberry pi2 printer/scanner server floppy_stuttgart Linux - Embedded & Single-board computer 1 01-17-2021 07:41 PM
[SOLVED] HP Deskjet 3070A Scanning Problem Solved. Ubuntu 10.04 roger2143 Ubuntu 1 07-10-2012 01:08 AM
Hp f300 joegumbo Slackware 7 04-14-2009 10:45 AM
Active Scanning or Passive Scanning Paris Heng Linux - Networking 2 02-15-2008 09:37 AM
HP Deskjet 695Cci Printer does not work in Ubuntu 6.10 gregorian Linux - Newbie 4 03-26-2007 07:54 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Mageia

All times are GMT -5. The time now is 06:20 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration