Skip to main content
Turn Your Old STB into a Network Print Server with CUPS

Turn Your Old STB into a Network Print Server with CUPS

·1028 words·5 mins
Zarvelion Zynji
Author
Zarvelion Zynji
Tech enthusiasts (self-proclaimed). Gaming addict (diagnosed). Anime simp (no regrets). I turn my hyperfixations into content—welcome to the chaos.
Table of Contents

Have an old Android STB (Set Top Box) gathering dust after you installed Armbian on it? Most of these devices aren’t used for TV anymore anyway. Instead of letting it sit idle or relegating it to media server duty, why not repurpose it as a network print server?

With this setup, you get a practical, power-efficient print server accessible from any device on your home network. Print from Windows, Linux, Android phones, or Chromebooks without physically connecting the printer to each device. Your STB becomes the hub—just like enterprise print servers, but for home use.

Let me show you exactly how to set this up. It’s simpler than you’d think. 🚀


What You’ll Need
#

Before starting, gather these:

  • A rooted Android STB (Indihome ZTE, B860H, or similar models)
  • Armbian installed on the STB (Debian/Ubuntu-based highly recommended)
  • SSH access to the STB from a PC or laptop
  • A USB printer that Linux supports
  • Active internet connection for package downloads
  • A client computer/laptop running Windows (Linux/Mac/Android also work)

💡 To check if your printer works with Linux, look up the model on OpenPrinting.


Step 1: Update Your STB’s System
#

First, ensure your system is completely up-to-date. This prevents mysterious bugs and dependency errors during installation.

sudo apt update && sudo apt upgrade -y

If your STB has limited storage (8GB or less), clean up the cache afterward:

sudo apt clean

Step 2: Install Printer Drivers
#

The most common reason printers don’t work in CUPS is missing drivers. Install the driver for your specific printer before configuring CUPS.

For HP Printers:
#

sudo apt install hplip -y

hplip is HP’s official Linux driver package, including PPDs and utilities.

For Epson Printers:
#

sudo apt install printer-driver-escpr -y

This supports Epson L-series and XP-series models common in many regions.

For Canon Printers:
#

sudo apt install printer-driver-gutenprint -y

gutenprint covers Canon, Lexmark, Brother, and many other manufacturers.

If Your Printer Still Doesn’t Show Up:
#

  • Download the .ppd file directly from your printer manufacturer’s website
  • Or install additional driver support:
sudo apt install foomatic-db foomatic-db-engine foomatic-filters

Step 3: Install and Configure CUPS
#

CUPS (Common UNIX Printing System) is open-source software that manages printing across networked systems. It runs on macOS, Linux, and most POSIX-based systems.

Install CUPS:
#

sudo apt install cups -y

Add Your User to the Admin Group:
#

This lets you manage printers without always needing root:

sudo usermod -aG lpadmin $USER

Enable and Start the Service:
#

sudo systemctl enable cups
sudo systemctl start cups

Verify It’s Running:
#

sudo systemctl status cups

Look for active (running) in the output.


Step 4: Enable Network Access to CUPS
#

By default, CUPS only accepts connections from the same machine (localhost). We need to change this so other devices on your network can access it.

Edit the CUPS Configuration:
#

sudo nano /etc/cups/cupsd.conf

Find and replace:

Listen localhost:631

With:

Port 631

Next, locate all instances of these sections and add Allow @local to each:

<Location />
  Order allow,deny
  Allow @local
</Location>

<Location /admin>
  Order allow,deny
  Allow @local
</Location>

<Location /admin/conf>
  Order allow,deny
  Allow @local
</Location>

The @local directive allows any device on your local network to connect.

Restart CUPS:
#

sudo systemctl restart cups

Test Access from Another Device:
#

Open a browser on another computer and navigate to:

http://<your-stb-ip>:631

You should see the CUPS web interface. Success!


Step 5: Add Your Printer via the Web Interface
#

  1. Go to http://<your-stb-ip>:631
  2. Click Administration > Add Printer
  3. Select your USB printer from the list
  4. Enter a name for the printer (optional but helpful)
  5. Choose the printer location if desired
  6. Select the correct driver from the list
  7. Complete the setup wizard
  8. Click Maintenance > Print Test Page

If the test page prints successfully, your STB is now a functional print server!


Step 6: Connect Your Windows Computer
#

The Easy Way: Add Printer via URL
#

  1. Open Control Panel > Devices and Printers
  2. Click Add a printer
  3. Your printer may appear automatically as PrinterName@hostname
  4. If not, select The printer that I want isn’t listed
  5. Choose Select a shared printer by name
  6. Enter the URL in this format:
http://192.168.1.100:631/printers/EPSON_L3110

(Replace the IP with your STB’s IP and the printer name with your actual printer name)

  1. Click Next
  2. Choose the printer driver if prompted
  3. Click Finish and try printing

Find your exact printer name in the CUPS web interface under Printers.


Optional Tips and Tricks
#

Give Your STB a Friendly Hostname
#

Instead of remembering an IP address, assign a hostname:

sudo hostnamectl set-hostname print-server

Then access it via:

http://print-server.local:631

Enable Auto-Discovery for macOS/iOS
#

Install Avahi for Bonjour/IPP printer discovery:

sudo apt install avahi-daemon
sudo systemctl enable avahi-daemon

Your printer will now appear automatically in macOS and iOS print dialogs.


Troubleshooting Common Issues
#

CUPS Is Not Accessible from Other Devices
#

  • Confirm the config shows Port 631 (not Listen localhost:631)
  • Restart CUPS: sudo systemctl restart cups
  • Temporarily disable firewall to test: sudo ufw disable

Printer Not Detected in CUPS
#

Run these diagnostic commands:

lsusb
dmesg | grep usb

Check that the USB cable is firmly connected and the driver installed correctly.

Login Required When Adding Printer
#

Ensure you’re using a user account that belongs to the lpadmin group:

groups $USER

If lpadmin isn’t listed, re-run: sudo usermod -aG lpadmin $USER

Windows Can’t Print to the Server
#

  • Verify the printer driver matches what’s installed on the STB
  • Check CUPS error logs: sudo tail -f /var/log/cups/error_log
  • Ensure Windows can ping the STB: ping 192.168.1.100

What You’ve Accomplished
#

✅ Transformed an old STB into a dedicated print server
✅ Enabled network printing from any device (Windows, Linux, Android)
✅ Created a low-power, always-on printing solution
✅ Gained experience managing Linux services
✅ Saved money on dedicated hardware


Next Steps
#

Now that you have a working print server, consider:

  1. Integrate with CasaOS: Manage CUPS through a unified dashboard
  2. Add scanning: Install sane to enable scanning from all-in-one printers
  3. Enable remote access: Configure with VPN for printing from outside your network
  4. Automate backups: Use your STB for more than just printing

This is just the beginning. Your repurposed STB is now a productive member of your homelab!


Related


Load Comments