LinuxCommandLibrary
GitHubF-DroidGoogle Play Store

hp-clean

Printhead cleaning utility for HPLIP-supported HP inkjet printers

TLDR

Clean print heads for the default printer (opens the interactive cleaning wizard)
$ hp-clean
copy
Clean a specific CUPS printer by queue name
$ hp-clean -p [printer-name]
copy
Clean a printer by device URI
$ hp-clean -d [device-uri]
copy
Run interactively, choosing the cleaning level (1-3) at the prompt
$ hp-clean -i
copy
Enable debug-level logging for troubleshooting
$ hp-clean -g
copy

SYNOPSIS

hp-clean [DEVICE-URI|PRINTER-NAME] [MODE] [OPTIONS]

DESCRIPTION

hp-clean runs the printhead cleaning routine on HPLIP-supported HP inkjet printers, clearing dried ink and debris from the nozzles to restore print quality.When launched without a specific mode it walks through an interactive wizard that lets the user pick a cleaning level from 1 to 3; higher levels clean more aggressively and consume more ink, so level 1 is usually tried first. The target printer can be selected up front with -p or -d, otherwise hp-clean prompts for one if more than one HPLIP device is installed.hp-clean only works with inkjet printers whose HPLIP plugin exposes a cleaning routine; laser printers and some low-end inkjets do not support it.

PARAMETERS

-d device-uri, --device=device-uri

Specify the target printer by CUPS device URI.
-p printer, --printer=printer
Specify the target printer by CUPS queue name.
-i, --interactive
Run in interactive mode.
-l level, --logging=level
Set logging verbosity: none, info (default), error, warn, or debug.
-g
Run with debug-level logging (equivalent to -l debug).
-h, --help
Display help and exit.

INSTALL

sudo apt install hplip
copy
sudo dnf install hplip
copy
sudo pacman -S hplip
copy
sudo zypper install hplip
copy
nix profile install nixpkgs#hplip
copy

CAVEATS

Part of the HPLIP package. Cleaning consumes ink and should only be run when print quality actually degrades (streaks, missing lines). Not all HPLIP-supported models implement printhead cleaning.

HISTORY

hp-clean is one of the device-maintenance utilities in HPLIP (HP Linux Imaging and Printing), HP's open-source printer/scanner driver suite for Linux, alongside hp-align and hp-linefeedcal.

SEE ALSO

RESOURCES

Copied to clipboard
Kai