Rotates a log file. (version 4.78 or later)
logrotate 'size' '<size>'
logrotate 'rotate' <count>
- 'size' <size>
- When a log file size is over <size> byte, the log file is be rotated.
The <size> value must be larger than 128.
If the <size> is followed by K, the size is assumed to be in kilobytes.
If the M is used, the size is in megabytes.
- 'rotate' <count>
- Log files are rotated <count> times before being removed.
The <count> value must be larger than 1.
- The log rotation is stopped.
- A log file must be opened previously.
- This command only configure the log rotation. So, the rotation does not be executed immediately.
; Open log
getspecialfolder str "MyDocuments"
logopen 'teraterm_sample.log' 0 0
; Start log rotation
logrotate 'size' '32K'
logrotate 'rotate' 3
; Stop log rotation
; Close log