Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Command Ref] Add doc for syslog rate limit #2508

Merged
merged 3 commits into from
Dec 20, 2022
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
92 changes: 89 additions & 3 deletions doc/Command-Reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -3356,7 +3356,7 @@ This command displays basic information about the gearbox phys configured on the
PHY Id Name Firmware
-------- ------- ----------
1 sesto-1 v0.1

```

Go Back To [Beginning of the document](#) or [Beginning of this section](#gearbox)
Expand Down Expand Up @@ -8701,7 +8701,7 @@ Go Back To [Beginning of the document](#) or [Beginning of this section](#subint

### Syslog Show Commands

This subsection explains how to display configured syslog servers.
This subsection explains how to display syslog related configuration.

**show syslog**

Expand All @@ -8720,9 +8720,58 @@ This command displays configured syslog servers.
2.2.2.2 1.1.1.1 514 default
```

**show syslog rate-limit-host**

This command displays rate limit configuration for host.

- Usage
```
show syslog rate-limit-host
```

- Example:
```
admin@sonic:~$ show syslog rate-limit-host
INTERVAL BURST
---------- --------
500 50000
```

**show syslog rate-limit-container**

This command displays rate limit configuration for containers.

- Usage
```
show syslog rate-limit-container [<service_name>]
```

- Example:
```
admin@sonic:~$ show syslog rate-limit-container
SERVICE INTERVAL BURST
-------------- ---------- -------
bgp 0 0
database 300 20000
lldp 300 20000
mgmt-framework 300 20000
pmon 300 20000
radv 300 20000
snmp 300 20000
swss 300 20000
syncd 300 20000
teamd 300 20000
telemetry 300 20000

admin@sonic:~$ show syslog rate-limit-container bgp
SERVICE INTERVAL BURST
-------------- ---------- -------
bgp 0 0
```

### Syslog Config Commands

This subsection explains how to configure syslog servers.
This subsection explains how to configure syslog.

**config syslog add**

Expand Down Expand Up @@ -8766,6 +8815,43 @@ This command is used to delete the configured syslog server.
Running command: systemctl restart rsyslog-config
```

**config syslog rate-limit-host**

This command is used to configure syslog rate limit for host.

- Usage:
```
config syslog rate-limit-host
```

- Parameters:
- _interval_: determines the amount of time that is being measured for rate limiting.
- _burst_: defines the amount of messages, that have to occur in the time limit of interval, to trigger rate limiting

- Example:
```
admin@sonic:~$ sudo config syslog rate-limit-host --interval 300 --burst 20000
```

**config syslog rate-limit-container**

This command is used to configure syslog rate limit for containers.

- Usage:
```
config syslog rate-limit-container
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i think we are missing the container name

```

- Parameters:
- _interval_: determines the amount of time that is being measured for rate limiting.
- _burst_: defines the amount of messages, that have to occur in the time limit of interval, to trigger rate limiting

- Example:
```
admin@sonic:~$ sudo config syslog rate-limit-container bgp --interval 300 --burst 20000
```
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if there is a default value, suggest to add as well
if there is range supported, suggest to add as well

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is no default value, either interval or burst must be present. There is no range supported, as we did not find range from rsyslog document.



Go Back To [Beginning of the document](#) or [Beginning of this section](#syslog)

## System State
Expand Down