LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > CentOS
User Name
Password
CentOS This forum is for the discussion of CentOS Linux. Note: This forum does not have any official participation.

Notices


Reply
  Search this Thread
Old 11-23-2015, 09:37 AM   #1
tonreg
LQ Newbie
 
Registered: Nov 2015
Posts: 18

Rep: Reputation: Disabled
Question Printing control files accumulate in the directory /var/spool/cups


I'm using CUPS 1.4.2 and the printing control files accumulate in the directory
/var/spool/cups. Is this standard for cups or can it easily be changed??

I'ld be very happy if I could get an answer to this question.

Many thanks in advance

tonreg
 
Old 11-24-2015, 07:03 AM   #2
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,784

Rep: Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937
Yes, the default is to keep job history files and yes it can be changed. The limit is the last 500 jobs but it is not the actual print file and therefore their size is small.

Set JobPerserveHistory No in your cupsd.conf file.
 
Old 11-24-2015, 07:31 AM   #3
tonreg
LQ Newbie
 
Registered: Nov 2015
Posts: 18

Original Poster
Rep: Reputation: Disabled
Hello michaelk,

many thanks for your immediate reply. The problem is: How can I set this option. And by the way I presume the name of the "option" is JobPreserveHistory??!!

I tried "man cupsd.conf" and "man cupsd" but I couldn't find any hint about JobPreserveHistory. Please help a LQ Newbie to collect a tiny bit of knowledge.

Regards

Gernot
 
Old 11-24-2015, 07:50 AM   #4
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,784

Rep: Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937
Edit the file (as root) and add JobPerserveHistory off to your cupsd.conf file. A good place would be below the maxlogsize line.
 
Old 11-25-2015, 05:38 AM   #5
tonreg
LQ Newbie
 
Registered: Nov 2015
Posts: 18

Original Poster
Rep: Reputation: Disabled
Hello michaelk,

I'm still having problems. I tried "JobPerserveHistory" and got this message in the error_log
E [24/Nov/2015:17:40:15 +0100] Unknown directive JobPerserveHistory on line 3.
Then I changend it to JobPreserveHistory and got this message:
E [25/Nov/2015:11:35:41 +0100] Unknown directive JobPreserveHistory on line 3.

Here are the first 6 lines from my cupsd.conf:

DefaultEncryption Never
MaxLogSize 0
JobPreserveHistory No
LogLevel debug
SystemGroup sys root
# Allow remote access

Is there a document which describes the structure and details of cupsd.conf??
I will still try two things:
JobPreserveHistory Off
JobPreserveHistory Off

Perhaps one of these two is o.k.

Regards

Gernot
 
Old 11-25-2015, 05:47 AM   #6
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,784

Rep: Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937
Sorry, it appears I was a bit dyslexic. It should be
PreserveJobHistory Yes
or
PreserveJobHistory No

http://linux.die.net/man/5/cupsd.conf
 
1 members found this post helpful.
Old 11-25-2015, 06:13 AM   #7
tonreg
LQ Newbie
 
Registered: Nov 2015
Posts: 18

Original Poster
Rep: Reputation: Disabled
Hello michaelk,

your hint with the link solved the problem.

The actual parameters are:

Specifies whether or not to preserve job files after they are printed.
PreserveJobHistory Yes
PreserveJobHistory No

This seems to be specific to this old version of cups??!

Many thanks for your help!!

There is still a little other problem with the error_log:
E [25/Nov/2015:13:06:44 +0100] Missing value for 192.168.1.104:631 on line 9.

I always get this message. Which file is wrong??
 
Old 11-25-2015, 06:17 AM   #8
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,784

Rep: Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937
I have not seen any similar error messages before. Could be your specific your printer configuration files.
 
Old 11-25-2015, 08:12 AM   #9
tonreg
LQ Newbie
 
Registered: Nov 2015
Posts: 18

Original Poster
Rep: Reputation: Disabled
Hello michaelk,

the files in the directory /var/spool/cups are still accumulating (
-rw-------. 1 root lp 725 23. Nov 13:57 c00244
-rw-------. 1 root lp 885 24. Nov 17:37 c00245
-rw-------. 1 root lp 885 24. Nov 17:41 c00246
-rw-------. 1 root lp 885 24. Nov 17:51 c00247
-rw-------. 1 root lp 885 25. Nov 13:16 c00248
-rw-------. 1 root lp 885 25. Nov 15:08 c00249)
, although I don't get any error messages in the error_log.

Have you got another idea why this happens
 
Old 11-25-2015, 08:16 AM   #10
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,784

Rep: Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937
Did you restart cups?
 
Old 11-25-2015, 09:35 AM   #11
tonreg
LQ Newbie
 
Registered: Nov 2015
Posts: 18

Original Poster
Rep: Reputation: Disabled
I restarted cups and as that didn't work I restarted the complete system
 
Old 11-25-2015, 11:53 AM   #12
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,784

Rep: Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937
I don't know at the moment since it works for me. Check the cups error_log again just to make sure since you restarted the system.
I assume you did edit the cupsd.conf file as root?
 
Old 11-26-2015, 07:27 AM   #13
tonreg
LQ Newbie
 
Registered: Nov 2015
Posts: 18

Original Poster
Rep: Reputation: Disabled
Hello michaelk,

I'm back again. You wrote: "I have not seen any similar error messages before. Could be your specific your printer configuration files". I've checked and found out that this error message is caused by my cupsd.conf.
############### Start of cupsd.conf (10 lines)
DefaultEncryption Never
MaxLogSize 0
PreserveJobFiles No
LogLevel debug
SystemGroup sys root
# Allow remote access
Port 631
Listen /var/run/cups/cups.sock
# Test line
192.168.1.104:631
############### End of cupsd.conf (10 lines)

The corresponding message in error_log reads:
E [26/Nov/2015:12:46:59 +0100] Missing value for 192.168.1.104:631 on line 10.

I'ld be extremely happy if you'ld have an idea about this message now.

By the way, the files:

-rw-------. 1 root lp 725 23. Nov 13:57 c00244
-rw-------. 1 root lp 885 24. Nov 17:37 c00245
-rw-------. 1 root lp 885 24. Nov 17:41 c00246
-rw-------. 1 root lp 885 24. Nov 17:51 c00247
-rw-------. 1 root lp 885 25. Nov 13:16 c00248
-rw-------. 1 root lp 885 25. Nov 15:08 c00249

are still accumulating

Regards

Gernot
 
Old 11-27-2015, 03:57 PM   #14
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,784

Rep: Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937Reputation: 5937
Delete 192.168.1.104:631

Where did you add PreserveJobHistory No in the cupsd.conf file?
 
1 members found this post helpful.
Old 11-30-2015, 09:06 AM   #15
tonreg
LQ Newbie
 
Registered: Nov 2015
Posts: 18

Original Poster
Rep: Reputation: Disabled
Hello michaelk,
many thanks for your message. As I didn't get any mail from Linuxquestions I didn't expect any answer.

1) I will delete 192.168.1.104:631
2) I will add PreserveJobHistory No in cupsd.conf!! By mistake I inserted PreserveJobFiles No.
I'll let you know about success or failure after the modifications have been tested

Regards

Gernot
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Need a script for automatically cleaning up /var/spool/cups directory everyday thamim123 Linux - General 2 04-08-2014 09:44 AM
Samba/Cups print sharing problems (/var/spool/samba files) Gates1026 Linux - General 9 06-23-2013 01:33 AM
How to prevent /var/spool/cups from becoming full? tasdca Linux - Software 3 09-08-2011 08:32 PM
cps printing problem - /var/spool (permission denied) carboncopy Slackware 10 11-11-2004 03:28 AM
Printing from Mozilla creates 200Mb files in /var/spool/cups mikeyt_333 Linux - Software 3 05-23-2004 12:47 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > CentOS

All times are GMT -5. The time now is 11:00 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration