Followed tutorials:
- Configure and install server: https://geekytheory.com/tutorial-raspberry-pi-12-como-crear-un-servidor-de-impresion
- HP LaserJet 1020 driver: http://foo2zjs.rkkda.com/
Url to access to the server once installed https://SERVER_IP:631/
.
Installed raspbian using Raspberry Pi Imager v1.2
, desktop app to install SO in the SD from a computer. Installed Raspbian without user interface.
Execute from console sudo raspi-config
to configure:
-> set keyboard layout
-> set timezone
-> set wifi network, SSID name + pass
sudo apt-get update
sudo apt-get upgrade
sudo apt-get install openssh-client #<- should be installed
sudo apt-get install openssh-server #<- should be installed
Execute sudo raspi-config
and do it from menu
OR do it directly sudo systemctl enable ssh
and sudo systemctl start ssh
sudo apt-get install cups
sudo usermod -a -G lpadmin pi
sudo nano /etc/cups/cupsd.conf
# -> see changes below
sudo service cups restart
Tendremos que comentar o eliminar algunas líneas que hacen que por defecto la administración sea local. Añadiremos otras para poder acceder de forma remota.
# Only listen for connections from the local machine.
#Listen localhost:631
Listen *:631
Listen /var/run/cups/cups.sock
La red en la que está mi Raspberry Pi, es 192.168.1.*, así que permitiré el acceso a cualquier máquina de esa misma red: You can allow same IP range for logs and other sections
# Restrict access to the server...
Order allow,deny
Allow 192.168.1.*
# Restrict access to the admin pages...
Order allow,deny
Allow 192.168.1.*
# Restrict access to configuration files...
AuthType Default
#Require user @SYSTEM
Allow 192.168.1.*
Order allow,deny
Finally restart cups sudo service cups restart
Click the link, or cut and paste the whole command line below to download the driver.
$ wget -O foo2zjs.tar.gz http://foo2zjs.rkkda.com/foo2zjs.tar.gz
Now unpack it:
$ tar zxf foo2zjs.tar.gz
$ cd foo2zjs
Now compile and install it. The INSTALL file contains more detailed instructions; please read it now.
Compile:
$ make
Get extra files from the web, such as .ICM profiles for color correction,
and firmware. Select the model number for your printer:
$ ./getweb cpwl # Get Minolta Color PageWorks/Pro L .ICM files
$ ./getweb 2200 # Get Minolta 2200 DL .ICM files
$ ./getweb 2300 # Get Minolta 2300 DL .ICM files
$ ./getweb 2430 # Get Minolta 2430 DL .ICM files
$ ./getweb 1000 # Get HP LaserJet 1000 firmware file
$ ./getweb 1005 # Get HP LaserJet 1005 firmware file
$ ./getweb 1018 # Get HP LaserJet 1018 firmware file
$ ./getweb 1020 # Get HP LaserJet 1020 firmware file
$ ./getweb 1025 # Get HP LaserJet Pro CP1025nw .ICM files
Install driver, foomatic XML files, and extra files:
$ su OR $ sudo make install
# make install
(Optional) Configure hotplug (USB; HP LJ 1000/1005/1018/1020):
# make install-hotplug OR $ sudo make install-hotplug
(Optional) If you use CUPS, restart the spooler:
# make cups OR $ sudo make cups
Finally add printer to CUPS here https://SERVER_IP:631/admin
and using drivers from step #6.
Add the printer ...@ raspberry
to computers.
Let's print!!!
If once the printer added to the MacOs the printer job says "Hold for authentication", then follow this steps to enable Kerberos authentication:
- Add printer with "Generic Postcript Printer" driver.
- Execute:
lpstat -s
and pick the printer name (after text 'device for') example: "HP_LaserJet_1020___raspberrypi" - Execute:
sudo lpadmin -p [PRINTER-NAME] -o auth-info-required=negotiate
.
http://foo2zjs.rkkda.com/ is down. You can find everything here now https://github.com/koenkooi/foo2zjs.