From: Ian Gregory on 6 Jan 2010 11:01 On 2010-01-06, Sn!pe <snipe(a)spambin.fsnet.co.uk> wrote: > My local hard drive is getting full so I'd like to clear some cruft. > I find that /private/var/log/kernel.log.1has grown to over 6 GB; > how can I reclaim some of this disk space, please? Can I simply > delete it? TIA. The traditional way of truncating log files in Unix is: cat /dev/null > $LOGFILE That way it doesn't need to get recreated and there is no danger of deleting it while it is being written to. However, in your case the log file ends in ".1" which probably means that it is not being written to anyway. There should also be a newer file with the same name but without the ".1" ending, and that would be the active log file. At one point it must have got big and then some periodic job "rotated" the logs. So if you don't think you will need to look at the old logs for diagnostic purposes then there is almost certainly no harm in just deleting the ".1" file. Ian -- Ian Gregory http://www.zenatode.org.uk/ian/
From: Tom Stiller on 6 Jan 2010 11:47 In article <1jbwlb0.1gcyglu1fs8g1cN%snipe(a)spambin.fsnet.co.uk>, snipe(a)spambin.fsnet.co.uk (Sn!pe) wrote: > Model Identifier: MacBookPro4,1 > Processor Name: Intel Core 2 Duo > Processor Speed: 2.6 GHz > RAM 2 GB > System Version: Mac OS X 10.6.2 (10C540) > Kernel Version: Darwin 10.2.0 > > Hi, Group. > > My local hard drive is getting full so I'd like to clear some cruft. > I find that /private/var/log/kernel.log.1has grown to over 6 GB; > how can I reclaim some of this disk space, please? Can I simply > delete it? TIA. Check the "clean" sections of file /etc/defaults/periodic.conf for the options that suit your mode of operation. -- Tom Stiller PGP fingerprint = 5108 DDB2 9761 EDE5 E7E3 7BDA 71ED 6496 99C0 C7CF
From: Jolly Roger on 6 Jan 2010 11:56 In article <1jbwlb0.1gcyglu1fs8g1cN%snipe(a)spambin.fsnet.co.uk>, snipe(a)spambin.fsnet.co.uk (Sn!pe) wrote: > Model Identifier: MacBookPro4,1 > Processor Name: Intel Core 2 Duo > Processor Speed: 2.6 GHz > RAM 2 GB > System Version: Mac OS X 10.6.2 (10C540) > Kernel Version: Darwin 10.2.0 > > Hi, Group. > > My local hard drive is getting full so I'd like to clear some cruft. > I find that /private/var/log/kernel.log.1has grown to over 6 GB; > how can I reclaim some of this disk space, please? Can I simply > delete it? TIA. You should look at the log to figure out what is filling it up. My kernel log is only 745k, with mostly messages from VMware and Cisco VPN client in it. -- Send responses to the relevant news group rather than email to me. E-mail sent to this address may be devoured by my very hungry SPAM filter. Due to Google's refusal to prevent spammers from posting messages through their servers, I often ignore posts from Google Groups. Use a real news client if you want me to see your posts. JR
From: John Varela on 6 Jan 2010 17:28 On Wed, 6 Jan 2010 15:35:20 UTC, snipe(a)spambin.fsnet.co.uk (Sn!pe) wrote: > Model Identifier: MacBookPro4,1 > Processor Name: Intel Core 2 Duo > Processor Speed: 2.6 GHz > RAM 2 GB > System Version: Mac OS X 10.6.2 (10C540) > Kernel Version: Darwin 10.2.0 > > Hi, Group. > > My local hard drive is getting full so I'd like to clear some cruft. > I find that /private/var/log/kernel.log.1has grown to over 6 GB; > how can I reclaim some of this disk space, please? Can I simply > delete it? TIA. How did you get the size in bytes? I'm unfamiliar with the Un*x command line, and all I can get is the size in blocks, but I don't know how big is a block. I installed Snow Leopard not long ago and I see that my system log is already almost 170K blocks. Should I worry? -- John Varela Trade NEWlamps for OLDlamps for email
From: Tom Harrington on 6 Jan 2010 17:39
In article <dxizd0mOwXzR-pn2-sinsTPMBEbnJ(a)localhost>, "John Varela" <OLDlamps(a)verizon.net> wrote: > How did you get the size in bytes? I'm unfamiliar with the Un*x > command line, and all I can get is the size in blocks, but I don't > know how big is a block. Try "du -sh" or "du -sk" on the directory you're interested in. -- Tom "Tom" Harrington Independent Mac OS X developer since 2002 http://www.atomicbird.com/ |