SDB:AirPrint via CUPS
Introduction
AirPrint is an Apple technology that helps you create full-quality printed output from iOS or macOS devices without the need to download or install drivers.
Some printers support AirPrint natively. For these printers, you do not need CUPS AirPrint support.
This guide explains how to make non-AirPrint printers available to iOS and macOS devices using CUPS + Avahi + cups-airprint, so they can be discovered and used as AirPrint printers on your network.
Overview
- cups-airprint* generates Avahi (mDNS/Bonjour) service files for CUPS printers so iOS/macOS devices can discover and print to them.
- CUPS* receives the print jobs over IPP.
- cups-filters* converts Apple raster (URF) data into PDF, then into your printer’s format.
Modern Linux systems can advertise CUPS printers directly via DNS-SD, and many do not need extra software beyond CUPS and Avahi. *cups-airprint* provides more compatible DNS-SD records for AirPrint clients.
Requirements
1. A printer configured in CUPS
- Must be shared and accepting IPP print jobs.
2. Avahi (mDNS/Bonjour)
- Used to broadcast AirPrint service announcements.
- Ensure the CUPS server and Avahi daemon run on the same host and your Apple devices are on the same subnet.
3. cups-filters >= 1.0.25
- Required for URF → PDF conversion.
4. CUPS >= 1.6
- Older CUPS releases may not work reliably with AirPrint.
5. Network
- Multicast DNS must be allowed (UDP port 5353).
- IPP (TCP port 631) must be reachable by clients.
Installation (openSUSE)
On openSUSE distributions where the package is available:
sudo zypper install cups-airprint
If a package isn’t available for your version, consider the openSUSE Build Service repository.
After installing, ensure printers are shared in CUPS (`/etc/cups/printers.conf` → `<Printer .. Shared Yes>`).
Restart CUPS and Avahi:
sudo systemctl restart cups avahi-daemon
Generate AirPrint service files:
sudo airprint-generate.py -v -d /etc/avahi/services/
This creates `.service` files for Avahi that advertise your shared CUPS queues as AirPrint printers.
Restart Avahi:
sudo systemctl restart avahi-daemon
Configuration Notes
- Set a ServerAlias for CUPS so that AirPrint clients accept its hostname:
sudo cupsctl "ServerAlias=$HOST.local"
- Ensure your firewall allows Avahi (mDNS) and IPP traffic.
Limitations
- Limited feature support: media size, duplex, color/grayscale, and copy count may not work reliably.
- Driver dependencies: your printer must have a working CUPS driver that can accept PDF.
- Some recent CUPS versions (e.g., 2.4.x) changed how PPDs are shared over AirPrint, which may affect client behavior.
For full AirPrint feature compatibility, consider a printer with native AirPrint support.
Alternatives & Related Solutions
- Containerized CUPS + Avahi solutions can expose printers as AirPrint devices without a standalone server.