Debugging CUPS “Filter Failed” Error on ArchLinux: Samsung ML-2010 Printer Setup Guide


2 views

When setting up a Samsung ML-2010 laser printer on a fresh ArchLinux installation, you might encounter the infamous "Filter failed" error in CUPS (Common Unix Printing System). This occurs despite the printer being correctly recognized and configured. The error typically appears in the print job status:

canceled at
Fri 06 Jun 2014 10:15:26 PM EEST
"Filter failed"

CUPS logs are the first place to investigate, but they might not always show the complete picture. Here's how to enable verbose logging:

# Edit cupsd.conf
sudo nano /etc/cups/cupsd.conf

# Add or modify these lines:
LogLevel debug
AccessLog /var/log/cups/access_log
ErrorLog /var/log/cups/error_log

Restart CUPS and check the logs:

sudo systemctl restart cups
tail -f /var/log/cups/error_log

The "Filter failed" error typically indicates missing printer drivers or incompatible filters. For Samsung printers, you'll need:

# Install necessary packages
sudo pacman -S cups ghostscript gsfonts foomatic-db foomatic-db-engine
sudo pacman -S foomatic-db-nonfree

For Samsung-specific drivers:

# Install Samsung driver (if available)
sudo pacman -S splix

If the above doesn't work, you might need to manually install the PPD file:

# Download the PPD file
wget http://www.samsung.com/support/download/supportDown.do?filetype=DRV&filename=ML-2010_1.00.36.tar.gz

# Extract and install
tar -xzvf ML-2010_1.00.36.tar.gz
cd cdroot/Linux/noarch/at_opt/share/ppd
sudo cp Samsung-ML-2010.ppd /usr/share/ppd/custom/

Then reconfigure your printer in CUPS web interface (http://localhost:631) using this PPD file.

If Samsung-specific drivers don't work, try using generic PostScript drivers:

# In CUPS web interface:
1. Select "Generic" as manufacturer
2. Choose "Generic PostScript Printer" as model
3. Set appropriate options for your printer

Sometimes the issue is related to file permissions. Ensure the CUPS filters have proper access:

# Check filter permissions
ls -la /usr/lib/cups/filter/

# If needed, fix permissions
sudo chmod 755 /usr/lib/cups/filter/*

To isolate the problem, try printing simple text files first:

echo "Test print" > test.txt
lp -d Samsung-ML-2010 test.txt

If this works but complex documents fail, you might need additional filters or updated ghostscript.


When CUPS encounters a "Filter failed" error, it typically means one of the conversion filters in the print pipeline crashed. The Samsung ML-2010 uses the rastertosamsungspl filter to convert PostScript to printer-specific format. Let's examine the filter execution path:

# Check installed filters
ls -l /usr/lib/cups/filter/ | grep -i samsung

# Typical filter chain for this printer:
application/vnd.cups-postscript → pstops → rastertosamsungspl → application/vnd.cups-raw

While basic CUPS logs might not show details, we need to enable debug logging:

# Edit CUPS config
sudo nano /etc/cups/cupsd.conf

# Add these lines:
LogLevel debug
PageLogFormat "%p %u %j %T %P %C %{job-originating-host-name} %{job-billing} %{job-id} %k"

# Restart CUPS
sudo systemctl restart cups.service

Now check detailed logs with:

sudo tail -f /var/log/cups/error_log
journalctl -u cups.service -f

The Samsung ML-2010 requires these specific packages on ArchLinux:

# Install necessary packages
sudo pacman -S cups ghostscript gsfonts splix

# Verify filter presence
/usr/lib/cups/filter/rastertosamsungspl --version

Common issues include missing 32-bit libraries on 64-bit systems. Check dependencies with:

ldd /usr/lib/cups/filter/rastertosamsungspl

To isolate the failing component, execute the filter chain manually:

# Generate test file
echo "%PDF-" > test.pdf

# Run through filter chain
/usr/lib/cups/filter/pstops 1 test.pdf anonymous test 1 "" < test.pdf > temp.ps
/usr/lib/cups/filter/rastertosamsungspl temp.ps anonymous test 1 "" > output.dat

Check each step's exit code (echo $?) to identify where it fails.

If the Samsung driver proves problematic, try these alternatives:

# Install generic driver
sudo pacman -S foo2zjs

# Configure with:
lpadmin -p SamsungML2010 -E -v usb://Samsung/ML-2010 -m driverless:ipp://...

Or use the PostScript emulation mode if available:

# Edit PPD file
sudo nano /etc/cups/ppd/SamsungML2010.ppd

# Look for and uncomment:
*cupsFilter: "application/vnd.cups-postscript 0 -"

Many filter failures stem from permission issues. Verify:

# Check file permissions
ls -la /usr/lib/cups/filter/

# Check user context
ps aux | grep cups

For SELinux systems, check audit logs:

sudo ausearch -m avc -ts recent | grep cups