Board index Other Hangar talk

Linux "cups" log file heartache

Talk about (almost) anything, as long as it is no serious FlightGear talk and does not fit in the other subforums.
Forum rules
Please refrain from discussing politics.

Linux "cups" log file heartache

Postby wlbragg » Thu Jun 15, 2017 6:57 am

I just spent the better part of a day troubleshooting my Debian "stretch" install. A "CUPS" log file (66gig) caused a major problem trying to boot after a thunderstorm knocked out our power last night. I guess it ate up my entire free space on my solid state drive. Once I found it and deleted it I was able to get back in and repair the damage.
Don't have the foggiest idea how it got so large, or what cups is for for all that matters.
Kansas and Ohio/Midwest scenery development.
KEQA, 3AU, KRCP Airport Layout
Intel i7/GeForce RTX 2070/Max-Q
User avatar
wlbragg
 
Posts: 7586
Joined: Sun Aug 26, 2012 12:31 am
Location: Kansas (Tornado Alley), USA
Callsign: WC2020
Version: next
OS: Win10/Linux/RTX 2070

Re: Linux "cups" log file heartache

Postby Ovazor » Thu Jun 15, 2017 8:08 am

Cups is the printing system, so the log files contain data related on printers and print jobs. Maybe there is some error that gets logged again and again?

There should be a file /etc/cups/cupsd.conf , where you can set the value MaxLogSize to limit the sizes of log files
Flying the Dakota
Ovazor
 
Posts: 76
Joined: Wed Feb 12, 2014 7:53 am
Location: Finland
Callsign: OH-OVA
Version: 2020.4.0
OS: OpenSUSE LEap 15.2

Re: Linux "cups" log file heartache

Postby wlbragg » Thu Jun 15, 2017 6:07 pm

Thank you, I really need this. I woke up this morning again to a broken cpu. Overnight night cups logged another 56gig if error messages. I need to find out what's broke but in the mean time limiting the size will help. I'm running on a solid state drive and I am afraid all this writing is going to damage it.

Unfortunately, the config file shows this

Code: Select all
# Deactivate CUPS' internal logrotating, as we provide a better one, especially
# LogLevel debug2 gets usable now
MaxLogSize 0


I'm not sure what "A better one" means. However the log in question is the error_log. But it is the locked log file (either needs to be root, or I don't know).

I deleted the log in order to boot. By the time I went to the log to see if it changed it was already 18gig. I tried a root mouspad to view the log but it hung. I am kind of stumped as to how to read the log file.

The bootup process hangs at
Code: Select all
Started update UTMP about System Runlevel Changes


So my startup consists of alt+f1 to terminal at the hangup, login to wayne and run startx to GUI.

Kind of a cluster-#$$%.

I'm still researching the UTMP hangup but it is inconclusive so far.
Kansas and Ohio/Midwest scenery development.
KEQA, 3AU, KRCP Airport Layout
Intel i7/GeForce RTX 2070/Max-Q
User avatar
wlbragg
 
Posts: 7586
Joined: Sun Aug 26, 2012 12:31 am
Location: Kansas (Tornado Alley), USA
Callsign: WC2020
Version: next
OS: Win10/Linux/RTX 2070

Re: Linux "cups" log file heartache

Postby wlbragg » Thu Jun 15, 2017 8:26 pm

Well the cups problem was a file permission issue which I fixed. That makes me a bit nervous though that there is some serious degradation of system file permissions.
Kansas and Ohio/Midwest scenery development.
KEQA, 3AU, KRCP Airport Layout
Intel i7/GeForce RTX 2070/Max-Q
User avatar
wlbragg
 
Posts: 7586
Joined: Sun Aug 26, 2012 12:31 am
Location: Kansas (Tornado Alley), USA
Callsign: WC2020
Version: next
OS: Win10/Linux/RTX 2070

Re: Linux "cups" log file heartache

Postby Ovazor » Fri Jun 16, 2017 12:42 pm

Set a value for the MaxLogSize - 0 means "unlimited". Try e.g. 10m
Flying the Dakota
Ovazor
 
Posts: 76
Joined: Wed Feb 12, 2014 7:53 am
Location: Finland
Callsign: OH-OVA
Version: 2020.4.0
OS: OpenSUSE LEap 15.2

Re: Linux "cups" log file heartache

Postby wlbragg » Fri Jun 16, 2017 6:16 pm

Thanks for explaining that, it was worded such that I thought that line was disabling the internal logrotating and they are using something else.

Unfortunately, changing the log size in this case would not have fixed the problem. I would have ended up with a billion small logs, until I ran out of space. But still worth knowing how it work.

I could literally watch the log file size grow it was erring so fast. I think it took several hours to eat all the free space.

My system is stable for now, I'll reinstall in a week or so after "stretch" is made the next release.
Kansas and Ohio/Midwest scenery development.
KEQA, 3AU, KRCP Airport Layout
Intel i7/GeForce RTX 2070/Max-Q
User avatar
wlbragg
 
Posts: 7586
Joined: Sun Aug 26, 2012 12:31 am
Location: Kansas (Tornado Alley), USA
Callsign: WC2020
Version: next
OS: Win10/Linux/RTX 2070

Re: Linux "cups" log file heartache

Postby swampthing » Sat Jan 13, 2018 12:30 am

I just did a rolling update for Linux Mint to 18.3 to get a message that my hard drive space was low I'm left with just less than 4 gigs and it was 2 i deleted all of my videos and anything else I could find that I don't need left on there but I don't have a clue what is causing it. Maybe it the same problem. I got updates that said in the change log were to revert back to the old file due to errors. They certainly screwed up somewhere.
www.opredflag.com
I have sworn upon the altar of God, eternal hostility against every form of tyranny over the mind of man. -Thomas Jefferson-
swampthing
 
Posts: 591
Joined: Wed Oct 28, 2015 5:10 am
Location: Missouri
Callsign: swamp
Version: 2018.2
OS: multiple

Re: Linux "cups" log file heartache

Postby swampthing » Sat Jan 13, 2018 12:55 am

It also says my hard drive is 160 gig when it is 250 gig.Nvidia driver shows it is loaded but my resolution is low and I can't change to the proper resolution. it reminds me of when Windows loads a generic video driver.
www.opredflag.com
I have sworn upon the altar of God, eternal hostility against every form of tyranny over the mind of man. -Thomas Jefferson-
swampthing
 
Posts: 591
Joined: Wed Oct 28, 2015 5:10 am
Location: Missouri
Callsign: swamp
Version: 2018.2
OS: multiple

Re: Linux "cups" log file heartache

Postby wlbragg » Sat Jan 13, 2018 5:21 am

Maybe it the same problem

Probably not, I was the cause of my problem, something dumb I did.
I have yet to redo my system because I was able to get it stable enough for my purposes.

You may have to get some support from the Mint folks to figure out what went wrong with your upgrade.

Linux video drivers have always been a headache for me. Although lately since I switched to Nvidia it has been much easier to get a driver that works.
Kansas and Ohio/Midwest scenery development.
KEQA, 3AU, KRCP Airport Layout
Intel i7/GeForce RTX 2070/Max-Q
User avatar
wlbragg
 
Posts: 7586
Joined: Sun Aug 26, 2012 12:31 am
Location: Kansas (Tornado Alley), USA
Callsign: WC2020
Version: next
OS: Win10/Linux/RTX 2070

Re: Linux "cups" log file heartache

Postby swampthing » Sun Jan 21, 2018 9:27 pm

It wasa big enough mess I just hit reset and installed a clean version. good thing for github. Its not my favorite thing to download and install everything again but I believe I would still be scratching my head if I didn't. I don't think I'll do another rolling upgrade. ;)
www.opredflag.com
I have sworn upon the altar of God, eternal hostility against every form of tyranny over the mind of man. -Thomas Jefferson-
swampthing
 
Posts: 591
Joined: Wed Oct 28, 2015 5:10 am
Location: Missouri
Callsign: swamp
Version: 2018.2
OS: multiple

Re: Linux "cups" log file heartache

Postby swampthing » Sun Jan 21, 2018 9:30 pm

wlbragg, This is off topic but I noticed the scenery development at the bottom of your post. Anyone thinking of doing KSTL? :)
www.opredflag.com
I have sworn upon the altar of God, eternal hostility against every form of tyranny over the mind of man. -Thomas Jefferson-
swampthing
 
Posts: 591
Joined: Wed Oct 28, 2015 5:10 am
Location: Missouri
Callsign: swamp
Version: 2018.2
OS: multiple

Re: Linux "cups" log file heartache

Postby wlbragg » Sun Jan 21, 2018 9:50 pm

Not that I know of.
Kansas and Ohio/Midwest scenery development.
KEQA, 3AU, KRCP Airport Layout
Intel i7/GeForce RTX 2070/Max-Q
User avatar
wlbragg
 
Posts: 7586
Joined: Sun Aug 26, 2012 12:31 am
Location: Kansas (Tornado Alley), USA
Callsign: WC2020
Version: next
OS: Win10/Linux/RTX 2070

Re: Linux "cups" log file heartache

Postby icecode » Sat Feb 17, 2018 11:15 pm

This is kind of a late answer, but my two cents:
I usually create a separate /var partition in most of my systems. If you work (or tinker) with databases, web servers etc. you might find /var to be a mess and filled with logs. Separating it from the root filesystem prevents a whole system breakage when logs fill up. If you have a SSD you can also move this partition to a HDD to avoid unnecessary reads and writes since /var's data is very volatile.
icecode
 
Posts: 709
Joined: Thu Aug 12, 2010 1:17 pm
Location: Spain
Version: next
OS: Fedora

Re: Linux "cups" log file heartache

Postby www2 » Mon Feb 19, 2018 11:41 pm

@Icecode GL
SSD Reads are not the problem the writes.
Btw i have an simalar setup on my laptop and pc: / <root> SSD, /var /home and temp fs on my HDD.
www2
 
Posts: 319
Joined: Thu Apr 16, 2009 2:58 pm
OS: Ubuntu


Return to Hangar talk

Who is online

Users browsing this forum: No registered users and 5 guests