Page MenuHomeVyOS Platform

'delete log file' does not work
Closed, ResolvedPublic


the command "delete log file" only works when any file is present in /var/log/user and mostly no files are written in this directory

vyos@R3:~$ delete log file messages
File does not exist


Difficulty level
Unknown (require assessment)
VyOS 1.2.7 1.4-rolling-202105192127
Why the issue appeared?
Will be filled on close
Is it a breaking change?
Unspecified (possibly destroys the router)

Event Timeline

When the following command "set system syslog file <filename> facility <keyword> level <keyword>" is applied, then the files are stored in the /var/log/user directory. These files can be deleted using the command "delete log file <text>"

Updated the documentation:

vyos@R3# run sh conf comm |grep syslog
set system syslog file test facility auth level 'all'

vyos@R3# ls -ltr /var/log/user
total 4
-rw-r----- 1 root adm 561 May 30 08:50 test

vyos@R3:~$ delete log file test
vyos@R3:~$ ls -ltr /var/log/user/
total 0

The file will be recreated once new events are generated.

Maybe a completion helper could work here, too?

thank you for the suggestion, I will work on this.

SrividyaA triaged this task as Low priority.