Score:0

So my root file system is filled to the brim due to log files

cn flag

So I have fairly recently started using Ubuntu as my main OS and it has been quite smooth for the past 4 months but today I was intimated that the system is full and on checking the var/log/ seems to have used an enormous chunk from my hard drive and I really don't know what to do and need advice. Thanks in advance!

enter image description here

Shreyas Devesh avatar
cn flag
I have read a few other answers but they weren't really helpful.
francois P avatar
it flag
First think to think about, is to check why, if it is only due to "normal" logging, you have to adjust your logrotate & set it up to compress older logs. If it is due to a fault in some application, you have to fix that (I think it that seeing size of your log directory) & remove older logs.
cc flag
Ubuntu 12.04 is long out of service, who knows what security issues might be present, logging all sorts of bad things. You need to backup your files, and reinstall a more current release, 20.04, or 21.10.
Shreyas Devesh avatar
cn flag
Oh my bad it's 20.04 (typo)
heynnema avatar
ru flag
Find the logs that are eating up your space. You indicate syslog and syslog.1. Take a look at syslog and look for a repeating error. That's what you have to fix. Delete the syslog.1 file, and any of the compressed syslog files, if space is getting real critical.
Score:0
td flag

use stacer install it with sudo apt install stacer, next open stacer and folle the picures enter image description here

enter image description here

enter image description here

enter image description here enter image description here

click the blue button type in your password and your done.

Shreyas Devesh avatar
cn flag
Are you sure that nothing will happen if i delete those log files ?
Shreyas Devesh avatar
cn flag
And syslog and syslog1 are the primary space eater's
lnee avatar
td flag
only do logs if you like
heynnema avatar
ru flag
Don't do this until you've looked at what's in the logs.
francois P avatar
it flag
Do not remove logs until you fix the reason logs are so big ! /var/log may never increase over 8Gb even on small production servers, so having much log space, is of course a very big issue symptom. Cure the issue, not the symptom ! Only AFTER doing that you can purge/sort the useless logs
Shreyas Devesh avatar
cn flag
syslog consumed 500GiB and syslog.1 consumed 250GiB so i followed another thread to empty the log files then restarted their service
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.