View previous topic :: View next topic |
Author |
Message |
Infamy Tux's lil' helper
Joined: 26 Nov 2003 Posts: 92
|
Posted: Mon Aug 02, 2004 8:24 pm Post subject: /var/log/messages file 2.6 GB!!! |
|
|
I noticed that my / partition was full, so I started to dig around, and noticed that my messages log was 2.6 GB of text.
log # ls -hl
total 2.6G
-rw-r--r-- 1 root users 48K Apr 25 21:52 XFree86.0.log
-rw-r--r-- 1 root users 53K Apr 24 01:30 XFree86.0.log.old
-rw-r--r-- 1 root users 50K Jul 30 10:59 Xorg.0.log
-rw-r--r-- 1 root users 49K Jul 28 18:52 Xorg.0.log.old
drwxr-xr-x 2 root root 4.0K Mar 1 14:53 cups
-rw-rw---- 1 portage portage 605K Aug 2 16:21 emerge.log
-rw-r--r-- 1 root root 61K Jul 31 00:24 genkernel.log
-rw-r--r-- 1 root root 286K Jul 28 18:54 lastlog
-rw-r--r-- 1 root root 6.7K Apr 22 00:04 log.nmbd
-rw-r--r-- 1 root root 1.9K Apr 21 21:27 log.smbd
-rw------- 1 root root 2.6G Aug 1 03:28 messages
Is there a way to limit the size of this file so that it doesn't use all of my disk space?
Thanks,
Infamy |
|
Back to top |
|
|
br0mGreV Apprentice
Joined: 28 Jul 2004 Posts: 265 Location: Paris, France
|
Posted: Mon Aug 02, 2004 8:38 pm Post subject: |
|
|
the "classic" solution to avoid that kind of issue it to create a different partition for /var/ mount point, so that you system don't get stuck if you get to much messages
A line in your cron can fit for a while
At last, you can use quota to regulate your /var/log directory.
http://www.gentoo.org/doc/en/gentoo-security.xml#doc_chap6_sect3 |
|
Back to top |
|
|
El_Presidente_Pufferfish Veteran
Joined: 11 Jul 2002 Posts: 1179 Location: Seattle
|
Posted: Mon Aug 02, 2004 9:04 pm Post subject: |
|
|
Maybe find out whats spouting all those errors? |
|
Back to top |
|
|
pjp Administrator
Joined: 16 Apr 2002 Posts: 20067
|
Posted: Mon Aug 02, 2004 9:26 pm Post subject: |
|
|
The installation guide briefly discusses a system logger. You should read up on the logger you installed and learn how to configure it for log rotation. _________________ Quis separabit? Quo animo? |
|
Back to top |
|
|
think4urs11 Bodhisattva
Joined: 25 Jun 2003 Posts: 6659 Location: above the cloud
|
Posted: Mon Aug 02, 2004 9:29 pm Post subject: |
|
|
Depending on whether you are using syslog or syslog-ng you might want to have a look onto logrotate or the build-in capabilities syslog-ng has (remove_if_older())
And of course - take a look into the file for the reasons why its getting this huge (in which timeframe btw?).
HTH
T. _________________ Nothing is secure / Security is always a trade-off with usability / Do not assume anything / Trust no-one, nothing / Paranoia is your friend / Think for yourself |
|
Back to top |
|
|
GenKreton l33t
Joined: 20 Sep 2003 Posts: 828 Location: Cambridge, MA
|
Posted: Mon Aug 02, 2004 11:04 pm Post subject: |
|
|
If thats your only log file and you don't split it up a simple cron job could be easier than logrotate.
But thats a LOT of messages. Unless you've been running that system for a hell of a long time I would take a minute to find anything odd in there. |
|
Back to top |
|
|
Infamy Tux's lil' helper
Joined: 26 Nov 2003 Posts: 92
|
Posted: Tue Aug 03, 2004 12:40 am Post subject: |
|
|
Thanks for the response, I will look into these options. A large portion of the text in the log dealt with i2c, which I have since uninstalled. Hopefully a combination of both will help
Thank you,
Infamy |
|
Back to top |
|
|
Kow Apprentice
Joined: 28 Dec 2003 Posts: 227
|
Posted: Tue Aug 03, 2004 6:32 am Post subject: |
|
|
I found a bug once, in the kernel source where a module was outputting stuff that didnt need to be to what gets logged, it had to do with mouse movements and keyboard buttons being pressed - everytime I moved the mouse and keyboard it logged what was pressed, and that was with no special configuration for debug at all, or no extra logging options. In fact, it was a brand new install and I hadnt even gotten to the point of customizing. I think I got at least a 1 gig log file in a day -- depending upon how often I was using the computer.
That was a long time ago now, a year ago probably. _________________ -Kow |
|
Back to top |
|
|
Infamy Tux's lil' helper
Joined: 26 Nov 2003 Posts: 92
|
Posted: Wed Aug 11, 2004 5:19 pm Post subject: |
|
|
lol |
|
Back to top |
|
|
perseguidor Apprentice
Joined: 01 Aug 2004 Posts: 278 Location: West Kingdom of Buenos Aires
|
Posted: Thu Aug 12, 2004 5:21 am Post subject: |
|
|
This is slightly offtopic, but this same thing happened to me the other day and I rejoiced at the 1:1000+ ratio bzip2 offers in this kind of setting _________________ O make me a mask! |
|
Back to top |
|
|
|