1

Recently, I've started to run out of space on my startup disk. I used Disk Inventory X to identify large files that could be removed. It seems that the kernel*.log files have become GB in size (one was 60GB+).

To fix the problem, I delete the files, restart (to release locks), then empty the trash.

Is this a normal behavior for these log files? Is there anything that I can do to prevent these from becoming so large? Might their size be associated with certain types of usage (e.g. VPN)?

** edit 0 **

There are a number of files that follow this pattern: kernel.log[.0-5][.bz2]. They are ~20MB in size. Apparently, this issue is period and difficult to reproduce.

** edit 1 **

I upgraded my OS to Lion. We'll see if this addresses the problem. I'll post the results.

2 Answers 2

2

Oh, my no. Logfiles in OSX (and Unix in general) are usually rotated (that is, moved into another file and compressed, then later deleted) with newsyslog. OSX should do this every half an hour.

Either your kernel just did a lot of stuff in the past half hour or your log rotation is broken.

6
  • How would I know which is the case?
    – Craig
    Aug 16, 2011 at 13:46
  • @Craig The easiest (if not the least involved) way is to just look at the file every 5 minutes or so to see if it shrinks.
    – digitxp
    Aug 16, 2011 at 14:24
  • 1
    Look at the beginning of the log file and see how old the first few entries are.
    – JRobert
    Aug 16, 2011 at 14:32
  • That too. (Though you're probably gonna want to use more to open a potentially 60gb logfile.)
    – digitxp
    Aug 16, 2011 at 15:31
  • @digitxp: how do i fix a broken log rotation?
    – Craig
    Aug 17, 2011 at 13:17
0

I upgraded Lion; problem solved. Now on Mountain Lion; problem has not resurfaced.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .