Forum Discussion
LTM log file
Suppose I copy the ltm file, Is it safe to delete the LTM log file? Will F5 create a new one?
- nitassEmployee
it was not created in my gear after i deleted it until it got rotated (by logrotate). so, if you want to purge the log, i think it may be better to empty log.
e.g.
[root@ve11a:Active:In Sync] config ls -l /var/log/ltm -rw------- 1 root root 1555 Feb 10 19:58 /var/log/ltm [root@ve11a:Active:In Sync] config cat > /var/log/ltm [root@ve11a:Active:In Sync] config [root@ve11a:Active:In Sync] config ls -l /var/log/ltm -rw------- 1 root root 0 Feb 10 20:01 /var/log/ltm
- ERLomboy_27803Nimbostratus
Thanks! how do you force logrotate?
- ERLomboy_27803NimbostratusPlease advise why is the ltm file keeps growing even after I removed the iRule from the Virtual Server and put a comment on the log?
- Vitaliy_SavransNacreousto force logrotate: logrotate -f /etc/logrotate.conf :)
- ERLomboy_27803NimbostratusHi Vitaly - the logrotate will stop the log from growing?
- nitassEmployee
e.g.
[root@ve11a:Active:In Sync] config ls -l /var/log/ltm ls: /var/log/ltm: No such file or directory [root@ve11a:Active:In Sync] config logrotate -f /etc/logrotate.conf [root@ve11a:Active:In Sync] config [root@ve11a:Active:In Sync] config ls -l /var/log/ltm -rw------- 1 root root 0 Feb 10 20:19 /var/log/ltm
- Vitaliy_SavransNacreous
Hi, logrotate is used to archived files. You can manage your logs files by this utility. If you need you may execute it as you need by crontab or manualy. Configuation stores in /etc/logrotate.conf (be aware that on f5 devices you need to manage it through tmsh cli) :
compress missingok notifempty weekly create rotate 10 size 100M
means that logs will be rotated and archived (commpress)after one week of previous rotation. If log file will be more than 100M, it will be rotated of execution of logrotate. Files of logs will be 10. If you need help in this don't hesitate to ask, I will help with pleasure.
Recent Discussions
Related Content
* 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