CUPS has gone away


 
Thread Tools Search this Thread
Top Forums UNIX for Advanced & Expert Users CUPS has gone away
# 8  
Old 09-18-2017
I am not a Linux expert but this:

Code:
Message from syslogd@server1 at Sep  9 23:31:35 ...
 cupsd: Unable to read "/etc/cups/cupsd.conf" due to errors.

seems to be quite clearly phrased, no?

If there are not non-printable characters in the file (as Corona688 suggested) and there are no privilege problems (post an output of ls -l /etc/cups/cupsd.conf if unsure) I suppose the file is syntactically wrong (i.e. it has content that makes no sense to CUPS).

Try commenting out everything, then try to stop/start the service again. If it works uncomment one part of the file and stop/start again. Repeat this until you have found the part which prevents CUPS from starting.

I hope this helps.

bakunin
# 9  
Old 09-19-2017
Can anybody see any non printing characters?

If so, where are they?

---------- Post updated at 07:04 PM ---------- Previous update was at 06:59 PM ----------

Bakunin -

Sorry, I did not see your reply.

Anyway...
Code:
root@server1:/home/server1#  ls -l /etc/cups/cupsd.conf
-rw-r----- 1 root lp 6737 Sep 10 00:25 /etc/cups/cupsd.conf

TIA

---------- Post updated at 08:11 PM ---------- Previous update was at 07:04 PM ----------

I have commented out ALL the lines. This is what I get from attempting to run CUPS
Code:
This site can’t be reached
localhost refused to connect.
ERR_CONNECTION_REFUSED

I think it is a permission error. Whast is wrong here -

Code:
root@server1:/home/server1#  ls -l /etc/cups/cupsd.conf
-rw-r----- 1 root lp 6895 Sep 19 20:04 /etc/cups/cupsd.conf

# 10  
Old 09-23-2017
Quote:
Originally Posted by Meow613
Code:
root@server1:/home/server1#  ls -l /etc/cups/cupsd.conf
-rw-r----- 1 root lp 6737 Sep 10 00:25 /etc/cups/cupsd.conf

It probably depends on how CUPS is started, but i suppose it is correct. Try changing that to 644 (rw-r--r--) and restart CUPS for a test - if the error mesage stays the same this is not the problem.

Quote:
Originally Posted by Meow613
I have commented out ALL the lines. This is what I get from attempting to run CUPS
Code:
This site can't be reached
localhost refused to connect.
ERR_CONNECTION_REFUSED

I think it is a permission error. Whast is wrong here -
Doesn't it state the reason clearly? "localhost refused to connect": i am not a Linux expert, but as far as i know CUPS opens a network connection to the system it runs on (localhost, or 127.0.0.1) and this obviously fails.

First: now, that the error message has changed it is established that your config file has some error in it. You can and should that correct later. Second: there is also this issue with the refused connection to localhost Possible reasons might be: a host-based firewall rule which prevents this connection, the CUPS process not being allowed to write to /tmp so that it can't create the socket (if i remember correctly it is done it /tmp in Linux).

I can't perhaps tell you all the possible reasons for this in an exhaustive list, but i think you get the gist of it: read the error messages, then try one possible reason after the other and resolve it testwise - if it helps or changes the error, you are one tep further, otherwise step back and repeat.

I hope this helps.

bakunin
# 11  
Old 09-29-2017
I changed the permissions
Code:
root@server1:/home/server1#  ls -l /etc/cups/cupsd.conf
-rwxrwxrwx 1 root lp 6895 Sep 19 20:04 /etc/cups/cupsd.conf

Still doesn't work.

There is no firewall as far as I know.

---------- Post updated at 11:24 PM ---------- Previous update was at 07:13 PM ----------

Purged cups


Code:
root@server1:/etc/cups# apt-get purge cups
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages were automatically installed and are no longer required:
  hplip-data libsane-hpaio python-imaging python-pexpect python-renderpm
  python-reportlab python-reportlab-accel
Use 'apt-get autoremove' to remove them.
The following packages will be REMOVED:
  cups* printer-driver-gutenprint*
0 upgraded, 0 newly installed, 2 to remove and 1 not upgraded.
After this operation, 1,626 kB disk space will be freed.
Do you want to continue? [Y/n] 
(Reading database ... 184084 files and directories currently installed.)
Removing printer-driver-gutenprint (5.2.10-3) ...

Broadcast message from systemd-journald@server1 (Thu 2017-09-28 22:48:46 EDT):

cupsd[14032]: Unable to read "/etc/cups/cupsd.conf" due to errors.


Message from syslogd@server1 at Sep 28 22:48:46 ...
 cupsd: Unable to read "/etc/cups/cupsd.conf" due to errors.
Purging configuration files for printer-driver-gutenprint (5.2.10-3) ...
Removing cups (1.7.5-11+deb8u1) ...
Purging configuration files for cups (1.7.5-11+deb8u1) ...
Processing triggers for man-db (2.7.0.2-5) ...
N: Ignoring file 'sources.list.d' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension
N: Ignoring file 'sources.list.d' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension

Installed CUPS
Code:
root@server1:/etc/apt/sources.list.d# apt-get install cups
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages were automatically installed and are no longer required:
  hplip-data libsane-hpaio python-imaging python-pexpect python-renderpm
  python-reportlab python-reportlab-accel
Use 'apt-get autoremove' to remove them.
The following extra packages will be installed:
  printer-driver-gutenprint
Suggested packages:
  printer-driver-hpcups hplip cups-pdf smbclient gutenprint-doc
  gutenprint-locales
The following NEW packages will be installed:
  cups printer-driver-gutenprint
0 upgraded, 2 newly installed, 0 to remove and 1 not upgraded.
Need to get 0 B/694 kB of archives.
After this operation, 1,626 kB of additional disk space will be used.
Do you want to continue? [Y/n] 
Preconfiguring packages ...
Selecting previously unselected package cups.
(Reading database ... 184000 files and directories currently installed.)
Preparing to unpack .../cups_1.7.5-11+deb8u1_amd64.deb ...
Unpacking cups (1.7.5-11+deb8u1) ...
Selecting previously unselected package printer-driver-gutenprint.
Preparing to unpack .../printer-driver-gutenprint_5.2.10-3_amd64.deb ...
Unpacking printer-driver-gutenprint (5.2.10-3) ...
Processing triggers for man-db (2.7.0.2-5) ...
Setting up cups (1.7.5-11+deb8u1) ...

Broadcast message from systemd-journald@server1 (Thu 2017-09-28 22:57:44 EDT):

cupsd[15065]: Unable to read "/etc/cups/cupsd.conf" due to errors.

Code:
Ignoring file 'sources.list.d' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension
Message from syslogd@server1 at Sep 28 23:01:25 ...
 cupsd: Unable to read "/etc/cups/cupsd.conf" due to errors.

--->>>I think that the above errors are significant, but I do not know how to interpret them <<<---

FYI here is /etc/cups/cupsd.conf
Code:
# Show general information in error_log.
LogLevel warn
MaxLogSize 0
Listen /var/run/cups/cups.sock
#Listen /var/run/cups/cups.sock
Browsing On
BrowseLocalProtocols dnssd
DefaultAuthType Basic
WebInterface Yes
<Location /admin>
  Order allow,deny
</Location>
<Location /admin/conf>
  AuthType Default
  Require user @SYSTEM
  Order allow,deny
</Location>
<Policy default>
  JobPrivateAccess default
  JobPrivateValues default
  SubscriptionPrivateAccess default
  SubscriptionPrivateValues default
  <Limit Create-Job Print-Job Print-URI Validate-Job>
    Order deny,allow
  </Limit>
  <Limit Send-Document Send-URI Hold-Job Release-Job Restart-Job Purge-Jobs Set-Job-Attributes Create-Job-Subscription Renew-Subscription Cancel-Subscription Get-Notifications Reprocess-Job Cancel-Current-Job Suspend-Current-Job Resume-Job Cancel-My-Jobs Close-Job CUPS-Move-Job CUPS-Get-Document>
    Require user @OWNER @SYSTEM
    Order deny,allow
  </Limit>
  <Limit CUPS-Add-Modify-Printer CUPS-Delete-Printer CUPS-Add-Modify-Class CUPS-Delete-Class CUPS-Set-Default CUPS-Get-Devices>
    AuthType Default
    Require user @SYSTEM
    Order deny,allow
  </Limit>
  <Limit Pause-Printer Resume-Printer Enable-Printer Disable-Printer Pause-Printer-After-Current-Job Hold-New-Jobs Release-Held-New-Jobs Deactivate-Printer Activate-Printer Restart-Printer Shutdown-Printer Startup-Printer Promote-Job Schedule-Job-After Cancel-Jobs CUPS-Accept-Jobs CUPS-Reject-Jobs>
    AuthType Default
    Require user @SYSTEM
    Order deny,allow
  </Limit>
  <Limit Cancel-Job CUPS-Authenticate-Job>
    Require user @OWNER @SYSTEM
    Order deny,allow
  </Limit>
  <Limit All>
    Order deny,allow
  </Limit>
</Policy>
<Policy authenticated>
  JobPrivateAccess default
# Show general information in error_log.
LogLevel warn
MaxLogSize 0
Listen /var/run/cups/cups.sock
Listen /var/run/cups/cups.sock
Browsing On
BrowseLocalProtocols dnssd
DefaultAuthType Basic
WebInterface Yes
<Location /admin>
  Order allow,deny
</Location>
<Location /admin/conf>
  AuthType Default
  Require user @SYSTEM
  Order allow,deny
</Location>
<Policy default>
  JobPrivateAccess default
  JobPrivateValues default
  SubscriptionPrivateAccess default
  SubscriptionPrivateValues default
  <Limit Create-Job Print-Job Print-URI Validate-Job>
    Order deny,allow
  </Limit>
  <Limit Send-Document Send-URI Hold-Job Release-Job Restart-Job Purge-Jobs Set-Job-Attributes Create-Job-Subscription Renew-Subscription Cancel-Subscription Get-Notifications Reprocess-Job Cancel-Current-Job Suspend-Current-Job Resume-Job Cancel-My-Jobs Close-Job CUPS-Move-Job CUPS-Get-Document>
    Require user @OWNER @SYSTEM
    Order deny,allow
  </Limit>
  <Limit CUPS-Add-Modify-Printer CUPS-Delete-Printer CUPS-Add-Modify-Class CUPS-Delete-Class CUPS-Set-Default CUPS-Get-Devices>
    AuthType Default
    Require user @SYSTEM
    Order deny,allow
  </Limit>
  <Limit Pause-Printer Resume-Printer Enable-Printer Disable-Printer Pause-Printer-After-Current-Job Hold-New-Jobs Release-Held-New-Jobs Deactivate-Printer Activate-Printer Restart-Printer Shutdown-Printer Startup-Printer Promote-Job Schedule-Job-After Cancel-Jobs CUPS-Accept-Jobs CUPS-Reject-Jobs>
    AuthType Default
    Require user @SYSTEM
    Order deny,allow
  </Limit>
  <Limit Cancel-Job CUPS-Authenticate-Job>
    Require user @OWNER @SYSTEM
    Order deny,allow
  </Limit>
  <Limit All>
    Order deny,allow
  </Limit>
</Policy>
<Policy authenticated>
  JobPrivateAccess default
  JobPrivateValues default
  SubscriptionPrivateAccess default
  SubscriptionPrivateValues default
  <Limit Create-Job Print-Job Print-URI Validate-Job>
    AuthType Default
    Order deny,allow
  </Limit>
  <Limit Send-Document Send-URI Hold-Job Release-Job Restart-Job Purge-Jobs Set-Job-Attributes Create-Job-Subscription Renew-Subscription Cancel-Subscription Get-Notifications Reprocess-Job Cancel-Current-Job Suspend-Current-Job Resume-Job Cancel-My-Jobs Close-Job CUPS-Move-Job CUPS-Get-Document>
    AuthType Default
    Require user @OWNER @SYSTEM
    Order deny,allow
  </Limit>
  <Limit CUPS-Add-Modify-Printer CUPS-Delete-Printer CUPS-Add-Modify-Class CUPS-Delete-Class CUPS-Set-Default>
    AuthType Default
    Require user @SYSTEM
    Order deny,allow
  </Limit>
  <Location />
   Order Deny,Allow
   Deny From All
   Allow From 127.0.0.1
</Location> 

  <Limit Pause-Printer Resume-Printer Enable-Printer Disable-Printer Pause-Printer-After-Current-Job Hold-New-Jobs Release-Held-New-Jobs Deactivate-Printer Activate-Printer Restart-Printer Shutdown-Printer Startup-Printer Promote-Job Schedule-Job-After Cancel-Jobs CUPS-Accept-Jobs CUPS-Reject-Jobs>
    AuthType Default
    Require user @SYSTEM
    Order deny,allow
  </Limit>
  <Limit Cancel-Job CUPS-Authenticate-Job>
    AuthType Default
    Require user @OWNER @SYSTEM
    Order deny,allow
  </Limit>
  <Limit All>
    Order deny,allow
  </Limit>
<Location />
Order Deny,Allow
Deny From All
Allow From 127.0.0.1
</Location> 
</Policy>
JobPrivateAccess default
JobPrivateValues default
SubscriptionPrivateAccess default
SubscriptionPrivateValues default
  JobPrivateValues default
  SubscriptionPrivateAccess default
  SubscriptionPrivateValues default
  <Limit Create-Job Print-Job Print-URI Validate-Job>
    AuthType Default
    Order deny,allow
  </Limit>
  <Limit Send-Document Send-URI Hold-Job Release-Job Restart-Job Purge-Jobs Set-Job-Attributes Create-Job-Subscription Renew-Subscription Cancel-Subscription Get-Notifications Reprocess-Job Cancel-Current-Job Suspend-Current-Job Resume-Job Cancel-My-Jobs Close-Job CUPS-Move-Job CUPS-Get-Document>
    AuthType Default
    Require user @OWNER @SYSTEM
    Order deny,allow
  </Limit>
  <Limit CUPS-Add-Modify-Printer CUPS-Delete-Printer CUPS-Add-Modify-Class CUPS-Delete-Class CUPS-Set-Default>
    AuthType Default
    Require user @SYSTEM
    Order deny,allow
  </Limit>
  <Location />
   Order Deny,Allow
   Deny From All
   Allow From 127.0.0.1
</Location> 

  <Limit Pause-Printer Resume-Printer Enable-Printer Disable-Printer Pause-Printer-After-Current-Job Hold-New-Jobs Release-Held-New-Jobs Deactivate-Printer Activate-Printer Restart-Printer Shutdown-Printer Startup-Printer Promote-Job Schedule-Job-After Cancel-Jobs CUPS-Accept-Jobs CUPS-Reject-Jobs>
    AuthType Default
    Require user @SYSTEM
    Order deny,allow
  </Limit>
  <Limit Cancel-Job CUPS-Authenticate-Job>
    AuthType Default
    Require user @OWNER @SYSTEM
    Order deny,allow
  </Limit>
  <Limit All>
    Order deny,allow
  </Limit>
<Location />
Order Deny,Allow
Deny From All
Allow From 127.0.0.1
</Location> 
</Policy>
#JobPrivateAccess default
JobPrivateValues default
#SubscriptionPrivateAccess default
SubscriptionPrivateValues default
root@server1:/etc/apt/sources.list.d#

# 12  
Old 09-29-2017
Hi.

Shot in the dark -- the sources.list.d directory is supposed to contain filenames that end in list. Here's an example from one of our systems (a CentOS box):
Code:
$ ls /etc/apt/sources.list.d/
rpmforge-extras.list  rpmforge-testing.list  rpmforge.list

And here is one from MiNT:
Code:
$ ls /etc/apt/sources.list.d/
getdeb.list  official-package-repositories.list

However, you apparently have a file name that ends in .d for some reason:
Code:
N: Ignoring file 'sources.list.d' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension

That would be something to correct, but as I say, a shot in the dark, so it may not amount to anything.

Good luck ... cheers, drl

Last edited by drl; 09-29-2017 at 12:15 PM..
# 13  
Old 10-01-2017
drl -

Changed
Code:
sources.list.d

to
Code:
sources.list

. Problem remaint....,
One More step...
Code:
 Unable to read "/etc/cups/cupsd.conf" due to errors.

Can someone please look at
Code:
/etc/cups/cupsd.conf

and see if they can find the error.

TIA
# 14  
Old 10-01-2017
Hi.

Another shot: Googled for cupsd: Unable to read "/etc/cups/cupsd.conf" due to errors. and received 81 hits, the top two being marked solved:

[SOLVED]Mysterious cupsd problem. / Networking, Server, and Protection / Arch Linux Forums

standard operating procedures: CUPS - "cupsd: Unable to read configuration file '/etc/cups/cupsd.conf' - exiting!" - SOLVED

Good luck ... cheers, drl
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

[CUPS] printers not shown after a while

I'm currently running a CUPS server and it shows the printers on other computers just fine, but after a while they disappear. I found out, that restarting /etc/init.d/cups-browsed fixes the problem (for about 15min). When the printers disappear, the cups-browsed service is still running, so I... (0 Replies)
Discussion started by: Gajeela
0 Replies

2. UNIX for Dummies Questions & Answers

CUPS configuration

Hi, I just set up a CUPS server for my printers and want every computer in my home to use it. To connect to the print server with my Ubuntu 14.04 as a client which possibilities are there, if I don't want to use a client.conf in /etc/cups/ (1 Reply)
Discussion started by: Gajeela
1 Replies

3. Solaris

CUPS problems

I am running cups 2.0.2 on solaris 11, trying to get CUPS to report the page count of what was printed correctly. Right now I have the printer configured as post script both on solaris and on the windows box i am printing from. What happens is that when i print more pages than 2, the page count... (0 Replies)
Discussion started by: matt99199
0 Replies

4. UNIX for Dummies Questions & Answers

CUPs automation

A little background information: We are a company that uses Sharp MFP devices for everyone to print on. We have a lot of MAC BYOD devices. All printing is done through a product called PaperCut which is ran on a Windows 2008 R2 server. Sharp charges our company for each print job done in... (1 Reply)
Discussion started by: jdmorecraft
1 Replies

5. UNIX for Advanced & Expert Users

Troubleshooting printing through Cups

Hello Experts, I have been facing an issue with printing through cups configured on Linux server. All was going on well but all of a sudden the printers started giving an error message, "Unsupported format application/postscript!" and we cant get any prints of any printer. Need your help as... (2 Replies)
Discussion started by: Rockyc3400
2 Replies

6. Red Hat

cups printing error

Hi All, Having searched for a solution to this issue i found no suggestions which help my particular problem. I am getting the following error message on 1 of the 3 printers i have configured: recoverable: Network host 'xxx.xxx.xxx.xxx' is busy; will retry in 30 seconds All 3 printers are... (0 Replies)
Discussion started by: Tommyk
0 Replies

7. Red Hat

Problem with compileing CUPS

Hi guys, I'm trying to install a newer version of CUPS and my compilation fails: # ./configure checking for gawk... gawk checking for gcc... gcc checking for C compiler default output file name... a.out checking whether the C compiler works... yes checking whether we are cross compiling...... (4 Replies)
Discussion started by: eliraza6
4 Replies

8. UNIX for Dummies Questions & Answers

how does cups recognize a new driver?

hi there, i am attempting to recognize a network printer on my red hat box. i know the IP, i have procured the correct driver, however, CUPS (nor the add printer utility) doesn't recognize the driver nor the printer type. i am assuming this has to do with the location of the driver. can anyone... (8 Replies)
Discussion started by: vickenyon
8 Replies

9. HP-UX

Installation of CUPS in HP-UX

Hi, Can anybody provide me the download link for CUPS on HP-UX 11i? and point me where i can get thorough help or howtos, certainly detailed, to get cups and hopefully my printer running? Thanks in advance. (6 Replies)
Discussion started by: meeraramanathan
6 Replies
Login or Register to Ask a Question