# HPLIP LJ P1005 PPD file not found. Printer not work.

## gangstervano

Hi!

There is a printer hp laserjet P1005. Installed package HPLIP. And as if all is well. But when you try to hp-stup -i issued an error:

error: No PPD found for model laserjet_p1005 using old algorithm.

error: Unable to find an appropriate PPD file.

When attempting to ppd file manually, I do not find it in the folder /usr/share/ppd/HP/

Rebuild package hplip with optional static-ppd.

File /usr/share/ppd/HP/hp-laserjet_p1005.ppd.gz appeared.

However, the printer still does not work. When you try to print a document, the printer is not listed.

The printer is connected by ubs

/etc/portage/make.conf

```

# These settings were set by the catalyst build script that automatically

# built this stage.

# Please consult /usr/share/portage/config/make.conf.example for a more

# detailed example.

CFLAGS="-march=core-avx-i -O2 -pipe"

CXXFLAGS="${CFLAGS}"

# WARNING: Changing your CHOST is not something that should be done lightly.                     

# Please consult http://www.gentoo.org/doc/en/change-chost.xml before changing.                  

CHOST="x86_64-pc-linux-gnu"                                                                      

# These are the USE and USE_EXPAND flags that were used for                                      

# buidling in addition to what is provided by the profile.                                       

USE="X bindist kde mmx mmxext sse sse2 sse3 libkms plymouth bindist qt5 alsa dvd cdr gtk networkmanager pam pulseaudio display-manager grub mediacenter plymouth sddm sdk wallpapers dbus policykit udev udisks video consolekit ffmpeg hpcups usb"                                                

CPU_FLAGS_X86="mmx mmxext sse sse2 sse3"                                                         

PORTDIR="/usr/portage"                                                                           

DISTDIR="${PORTDIR}/distfiles"                                                                   

PKGDIR="${PORTDIR}/packages"                                                                     

MAKEOPTS="-j5"                                                                                   

GENTOO_MIRRORS="http://mirror.yandex.ru/gentoo-distfiles/"                                       

INPUT_DEVICES="evdev synaptics"                                                                  

VIDEO_CARDS="radeon"

FEATURES="ccache"

CCACHE_SIZE="5G"

CCACHE_DIR="/var/tmp/ccache" 

L10N="ru"

LINGUAS="ru"

ACCEPT_LICENSE="*"

SANE_BACKENDS="hp"

```

cat /etc/portage/package.use/hp

```
net-print/hplip snmp hpcups static-ppds
```

kernel config:

https://yadi.sk/d/LWTKfGxsvfrbC

```
# CONFIG_USB_PRINTER is not set
```

Enable CONFIG_USB_PRINTER, I tried as M and *. Nothing changed.

The problem behind.

```
user ~ $ groups

wheel audio cdrom video games usb lpadmin vano
```

Last edited by gangstervano on Fri Sep 30, 2016 9:22 am; edited 2 times in total

----------

## vasettoo

Discussed here:

https://forums.gentoo.org/viewtopic-t-975378-start-0-postdays-0-postorder-asc-highlight-foo2zjs.html

and that one for foomatic-filters USE change:

https://forums.gentoo.org/viewtopic-t-998788-start-0-postdays-0-postorder-asc-highlight-laserjet.html

Best regards!

----------

## gangstervano

vasetto thanks for the reply!

I understand that the problem can be solved only by using non-standard tool?

There is no other means than the installation foo2zjs?

Does this will cause problems in the system?

```

** DON'T USE the foo2zjs package from:

        Ubuntu, SUSE, Mandrake/Manrivia, Debian, RedHat, Fedora, Gentoo, Xandros, EEE PC, Linpus, MacOSX, or BSD!

*** Download it here and follow the directions below. 
```

Hmm ... is this normal?

UPD:

Do I understand correctly that after the execution of commands:

```

root ~ # cd foo2zjs

root foo2zjs # make

root foo2zjs # make install

root foo2zjs # ./getweb P1005

```

It is necessary to run the command:

```
lpadmin -p "HP_P1005" -v "URI" -E -P /usr/share/cups/model/HP-LaserJet_P1005.ppd.gz
```

Where to get the URI?

UPD2:

```
root: lpadmin -p "HP_P1005" -v "usb:/dev/usb/lp0" -E -P /usr/share/cups/model/HP-LaserJet_P1005.ppd.gz
```

lpadmin: unable to connect to server: wrong file descriptor

Please help   :Sad: 

----------

## gangstervano

UPD3:

Add to kernel 

```
Device Drivers  --->

    [*] USB support  --->

        <*> USB Printer support
```

```
lpadmin -p "HP_P1005" -v "usb:/dev/usb/lp0" -E -P /usr/share/cups/model/HP-LaserJet_P1005.ppd.gz
```

```
root foo2zjs # make cups
```

```
 * Starting cupsd ...  
```

The printer appears in the list when printing (Ctrl + P). But nothing prints  :Very Happy: 

Have someone with such a printer hp P1005?

UPD4:

Printed the my first page  :Smile: 

Too much action has been taken to write here.

One of these days I will try to put the the old image, and to find out exactly what help to make, and that was a waste of time.

----------

## gangstervano

As I promised describe the installation algorithm that helped me:

add USE flag: 

```
hpcups usb static-ppds
```

```
Device Drivers  --->

    [*] USB support  --->

        < > USB Printer support

```

```
nano /etc/group
```

```
lpadmin:x:<?>:<username>
```

```
emerge -av dev-python/reportlab dev-python/notify-python dev-python/inotifyx dev-python/py-notify dev-python/pyinotify

emerge -a xsane 

emerge -a avahi

emerge -a usbutils

emerge -a net-snmp

emerge -a net-print/cups

emerge -a net-print/foo2zjs

emerge -a hplip

rc-update add cupsd default

reboot
```

Double click to HP icon in tray.

Push "Setup Devices.."

Must show "HP laserJet p1005"

Push "Next"

Set filed  "PPD file:" to "lsb/usr/HP/hp-laserjet_p1005.ppd.gz" or manualy choose /usr/share/ppd/HP/hp-laserjet_p1005.ppd.gz 

Push "Add Printer"

Menu->System Settings->Printers

Push "Setup"

Choose driver: hp laserjet p1005 Foomatic/foo2xqx

Push "Apply"

Open "kate" and  add any text...

Ctrl+P

Push "Print"

Profit  :Smile: 

Enjoy printing  :Smile: 

UPD:

Print two pages. The second time is not printed.  :Sad: 

However, says that all tasks are successfully completed. Only the printed sheets does not appear  :Smile: 

There's nothing to be done, we'll have to try install his from source. 

One of these days I will write about the result.

UPD2:

Nothing not turned  :Sad:  Returned new image. Again printed one page. The paper ended and the indicator began flashing .... Then that just did not do a clean queue, remove / install the printer, rebooted. Do not printed He writes that the operation was successful, but the printer does not do anything  :Sad: 

 :Sad:   :Sad:   :Sad: 

----------

## gangstervano

UPD

If you click in the hp-toolbox download firmware, the printer prints   :Smile:  . The problem is that we have to do every time you turn on / off the printer and restart the system.   :Sad: 

----------

## beerbellyswan

AHA - success! i found a dependency in okular that pointed me in the right direction:

dev-qt/qtprintsupport

when i looked at that guys use flags, i found "cups" - which is OFF by default. I added the cups use flag to qtprintsupport, and voila - okular found the printer. 

Then i found "cups" was also a use flag for chromium - and also off by default. I've now added cups to my make.conf and am recompiling.

*phew*

thanks for the responses everyone!

bob

----------

