LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 02-11-2008, 04:28 PM   #1
(((X)))
LQ Newbie
 
Registered: Dec 2007
Posts: 16

Rep: Reputation: 0
deleting /var/log


I would like to delete everything in /var/log to get more space, I donīt need them anymore..
I donī t want to get into trouble with that, so I want to know it is safe or not
 
Old 02-11-2008, 04:37 PM   #2
leonscape
Senior Member
 
Registered: Aug 2003
Location: UK
Distribution: Debian SID / KDE 3.5
Posts: 2,313

Rep: Reputation: 47
Usually log files are made with ordering so you'll get:

dmesg
dmesg.0
dmesg.1.gz
dmesg.2.gz
etc...

The compressed ones are usually very safe to remove, the ones with 0 are usually back ups of the live logs, you don't want to be deleting dmesg when the kernels trying to write to it. The others without this scheme you can usually delete the older versions quite easily, but I'd leave the latest, you never know whats trying to write to them or when it will be useful.

Most system delete the oldest ones anyway, I know my system only keeps dmesg.4.gz anything older gets removed automatically.
 
Old 02-11-2008, 06:09 PM   #3
gilead
Senior Member
 
Registered: Dec 2005
Location: Brisbane, Australia
Distribution: Slackware64 14.0
Posts: 4,123

Rep: Reputation: 151Reputation: 151
If you do have files numbered as leonscape describes, you are probably running logrotate. In the files /etc/logrotate.conf and /etc/logrotate.d/* you can modify the rotate directive to use fewer backups. For example, if you see the line rotate 4 change it to rotate 1
 
  


Reply

Tags
deleting, log, var


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
/var/log/packages and /var/log/setup sunny_5252 Slackware 4 05-17-2007 08:17 PM
Deleted /var/log/messages, can't log any files-iptables chingyenccy Linux - Newbie 7 02-27-2005 04:03 PM
Strange results in /var/log/apache/access.log subt13 Linux - Security 2 08-03-2004 01:21 PM
pppd logging to /var/log/ppp.log problem mrtwice Linux - Software 1 01-10-2004 05:38 PM
iptables, changing log file from /var/log/messages acid2000 Linux - Networking 3 03-11-2003 08:38 PM


All times are GMT -5. The time now is 03:35 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration