Ubuntu Log files

Discussion in 'all things UNIX' started by cet, May 7, 2010.

Thread Status:
Not open for further replies.
  1. cet

    cet Registered Member

    Joined:
    Sep 3, 2006
    Posts:
    876
    Location:
    Turkey/İzmir
    I have seen some posts on Internet about the growing size of logs and how to delete them.Some logs grow so much that some people get low disk space warning.
    My question is:May I restrict the size of the logs,or do I have to clean logs from time to time(how to do safely).
     
  2. dan_maran

    dan_maran Registered Member

    Joined:
    Aug 30, 2004
    Posts:
    1,053
    Location:
    98031
    Unless you are extremely low on hard disk space then you are fine, assuming you let the installation set your partitions. If not how big did you set your /var partition?

    You can check your sizes by:
    cd /var/log
    sudo du -a -h

    your total will be at the bottom. Mine is a lowly 12MB :)
     
  3. linuxforall

    linuxforall Registered Member

    Joined:
    Feb 6, 2010
    Posts:
    2,137
    You can also install Bleachbit from the repository to delete log files and other stuff from time to time.
     
  4. chronomatic

    chronomatic Registered Member

    Joined:
    Apr 9, 2009
    Posts:
    1,343
    Ubuntu automatically installs logrotate which automatically rotates the logs. If you go into /var/log and see a bunch of *.tar.gz files, those are files that logrotate has "rotated" and then compressed for storage. If you have extra log files you have created you will manually need to write a logrotate script for them (it's easy). If you have not created your own logs, you are good to go. Nothing needs to be done.

    For more info you can read the manual:

    Code:
    man logrotate
     
  5. mack_guy911

    mack_guy911 Registered Member

    Joined:
    Mar 21, 2007
    Posts:
    2,677

    i also use bleach bit once in a week or 10 days on fedora/mint/ubuntu it remove lots of temp logs.......firefox opera pidgin ...........junks etc free my space some more than 200 MB :D
     
  6. cet

    cet Registered Member

    Joined:
    Sep 3, 2006
    Posts:
    876
    Location:
    Turkey/İzmir
    I have 14MB


    I am installing BleachBit now.Thank you.

    Which entries are dangerous to choose,or should I choose all of them?
     
    Last edited: May 7, 2010
  7. Judge Dee

    Judge Dee Guest

    Under the web browser section, checking "passwords" will delete all passwords, "places" deletes bookmarks, "session restore' deletes ability to restore session after a crash.
    As far as the rest, I don't know. I use them with no ill effects, but I'm still a relative newbie.
     
Thread Status:
Not open for further replies.
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.