Update the example for pfcwd start command #1984
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
… it says invalid options. Update it with a correct command
Signed-off-by: Zhaohui Sun [email protected]
What I did
The example of pfcwd start command in start function comments is a little confused, after execution, it says invalid options.
Update it with a correct command.
The output of the current example is:
admin@vlab-01:~$ sudo pfcwd start --action drop ports all detection-time 400 --restoration-time 400
Failed to run command, invalid options:
ports
detection-time
How I did it
Update the example with a correct one in pfcwd start function comments which is also usage info for pfcwd start command.
How to verify it
Enter SONiC DUT, input the following command:
sudo pfcwd start --help
sudo pfcwd start --action drop all 400 --restoration-time 400
Previous command output (if the output of a command-line utility has changed)
admin@vlab-01:~$ sudo pfcwd start --help
Usage: pfcwd start [OPTIONS] [PORTS]... DETECTION_TIME
Start PFC watchdog on port(s). To config all ports, use all as input.
Example:
sudo pfcwd start --action drop ports all detection-time 400 --restoration-
time 400
Options:
-a, --action [drop|forward|alert]
-r, --restoration-time INTEGER RANGE
--help Show this message and exit.
New command output (if the output of a command-line utility has changed)
admin@vlab-01:~$ sudo pfcwd start --help
Usage: pfcwd start [OPTIONS] [PORTS]... DETECTION_TIME
Start PFC watchdog on port(s). To config all ports, use all as input.
Example:
start --action drop all 400 --restoration-time 400
Options:
-a, --action [drop|forward|alert]
-r, --restoration-time INTEGER RANGE
--help Show this message and exit.