CUPS service not working, can't find any logs
Solution 1
After a bit of searching and playing around, thanks to @Benjamin's comment above, I finally found that there is a default configuration file which should be installed in /usr/share/cups/cupsd.conf.default
.
I ran
sudo cp /usr/share/cups/cupsd.conf.default /etc/cups/cupsd.conf
sudo service cups restart
and since then it worked!
I still have no idea how the file got lost in the first place though.
Solution 2
I ran:
sudo apt-get purge cups
sudo apt-get install cups --install-suggests
and then I checked that the configuration was correct. I still got a cups error trying to access a network HP printer, and I had to reinstall the printer, and then I got it to work.
Related videos on Youtube
ec2011
Updated on September 18, 2022Comments
-
ec2011 almost 2 years
I am running Ubuntu 14.10 and when I open up the Printers dialog, I get an error message "Printing service not available. Start the service on this computer or connect to another server".
The start service button is greyed out.
I have tried
$ sudo service cups start start: Job is already running: cups
Followed by
ps -ef|grep cups | grep -v grep root 1210 1 0 08:15 ? 00:00:03 /usr/sbin/cups-browsed
I've tried to find some information in the logs about this, but the logs haven't been touched for days (and they are zero bytes)
ls -t -l total 96 -rw-r----- 1 root lpadmin 0 Jan 3 08:45 access_log -rw-r----- 1 root lpadmin 0 Jan 3 08:45 page_log -rw-r----- 1 root lpadmin 7920 Jan 2 13:22 access_log.1 -rw-r----- 1 root lpadmin 3389 Jan 2 13:17 page_log.1 -rw-r----- 1 root lpadmin 125 Dec 31 09:20 access_log.2.gz -rw-r----- 1 root lpadmin 0 Dec 31 08:29 error_log ...
Only other clue I've found is the following repeated many times in
dmesg
[17169.471390] audit: type=1400 audit(1421413284.183:1700): apparmor="STATUS" operation="profile_replace" profile="unconfined" name="/usr/lib/cups/backend/cups-pdf" pid=26540 comm="apparmor_parser" [17169.471398] audit: type=1400 audit(1421413284.183:1701): apparmor="STATUS" operation="profile_replace" profile="unconfined" name="/usr/sbin/cupsd" pid=26540 comm="apparmor_parser" [17169.492953] audit: type=1400 audit(1421413284.207:1702): apparmor="STATUS" operation="profile_replace" profile="unconfined" name="third_party" pid=26540 comm="apparmor_parser" [17169.496523] init: cups main process (26541) terminated with status 1 [17169.496532] init: cups main process ended, respawning
I've tried
sudo apt-get purge cups sudo apt-get install cups --install-suggests
but still no change.
I've filed a bug about this at https://bugs.launchpad.net/ubuntu/+source/cups/+bug/1407958 but is there anything obvious I've missed/should have checked?
-
Benjamin over 9 yearstry again and check logs in: tail /var/log/syslog
-
Rinzwind over 9 yearsThat "ps" is wrong. I would have expected also to see a
/usr/sbin/cupsd
-
ec2011 over 9 years@Benjamin, I think I see the problem. In /var/log/syslog, I see the error ` cupsd: Unable to open "/etc/cups/cupsd.conf": No such file or directory` How can I force this file to get recreated?
-
-
David Foerster over 7 yearsThat has pretty much the same effect as restoring the default configuration and restarting the CUPS service like in the accepted answer – but it's far more laborious.
-
Python Jim over 7 yearsTo respond the the prior comment, the hplip needed to be removed and reinstalled using sudo apt-get purge hplp, then sudo apt-get hplip.
-
David Foerster over 7 yearsWhy? Why was it not enough to reset the configuration and restart the service? The commands in your answer achieve no other outcome than that.
-
Python Jim over 7 yearsThe problem was when cups got corrupted it had corrupted my hplip service as well, and restoring cups did not restore the hplip service, that is why the second install was required.
-
Ace about 7 yearssolved my issue with cups in 16.10
-
Deepam Gupta about 3 yearsThis installed a lot of packages in my PC which were never needed.