Skip to content

[config] Add configurations for dynamically buffer calculation#5

Closed
stephenxs wants to merge 13 commits intomasterfrom
dynamically-buffer-calculation
Closed

[config] Add configurations for dynamically buffer calculation#5
stephenxs wants to merge 13 commits intomasterfrom
dynamically-buffer-calculation

Conversation

@stephenxs
Copy link
Owner

Signed-off-by: Stephen Sun stephens@mellanox.com

- What I did

- 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)

@stephenxs stephenxs marked this pull request as ready for review June 13, 2020 02:18
@stephenxs stephenxs force-pushed the dynamically-buffer-calculation branch from 7757195 to 3699112 Compare June 21, 2020 12:01
Stephen Sun added 11 commits June 26, 2020 11:51
Signed-off-by: Stephen Sun <stephens@mellanox.com>
Signed-off-by: Stephen Sun <stephens@mellanox.com>
Signed-off-by: Stephen Sun <stephens@mellanox.com>
Signed-off-by: Stephen Sun <stephens@mellanox.com>
Signed-off-by: Stephen Sun <stephens@mellanox.com>
Signed-off-by: Stephen Sun <stephens@mellanox.com>
Signed-off-by: Stephen Sun <stephens@mellanox.com>
1. Fix issue that db_migrator crashes if CABLE_LENGTH table doesn't exist
2. Don't treat BUFFER_PROFILE entries as default if their dynamic_th aren't 0.

Signed-off-by: Stephen Sun <stephens@mellanox.com>
including: BUFFER_POOL BUFFER_PROFILE

Signed-off-by: Stephen Sun <stephens@mellanox.com>
support copy buffer tables from config db to appl db in old mode

Signed-off-by: Stephen Sun <stephens@mellanox.com>
Signed-off-by: Stephen Sun <stephens@mellanox.com>
@stephenxs stephenxs force-pushed the dynamically-buffer-calculation branch from 773f36e to 5fb0ef3 Compare June 26, 2020 03:52
Stephen Sun and others added 2 commits June 29, 2020 18:26
Make the size cell-boundary-aligned

Signed-off-by: Stephen Sun <stephens@mellanox.com>
Signed-off-by: stephens <stephens@contoso.com>
@stephenxs
Copy link
Owner Author

Community PR opened

@stephenxs stephenxs closed this Jul 17, 2020
stephenxs pushed a commit that referenced this pull request Nov 21, 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
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant