How to Install and Configure HP Printers on CentOS 7
HP printers and scanners on Rocky Linux, CentOS, or RHEL require the HPLIP (HP Linux Imaging and Printing) package. This guide covers the complete setup process.
Install HPLIP packages
Start by installing the core HPLIP packages:
sudo dnf install hplip hplip-gui hpijs
On older CentOS 7 systems, use yum instead of dnf. HPLIP may prompt you to install additional dependencies — allow these installations to proceed. Some printer models require proprietary plugins that won’t function without the complete package set.
Install printer plugins
HP printers often need proprietary plugins for full functionality. Install them with:
sudo hp-plugin
This tool downloads and installs device-specific plugins. You may need to accept licensing agreements. If the command fails, ensure you have internet connectivity and that your printer model is supported by the current HPLIP version.
Configure your printer
Run the printer setup utility:
sudo hp-setup
This interactive tool will:
- Detect connected printers (USB or network)
- Configure the printer for your system
- Set default print queues
- Test basic connectivity
Follow the on-screen prompts. For network printers, enter the IP address when prompted.
Verify scanner functionality
Test scanner detection:
scanimage -L
This lists all detected scanners. If your scanner appears, the configuration is complete.
For USB scanners, ensure your user account belongs to the lpadmin and lp groups to avoid permission issues:
sudo usermod -aG lpadmin,lp $USER
Log out and back in for group changes to take effect.
Troubleshooting
Printer not detected: Check USB connections or network connectivity. For network printers, verify the device is on the same subnet:
sudo hp-probe -bnet
Plugin installation fails: Update HPLIP to the latest version. Older HPLIP versions may not support newer printer models:
sudo dnf update hplip
Scanner permissions denied: Ensure you’ve added your user to the appropriate groups (see above).
Check HPLIP status: View detailed device and driver information:
hp-info
Accessing the GUI
If you installed hplip-gui, launch the control panel:
sudo hp-toolbox
This provides a graphical interface for printer management, status monitoring, and basic diagnostics.
Troubleshooting Common Issues
If you encounter problems during installation, check these common solutions:
- Ensure your system packages are up to date before installing new software
- Check for conflicting packages that might prevent installation
- Verify network connectivity if downloading packages from external repositories
- Review system logs in /var/log/ for detailed error messages
Verification Steps
After installation, verify everything is working correctly by checking the installed version and running basic functionality tests. Most command-line tools respond to the –version or -v flag to display their version information.
Keeping Your Installation Updated
Regularly update your system to receive security patches and bug fixes. On Fedora, use dnf update. On Ubuntu and Debian, use apt update followed by apt upgrade. For software installed via language-specific package managers like pip, npm, or gem, check their respective update commands.
Related Linux Commands
These related commands are often used alongside the tools discussed in this article:
- man command-name – Read the manual page for any command
- which command-name – Find the location of an executable
- rpm -qa or dpkg -l – List installed packages
- journalctl -u service-name – Check service logs
- ss -tulpn – List listening ports and services
Quick Reference
This article covered the essential concepts and commands for the topic. For more information, consult the official documentation or manual pages. The key takeaway is to understand the fundamentals before applying advanced configurations.
Practice in a test environment before making changes on production systems. Keep notes of what works and what does not for future reference.

I have tried for hours to install a HP Deskjet Ink Advantage 2676 Printer wireless to no avail
When running hp_setup the printer is not seen. I run Windows (dual-boot) on the same box and the printer is fine from Windows. Any help would be appreciated.
Thanks! This worked the first time around. I had far more issues in the past.
The final command gave me this output:
[root@localhost ~]# hp-setup
HP Linux Imaging and Printing System (ver. 3.18.4)
Printer/Fax Setup Utility ver. 9.0
Copyright (c) 2001-15 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: Ignoring XDG_SESSION_TYPE=wayland on Gnome. Use QT_QPA_PLATFORM=wayland to run on Wayland anyway.
No protocol specified
qt.qpa.xcb: could not connect to display :0
qt.qpa.plugin: Could not load the Qt platform plugin “xcb” in “” even though it was found.
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.
Available platform plugins are: eglfs, linuxfb, minimal, minimalegl, offscreen, vnc, xcb.
Aborted (core dumped)
—-
Was not sure what to do from here.
I could not use hp-setup to complete the printer setup for a wireless HP LaserJet Professional Printer 1102W. It failed at the last step.
What worked for me is:
yum install hplip hplip-gui hpijs
hp-plugin
I then used GOOGLE CHROME to configure the printer. There are a few selections to be made along the way which I do not recall but if someone see this and wants the GOOGLE CHROME setup steps, I can recreate and provide the information.
I’d like to see the Chrome method steps