I want to delete var/log files due to low disk space, but I cannot find out how.
Asked
Active
Viewed 1.1k times
2 Answers
2
As mentioned, you can delete a specific log file with sudo rm /var/log/<FILENAME> or all of them with sudo rm /var/log/*.
I also found this:
du -h /var/log/ 2>/dev/null > ~/fileinfo to list the size and path of every log file. To view the result you can use cat ~/fileinfo
Jeremi G
- 121