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

Use redis for VID generator and move RID translation to syncd #2

Closed
wants to merge 1 commit into from

Conversation

kcudnik
Copy link
Collaborator

@kcudnik kcudnik commented Mar 29, 2016

No description provided.

@kcudnik kcudnik closed this Apr 1, 2016
@kcudnik kcudnik deleted the counter branch April 1, 2016 00:16
@lguohan
Copy link
Contributor

lguohan commented Apr 1, 2016

why closed?

2016-03-31 17:16 GMT-07:00 Kamil Cudnik notifications@github.com:

Closed #2 #2.


You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub
#2 (comment)

lguohan pushed a commit that referenced this pull request Feb 21, 2018
Signed-off-by: Volodymyr Samotiy <volodymyrs@mellanox.com>
andrii-savka pushed a commit to andrii-savka/sonic-sairedis that referenced this pull request Feb 22, 2018
…-net#2)

Signed-off-by: Volodymyr Samotiy <volodymyrs@mellanox.com>
andrii-savka pushed a commit to andrii-savka/sonic-sairedis that referenced this pull request Feb 22, 2018
…-net#2)

Signed-off-by: Volodymyr Samotiy <volodymyrs@mellanox.com>
dgsudharsan referenced this pull request in dgsudharsan/sonic-sairedis Jul 15, 2021
pettershao-ragilenetworks pushed a commit to pettershao-ragilenetworks/sonic-sairedis that referenced this pull request Nov 18, 2022
…-net#2)

Signed-off-by: Volodymyr Samotiy <volodymyrs@mellanox.com>
JunhongMao referenced this pull request in JunhongMao/sonic-sairedis Sep 1, 2023
•	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/"

  sonic-net#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

  sonic-net#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"

  sonic-net#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
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.

2 participants