Printer "Filter failed"

Solution 1:

I encountered the same problem. To track back its origin I looked into /var/log/cups/error_log

In my case, I discovered that the problem was caused by icc profiles used by ghostscript. I had the following error:

Started filter pstops (PID 26489)    
./base/gsicc_manage.c:1244: gsicc_open_search(): Could not find default_gray.icc    
./base/gsicc_manage.c:2261: gsicc_init_iccmanager(): cannot find default icc profile   
./base/gsicc_manage.c:1244: gsicc_open_search(): Could not find default_rgb.icc    
./base/gsicc_manage.c:2025: gsicc_set_device_profile(): cannot find device profile   
**** Unable to open the initial device, quitting.   

So what worked out for me has been to manually remove the icc profiles and then re-install libgs9-common (following this link: Broken ghostscript configuration):

sudo rmdir /usr/share/ghostscript/9.25/iccprofiles   
sudo apt-get install --reinstall libgs9-common   

Hope this helps

Solution 2:

For Brother HL2140 printer, the following worked for me (on Ubuntu 18.04):

  1. Run this command to install drivers

    sudo apt install hpijs-ppds printer-driver-hpijs
    
  2. Open printer properties (Printers > Additional Printer Settings > (Right click on printer) Properties > Make and Model) and ensure Brother HL-2140 Foomatic/hpijs-pcl5e is there.

  3. Now Print Test Page should work fine.