Problems with cups and umask
Issue
-
We have a cups server running and we've changed the default umask to 077. Our problem is when we try to add a printer with the command lpadmin from a user with rights, then we obtain the next error:
$ lpadmin -p pr2 -v socket://10.1.2.3:9100 -P "/tmp/RicohAficioSP4510DN.ppd" -E lpadmin: Unable to open PPD file "/tmp/56cecb4709851" - Permission deniedAfter that if we list the directory
/etc/cups/ppd, you can see the ppd was copied with wrong rights:# ll /etc/cups/ppd/ total 144 -rw-r----- 1 root root 71629 Feb 25 10:37 pr2.ppd -
Our default
umaskfor root is normally022and002for regular users. We are getting the following errors in the CUPS Error Log:D [01/Jun/2016:11:17:10 -0500] [Job 318] foomatic-rip version 4.0.4.217 running... D [01/Jun/2016:11:17:10 -0500] [Job 318] Process is dying with "Unable to open PPD file /etc/cups/ppd/lp2.ppd D [01/Jun/2016:11:17:10 -0500] [Job 318] ", exit stat 9 -
We have added the line "
umask 027" to/etc/sysconfig/init. When we do this some CUPS jobs fail because the permissions on the PPD files are incorrect:-rw-r-----. 1 root root 253222 Feb 27 15:10 adminpr.ppd
Environment
- Red Hat Enterprise Linux (RHEL) 6 & 6
- Common Unix Printing System (CUPS) 1.4.2 & 1.6.3
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.