forked from sonic-net/sonic-utilities
-
Notifications
You must be signed in to change notification settings - Fork 0
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
Pbh cli #2
Closed
Closed
Pbh cli #2
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Prevent potential kernel oops if drivers are removed/devices are deinitialized while PMon daemons are still trying to access those devices.
+ update 'show ip interface' command in tech support collection + fix unbound variable issue in case command times out
…as loopback. (sonic-net#1565) 2) The vrf routes are *not* handled.
…c-net#1505) + added tests for 'show queue counters' CLI
Dropped IP validation as server takes URL.
sonic-net#1519) Signed-off-by: Danny Allen <[email protected]>
What I did Added platform pre check support in reboot script. Checking platform based changes before stopping dockers and sonic services. Porting changes in master from 201911 branch sonic-net#1472 How I did it On branch reboot_pre_check_master Changes not staged for commit: (use "git add ..." to update what will be committed) (use "git checkout -- ..." to discard changes in working directory) modified: scripts/reboot How to verify it Write a platform pre check script(platform_reboot_pre_check) and place it in /usr/share/sonic/device// directory. If the script exit with status 0, reboot will be proceeded. If script exit with non-zero status, the reboot script gets stopped.
What I did Radius Management User Authentication Feature How I did it HLD: https://github.com/Azure/SONiC/blob/master/doc/aaa/radius_authentication.md How to verify it This is the CLI only. The changes are reflected in the Redis Config DB. Previous command output (if the output of a command-line utility has changed) New command output (if the output of a command-line utility has changed) admin@sonic:~$ show radius RADIUS global auth_type pap (default) RADIUS global retransmit 3 (default) RADIUS global timeout 5 (default) RADIUS global passkey <EMPTY_STRING> (default) admin@sonic:~$ admin@sonic:~$ sudo config radius Usage: config radius [OPTIONS] COMMAND [ARGS]... RADIUS server configuration Options: -?, -h, --help Show this message and exit. Commands: add Specify a RADIUS server authtype Specify RADIUS server global auth_type [chap | pap | mschapv2] default set its default configuration delete Delete a RADIUS server nasip Specify RADIUS server global NAS-IP|IPV6-Address passkey Specify RADIUS server global passkey retransmit Specify RADIUS server global retry attempts <0 - 10> sourceip Specify RADIUS server global source ip statistics Specify RADIUS server global statistics [enable | disable |... timeout Specify RADIUS server global timeout <1 - 60> admin@sonic:~$
* [console] Display success message after line cleared Signed-off-by: Jing Kan [email protected]
…mmands (sonic-net#1536) #### What I did Adding apply-patch, rollback, replace, checkpoint, delete-checkpoint, list-checkpoints functionality. #### How I did it This PR is implementing the first step in in README.md in the design document: sonic-net/SONiC#736 #### How to verify it Using unit-tests #### Previous command output (if the output of a command-line utility has changed) #### New command output (if the output of a command-line utility has changed) ```sh admin@sonic:~$ sudo config apply-patch --help Usage: config apply-patch [OPTIONS] PATCH_FILE_PATH Apply given patch of updates to Config. A patch is a JsonPatch which follows rfc6902. This command can be used do partial updates to the config with minimum disruption to running processes. It allows addition as well as deletion of configs. The patch file represents a diff of ConfigDb(ABNF) format or SonicYang format. <patch-file-path>: Path to the patch file on the file-system. Options: -f, --format [CONFIGDB|SONICYANG] format of config of the patch is either ConfigDb(ABNF) or SonicYang -d, --dry-run test out the command without affecting config state -v, --verbose print additional details of what the operation is doing -h, -?, --help Show this message and exit. admin@sonic:~$ sudo config replace --help Usage: config replace [OPTIONS] TARGET_FILE_PATH Replace the whole config with the specified config. The config is replaced with minimum disruption e.g. if ACL config is different between current and target config only ACL config is updated, and other config/services such as DHCP will not be affected. **WARNING** The target config file should be the whole config, not just the part intended to be updated. <target-file-path>: Path to the target file on the file-system. Options: -f, --format [CONFIGDB|SONICYANG] format of target config is either ConfigDb(ABNF) or SonicYang -d, --dry-run test out the command without affecting config state -v, --verbose print additional details of what the operation is doing -h, -?, --help Show this message and exit. admin@sonic:~$ sudo config rollback --help Usage: config rollback [OPTIONS] CHECKPOINT_NAME Rollback the whole config to the specified checkpoint. The config is rolled back with minimum disruption e.g. if ACL config is different between current and checkpoint config only ACL config is updated, and other config/services such as DHCP will not be affected. <checkpoint-name>: The checkpoint name, use `config list-checkpoints` command to see available checkpoints. Options: -d, --dry-run test out the command without affecting config state -v, --verbose print additional details of what the operation is doing -?, -h, --help Show this message and exit. admin@sonic:~$ sudo config checkpoint --help Usage: config checkpoint [OPTIONS] CHECKPOINT_NAME Take a checkpoint of the whole current config with the specified checkpoint name. <checkpoint-name>: The checkpoint name, use `config list-checkpoints` command to see available checkpoints. Options: -v, --verbose print additional details of what the operation is doing -h, -?, --help Show this message and exit. admin@sonic:~$ sudo config delete-checkpoint --help Usage: config delete-checkpoint [OPTIONS] CHECKPOINT_NAME Delete a checkpoint with the specified checkpoint name. <checkpoint-name>: The checkpoint name, use `config list-checkpoints` command to see available checkpoints. Options: -v, --verbose print additional details of what the operation is doing -h, -?, --help Show this message and exit. admin@sonic:~$ sudo config list-checkpoints --help Usage: config list-checkpoints [OPTIONS] List the config checkpoints available. Options: -v, --verbose print additional details of what the operation is doing -?, -h, --help Show this message and exit. ```
*Added checking of static routes, related to the interface, before deleting of the last IP entry to prevent deleting the RIF if a static route is present in the system. Signed-off-by: Maksym Belei <[email protected]>
What I did There is a bug that occasionally turn root-overlay as RO. This makes /etc & /home as RO. This blocks any new remote user login, as that needs to write into /etc & /home. This tool scans /etc & /home (or given dirs) as in RW or RO state. If RO, it could create a writable overlay using tmpfs. This is transient and stays until next reboot. Any write after the overlay will be lost upon reboot. But this allows new remote users login. How I did it Create upper & work dirs in /run/mount (tmpfs). Mount /etc & /home as lowerdirs and use the same name for final merge. This allows anyone opening a file in /etc or /home to operate on the merged overlay, transparently. How to verify it Mount any dir on tmpfs ( mount -t tmpfs tmpfs test_dir) remount as RO (mount -o remount,ro test_dir) Pass that dir to this script. (disk_check.py -d ./test_dir) Now it should be RW
…net#1574) This change is to add support for the commands "show ip bgp neighbor "and "show ip bgp network" for multi asic platforms Add unit tests for these commands Signed-off-by: Arvindsrinivasan Lakshmi Narasimhan <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
…tions Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
…flow Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
Signed-off-by: Vadym Hlushko <[email protected]>
vadymhlushko-mlnx
pushed a commit
that referenced
this pull request
Nov 27, 2023
…aidump_by_route_size (sonic-net#2972) * * [saidump] • Saidump for DNX-SAI sonic-net/sonic-buildimage#13561 Solution and modification: To use the redis-db SAVE option to save the snapshot of DB each time and recover later, instead of looping through each entry in the table and saving it. (1) Updated sonic-buildimage/build_debian.sh, to install Python library rdbtools into the host. (2) Updated sonic-buildimage/src/sonic-sairedis/saidump/saidump.cpp, add a new option -r, which updates the rdbtools's output-JSON files' format. (3) Add a new script file: files/scripts/saidump.sh, to do the below steps For each ASIC0, such as ASIC0, #1. Save the Redis data. sudo sonic-db-cli -n asic$1 SAVE > /dev/null #2. Move dump files to /var/run/redisX/ docker exec database$1 sh -c "mv /var/lib/redis/dump.rdb /var/run/redis$1/" #3. Run rdb command to convert the dump files into JSON files sudo python /usr/local/bin/rdb --command json /var/run/redis$1/dump.rdb | sudo tee /var/run/redis$1/dump.json > /dev/null #4. Run saidump -r to update the JSON files' format as same as the saidump before. Then we can get the saidump result in standard output. docker exec syncd$1 sh -c "saidump -r /var/run/redis$1/dump.json" #5. clear sudo rm -f /var/run/redis$1/dump.rdb sudo rm -f /var/run/redis$1/dump.json (4) Update sonic-buildimage/src/sonic-utilities/scripts/generate_dump, replace saidump with saidump.sh * * [saidump] • Saidump for DNX-SAI sonic-net/sonic-buildimage#13561
vadymhlushko-mlnx
pushed a commit
that referenced
this pull request
Jan 23, 2024
…aidump_by_route_size (sonic-net#2972) * * [saidump] • Saidump for DNX-SAI sonic-net/sonic-buildimage#13561 Solution and modification: To use the redis-db SAVE option to save the snapshot of DB each time and recover later, instead of looping through each entry in the table and saving it. (1) Updated sonic-buildimage/build_debian.sh, to install Python library rdbtools into the host. (2) Updated sonic-buildimage/src/sonic-sairedis/saidump/saidump.cpp, add a new option -r, which updates the rdbtools's output-JSON files' format. (3) Add a new script file: files/scripts/saidump.sh, to do the below steps For each ASIC0, such as ASIC0, #1. Save the Redis data. sudo sonic-db-cli -n asic$1 SAVE > /dev/null #2. Move dump files to /var/run/redisX/ docker exec database$1 sh -c "mv /var/lib/redis/dump.rdb /var/run/redis$1/" #3. Run rdb command to convert the dump files into JSON files sudo python /usr/local/bin/rdb --command json /var/run/redis$1/dump.rdb | sudo tee /var/run/redis$1/dump.json > /dev/null #4. Run saidump -r to update the JSON files' format as same as the saidump before. Then we can get the saidump result in standard output. docker exec syncd$1 sh -c "saidump -r /var/run/redis$1/dump.json" #5. clear sudo rm -f /var/run/redis$1/dump.rdb sudo rm -f /var/run/redis$1/dump.json (4) Update sonic-buildimage/src/sonic-utilities/scripts/generate_dump, replace saidump with saidump.sh * * [saidump] • Saidump for DNX-SAI sonic-net/sonic-buildimage#13561
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
What I did
The Policy-Based Hashing CLI
How I did it
How to verify it
Previous command output (if the output of a command-line utility has changed)
New command output (if the output of a command-line utility has changed)