Forum Discussion
JotaCePena_1783
Nimbostratus
Mar 08, 2017Disk partition /var/log has only 4% free
Hi all, I have this error msg in f5 console and in ltm log.
This is result of df -h command:
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/vg--db--sda-dat.log.1 6.9...
Mar 09, 2017
This is how to get some more info on what files are eating up your harddrive. The
du -x . | sort -n
command forces the du
(disk usage) command to limit itself to the /var/log partition. The sort
command will sort the output of du to display from smallest to largest files. In the example below you can see that the directory /var/log itself usages the most disk space.
[root@nielsvs-bigip:Active:Standalone] ~ cd /var/log
[root@nielsvs-bigip:Active:Standalone] log du -x . | sort -n
2 ./ConsoleKit
2 ./fpuserd
...
...
...
1006 ./restnoded
1644 ./avr
2005 ./datasync
12600 ./ts
14520 ./sa6
27363 ./auditd
109245 .
[root@nielsvs-bigip:Active:Standalone] log ls -lh auditd
total 27M
-rw-------. 1 root root 2.7M 2017-03-09 15:22 audit.log
-r--------. 1 root root 6.1M 2017-03-08 16:05 audit.log.1
-r--------. 1 root root 6.1M 2017-03-06 10:20 audit.log.2
-r--------. 1 root root 6.1M 2017-03-04 04:30 audit.log.3
-r--------. 1 root root 6.1M 2017-03-01 22:32 audit.log.4
[root@nielsvs-bigip:Active:Standalone] log
You can also sort on the largest files in de /var/log directory itself.
[root@nielsvs-bigip:Active:Standalone] log ls -Slh | head -10
total 46M
-rw-------. 1 root root 21M 2017-03-09 15:16 ltm
-rw-r--r--. 1 root root 7.6M 2017-02-28 21:35 restjavad-audit.0.log
-rw-------. 1 root root 7.1M 2017-03-09 03:06 ltm.1
-rw-r--r--. 1 root root 1.1M 2017-01-01 10:34 restjavad-gc.log.0
-rw-r--r--. 1 root root 978K 2017-02-28 21:32 restjavad.1.log
-rw-r--r--. 1 root root 732K 2017-02-24 11:19 debug.log
-rw-------. 1 root root 539K 2017-03-02 03:29 ltm.9.gz
-rw-rw-r--. 1 root tomcat 448K 2017-03-06 14:08 webui.log
-rw-------. 1 root root 432K 2017-03-09 03:02 icrd.1
[root@nielsvs-bigip:Active:Standalone] log
Maybe you can remove some old logfiles or make sure you turn off some debugging to log less.
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects