Hosed by hic-CUPS

I wrote a blog entry a while ago on setting up the Canon Pixma MP500 on linux. Well, I upgraded CUPS, and everything went to shizzle. It just stopped working, with no obvious explanation.

Tracing back through my original frustrations, I remembered that the single most vexing problem was that of the user running the CUPS programs. After a wasted evening digging around, I discovered that CUPS 1.2 changed the way CUPS runs its programs, in the name of enhanced security:

RunAsUser Removed; The insecure RunAsUser mode has been removed in favor of OS mechanisms such as SELinux
http://www.cups.org/documentation.php/whatsnew.html

Setting

User root

in /etc/cups/cups.conf for some reason is not able to override the user running the programs. Since cifmp500 insists on being run as root (as I mentioned previously), printing will always fail in CUPS 1.2 with a cryptic debug log to /var/log/cups/error_log:

Error: invalid printer model name

The only solution I had was to roll back to CUPS 1.1 . I followed the ArchWiki directions on building obsolete packages to create a package based on version 1.1.23 . Unfortunately, I ran into an issue with the PNG library using a deprecated function. I did not want to downgrade libpng, so I resolved the issue (hopefully) with a patch. Here’s the CUPS 1.1.23 package source with the PNG patch. To build and deploy:

% tar xvfz cups.tar.gz
% cd cups
% makepkg
% su
% pacman -R cups
% pacman -A -f cups-1.1.23-5.pkg.tar.gz

I still had to go back and twiddle the user setting in cupsd.conf … but an invocation of cngpij finally woke up the printer and did something! Hooray!

Guess what I’m about to do right now?

/etc/pacman.conf:

IgnorePkg   = kernel26 cups

Leave a Reply


Bad Behavior has blocked 523 access attempts in the last 7 days.