Skip to content

Commit

Permalink
Move frr logs from syslog to /var/log/frr/*.log (#5988)
Browse files Browse the repository at this point in the history
- Why I did it
Move frr logs from syslog from the directory /var/log/quagga/.log to /var/log/frr/log

- How I did it
Updated the rsyslog config files.

- How to verify it
Verified the logs come into the file zebra.log and bgpd.log in the DIR /var/log/frr/log
  • Loading branch information
judyjoseph authored and abdosi committed Dec 22, 2020
1 parent 547ec0a commit 1e4f09c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 9 deletions.
4 changes: 2 additions & 2 deletions files/image_config/logrotate/logrotate.d/rsyslog
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@
/var/log/syslog
/var/log/teamd.log
/var/log/telemetry.log
/var/log/quagga/bgpd.log
/var/log/quagga/zebra.log
/var/log/frr/bgpd.log
/var/log/frr/zebra.log
/var/log/swss/sairedis.rec
/var/log/swss/swss.rec
{
Expand Down
11 changes: 4 additions & 7 deletions files/image_config/rsyslog/rsyslog.d/00-sonic.conf
Original file line number Diff line number Diff line change
@@ -1,15 +1,12 @@
## Quagga rules

if $programname == ["bgp#quagga",
"bgp#watchquagga",
"bgp#zebra"]
then {
/var/log/quagga/zebra.log
if re_match($programname, "bgp[0-9]*#(frr|zebra|staticd|watchfrr)") then {
/var/log/frr/zebra.log
stop
}

if $programname == "bgp#bgpd" then {
/var/log/quagga/bgpd.log
if re_match($programname, "bgp[0-9]*#bgpd") then {
/var/log/frr/bgpd.log
stop
}

Expand Down

0 comments on commit 1e4f09c

Please sign in to comment.