Solved Does IPP printing work in FreeBSD? Aka driverless printing..

I just had setup a printer on Linux with this IPP thing, driverless printing. Don't have to do anything much really. Does Freebsd has similiar mechanism? In fact Apple did contribute to this IPP thing greatly.
So I checked some documents about this: https://docs.freebsd.org/en/books/handbook/printing/

I've tried these steps to no avail. My printer is well supported in Linux aswell, even my Android phone could easily send print files without any config really, I set this up as a network printer. It's Kyocera Ecosys P2135DN. Also it supports IPP thing too. Done that in Debian 12 like this:
Code:
driverless list

#this gives some string about kyocera printer, which we will print this string down here after ipps://

lpadmin -p Kyocera_IPP -E -v "ipps://Kyocera%20ECOSYS%20P2135dn._ipps._tcp.local/" -m everywhere

My question is does FreeBSD support such a thing, or will it in the future? It seems this is the newest coolest stuff about printers.
 
Short answer.
Yes, FreeBSD supports this sort of thing.

Longer answer
I'm going to spam my own page, https://srobb.net/cliscanprint.html#FreeBSD. I do it a bit differently. Assuming the Kyocera has an IP address I would use that to add it, giving an example from my page linked above (using a Brother printer at 192.168.1.50)
Code:
sudo lpadmin -p BrotherMFC -E -v ipp://192.168.1.50/ipp/print -m everywhere

I'm assuming you've installed cups and cups-filters and have cupsd running.

The stuff I mention adding at the beginning of that page is for scanning and not needed for printing, you just need cups and cups-filters.
 
Short answer.
Yes, FreeBSD supports this sort of thing.

Longer answer
I'm going to spam my own page, https://srobb.net/cliscanprint.html#FreeBSD. I do it a bit differently. Assuming the Kyocera has an IP address I would use that to add it, giving an example from my page linked above (using a Brother printer at 192.168.1.50)
Code:
sudo lpadmin -p BrotherMFC -E -v ipp://192.168.1.50/ipp/print -m everywhere

I'm assuming you've installed cups and cups-filters and have cupsd running.

The stuff I mention adding at the beginning of that page is for scanning and not needed for printing, you just need cups and cups-filters.
Ok but don't we have a GUI to see print queques just like in Linux? Even XFCE has this.
 
Yes FreeBSD has. Open your favorite web browser and go to localhost:631.
That brings up the cups GUI interface to install a printer or change things and watch the print queues.
 
As sko said, netcat will do it. I've only tried with pdfs. At first I used to convert them to a ps file, but that isn't necessary. so I don't know about other formats. The syntax, assuming your printer is at 192.168.1.50 is
Code:
nc 192.168.1.50 9100 < myfile.pdf
(assuming it's a pdf file.)
 
At first I used to convert them to a ps file, but that isn't necessary.
careful: it depends on the printer. cheap consumer devices or braindead "designed for windows" printers often can only deal with plaintext and some sort of scripting language (often some crippled variation of postscript with incompatible quirks). decent network printers can also deal with postscript and nowadays often pdf (proper pdf-a that is, not the non-standard crap adobe generates...).
some printers will also do weird things with images (scaling/cropping/spanning over dozens of pages...).
 
careful: it depends on the printer. cheap consumer devices or braindead "designed for windows" printers often can only deal with plaintext and some sort of scripting language (often some crippled variation of postscript with incompatible quirks). decent network printers can also deal with postscript and nowadays often pdf (proper pdf-a that is, not the non-standard crap adobe generates...).
some printers will also do weird things with images (scaling/cropping/spanning over dozens of pages...).

FWIW IPP printers are not obliged to support anything other than PWG-raster, which allows for the universal equivalent of a win-printer, where the computer does most of the work. This is supported by CUPS.

I've no idea how common these are.
 
Ok I did it with 2 FreeBSD pc's so far. This is how I did below. But my complaint is that, nowere in freebsd manuals they do talk about this. Why even meddle with cups and stuff if IPP everywhere works?

Code:
sudo pkg install cups cups-filters avahi nss_mdns

#I advise you to copy these lines one by one, for me it didn't work if I copied them all.

sudo sysrc cupsd_enable=YES

sudo sysrc dbus_enable=YES

sudo sysrc avahi_daemon_enable=YES

sudo sysrc avahi_dnsconfd_enable=YES

sudo service dbus start

sudo service avahi-daemon start

sudo service avahi-dnsconfd start

sudo service cupsd start

Then this:
sudo vi /etc/nsswitch.conf

Make this row like this:
hosts: files mdns dns
Then somehow it adds the printer automatically, if it supports IPP everywhere at least. Maybe after a restart, then it works. Nothing to do anymore.
 
Ok but don't we have a GUI to see print queques just like in Linux? Even XFCE has this.
CUPS should be required as a dependency of Xfce4 via Gtk3.
And IIUC, IPP is one of the "transferring protocol" like JetDirect (port 9100) that does not contain "printer controlling language" like PostScript, PreScribe, LIPS, ESC-P and so on.
 
CUPS should be required as a dependency of Xfce4 via Gtk3.
And IIUC, IPP is one of the "transferring protocol" like JetDirect (port 9100) that does not contain "printer controlling language" like PostScript, PreScribe, LIPS, ESC-P and so on.
I don't know that much, but for basic printing it works. Even print on both sides work.
 
I don't know that much, but for basic printing it works. Even print on both sides work.
This. Most printers will even happily accept any supported file/script format over all protocols they offer - in fact you don't even need to actually 'use' the protocol (send specific headers or e.g. all the html crap IPP defines) and can just dump the file at any port they are listening on.
E.g. I often send the output of sh int desc on cisco switches directly to port 9100 on the printer in my office. Port 631 (IPP) also works, but I always have to look up that port number because it doesn't stick as well as 9100.
Same goes for pdf files when I don't want to deal with any print job settings and just want the file to be printed 'as is', or to circumvent the annoying CUPS bug that won't print copies - a simple for-loop running nc multiple times is much faster than hitting 'print' 30 times.

Oh, and in case of other (binary) file formats, they will just fall back to raw text - try dumping a wave file to a printer (preferably not YOUR printer) and it will happily spit out what it thinks all that sound should look like, often using all the paper they have at their disposal to express themselves...
 
Yes, printers "usually" (not assured to be always, depending on the PDL the printer uses) accept "plain text" data flow with its configured default mode.
If, for example, the printer is configured to use A4 paper and print on both side, it would print "plain texts flow" as such.
 
This. Most printers will even happily accept any supported file/script format over all protocols they offer - in fact you don't even need to actually 'use' the protocol (send specific headers or e.g. all the html crap IPP defines) and can just dump the file at any port they are listening on.
E.g. I often send the output of sh int desc on cisco switches directly to port 9100 on the printer in my office. Port 631 (IPP) also works, but I always have to look up that port number because it doesn't stick as well as 9100.
Same goes for pdf files when I don't want to deal with any print job settings and just want the file to be printed 'as is', or to circumvent the annoying CUPS bug that won't print copies - a simple for-loop running nc multiple times is much faster than hitting 'print' 30 times.

Oh, and in case of other (binary) file formats, they will just fall back to raw text - try dumping a wave file to a printer (preferably not YOUR printer) and it will happily spit out what it thinks all that sound should look like, often using all the paper they have at their disposal to express themselves...
Thanks, but didn't understand a word of what you said. I just follow the easiest and cleanest path.
 
Back
Top