This is still not fixed. On a fresh install of feisty, I still see the
following in syslog:
Jul 10 07:35:04 zadok cupsd: Unable to open log file
/var/log/cups/error_log - Permission denied
Here is the listing for that directory:
[EMAIL PROTECTED] tmp]$ ll /var/log/cups
total 60
drwxr-xr-x 2 root root4096 2007-07-10 07:35 ./
drwxr-xr-x 9 root root4096 2007-07-10 07:37 ../
-rw-r- 1 cupsys lpadmin0 2007-07-06 07:37 access_log
-rw-r--r-- 1 cupsys lp 207 2007-07-05 11:59 access_log.1.gz
-rw-r--r-- 1 cupsys lp 137 2007-07-04 19:10 access_log.2.gz
-rw-r--r-- 1 cupsys lp 134 2007-07-03 08:13 access_log.3.gz
-rw-r- 1 cupsys lpadmin 144 2007-06-29 13:28 access_log.4.gz
-rw-r- 1 cupsys lpadmin 124 2007-06-25 00:53 access_log.5.gz
-rw-r- 1 cupsys lpadmin 843 2007-07-10 07:35 error_log
-rw-r- 1 cupsys lpadmin 358 2007-07-09 07:35 error_log.1.gz
-rw-r- 1 cupsys lpadmin 364 2007-07-08 07:35 error_log.2.gz
-rw-r- 1 cupsys lpadmin 357 2007-07-07 07:35 error_log.3.gz
-rw-r- 1 cupsys lpadmin 585 2007-07-06 13:16 error_log.4.gz
-rw-r--r-- 1 cupsys lpadmin 484 2007-07-05 11:59 error_log.5.gz
-rw-r- 1 cupsys lpadmin 110 2007-06-30 22:01 error_log.6.gz
-rw-r- 1 cupsys lpadmin 95 2007-06-27 09:00 error_log.7.gz
-rw-r- 1 cupsys lpadmin0 2007-06-21 23:44 page_log
and cupsd is running as user 'lp':
[EMAIL PROTECTED] tmp]$ ps auxw | grep cupsd
lp 10308 0.0 0.0 4704 1816 ?SNs 07:35 0:00 /usr/sbin/cupsd
ahawtho 11000 0.0 0.0 2888 776 pts/3S+ 09:10 0:00 grep cupsd
According to /proc/10308, it also is running with group lpadmin:
[EMAIL PROTECTED] tmp]$ ll -d /proc/10308
dr-xr-xr-x 5 lp lpadmin 0 2007-07-10 08:44 /proc/10308/
/etc/cups/cupsd.conf has the lines:
User lp
...
Group lpadmin
But /etc/init.d/cupsys has seemingly conflicting permissions (look for
):
case $1 in
start)
log_begin_msg Starting $DESC: $NAME
Here, we have root:lpadmin, with 3775
chown root:lpadmin /usr/share/ppd/custom 2/dev/null || true
chmod 3775 /usr/share/ppd/custom 2/dev/null || true
mkdir -p `dirname $PIDFILE`
Here we have cupsys:lp (not lpadmin), but the directory shows
lp:lpadmin
chown cupsys:lp `dirname $PIDFILE`
# create the logs file since cupsd can't
for l in access_log page_log error_log; do
[ -e /var/log/cups/$l ] || touch /var/log/cups/$l
chmod 640 /var/log/cups/$l
Here we have cupsys:lpadmin, with permissions 640, but since
cupsd is run as user 'lp', not 'cupsys', these files are not writable
chown cupsys:lpadmin /var/log/cups/$l
done
if [ $LOAD_LP_MODULE = yes -a -f /usr/lib/cups/backend/parallel \
-a -f /proc/devices -a -f /proc/modules \
-a -x /sbin/modprobe ]; then
modprobe -q lp || true
modprobe -q ppdev || true # for ISO-1284 device name detection
fi
start-stop-daemon --start --quiet --oknodo --pidfile $PIDFILE
--exec $DAEMON
# Correct the permissions after starting the CUPS daemon
for l in access_log page_log error_log; do
chmod 640 /var/log/cups/$l || true
Here again, cupsys:lpadmin, but cupsd is lp:lpadmin.
chown cupsys:lpadmin /var/log/cups/$l || true
done
log_end_msg $?
;;
I'd be happy to submit a patch, but I'm not sure which users/groups are
correct since there are 2 of each.
--
cupsys cannot create error_log
https://bugs.launchpad.net/bugs/41267
You received this bug notification because you are a member of Ubuntu
Bugs, which is a direct subscriber.
--
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs