-
Notifications
You must be signed in to change notification settings - Fork 672
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
[Reclaim buffer] [Mellanox] Db migrator support reclaiming reserved buffer for unused ports #1822
Conversation
Signed-off-by: Stephen Sun <stephens@nvidia.com>
- Set admin_status to up for all ports so that the reclaiming buffer migrator won't interfere it Signed-off-by: Stephen Sun <stephens@nvidia.com>
Signed-off-by: Stephen Sun <stephens@nvidia.com>
…eues Generate a zero buffer item for 0-2, 3-4, 5-6 separatedly. The previous approach can be problematic in case switching between lossless and lossy isn't supported on the platform Signed-off-by: Stephen Sun <stephens@nvidia.com>
- Add more comments - Adjust code Signed-off-by: Stephen Sun <stephens@nvidia.com>
This pull request introduces 1 alert when merging 499bbeb into 0d538d3 - view on LGTM.com new alerts:
|
By doing so, the buffer manager is able to remove it from APPL_DB in warm reboot Signed-off-by: stephens <stephens@contoso.com> Conflicts: scripts/mellanox_buffer_migrator.py
Signed-off-by: Stephen Sun <stephens@nvidia.com>
Signed-off-by: Stephen Sun <stephens@nvidia.com>
Signed-off-by: Stephen Sun <stephens@nvidia.com>
Signed-off-by: Stephen Sun <stephens@nvidia.com>
Signed-off-by: Stephen Sun <stephens@nvidia.com>
/azpw run |
/AzurePipelines run |
Azure Pipelines successfully started running 1 pipeline(s). |
Detailed changes scripts/mellanox_buffer_migrator.py: do the real work of reclaiming buffer
other files: test cases. |
Can you recheck the warm-boot case? Will there be issues when some objects present in older version are no longer present after warm-boot? |
Thanks for bringing this up. I don’t see a risk after reflecting it because only the profiles that are not be referenced will be removed. |
Signed-off-by: Stephen Sun <stephens@nvidia.com>
Signed-off-by: Stephen Sun <stephens@nvidia.com>
/azpw run |
/AzurePipelines run |
Azure Pipelines successfully started running 1 pipeline(s). |
Signed-off-by: Stephen Sun <stephens@nvidia.com>
tests/db_migrator_input/config_db/reclaiming-buffer-warmreboot-input.json
Show resolved
Hide resolved
tests/db_migrator_input/config_db/reclaiming-buffer-traditional-single-pool-expected.json
Show resolved
Hide resolved
tests/db_migrator_input/config_db/reclaiming-buffer-traditional-single-pool-expected.json
Show resolved
Hide resolved
…uffer for unused ports (#1822) Signed-off-by: Stephen Sun stephens@nvidia.com What I did Db migrator support reclaiming reserved buffer for unused ports How I did it For admin down ports, if the buffer objects configuration aligns with default configuration, set the buffer objects configuration as: Dynamic model: all normal buffer objects are configured on admin down ports. Buffer manager will apply zero profiles on admin down ports. Static model: zero buffer objects are configured on admin down ports. How to verify it Unit test. Manually test.
…1898) This is to cherry-pick community PR #1822 to 202012. - What I did Db migrator support reclaiming reserved buffer for unused ports As there is no empty slot for database version between 202012 and master (202111), this migration will be done regardless of whether database version is changed. The DB migrator should be idempotent. - How I did it For admin down ports, if the buffer objects configuration aligns with default configuration, set the buffer objects configuration as: 1. Dynamic model: all normal buffer objects are configured on admin down ports. Buffer manager will apply zero profiles on admin down ports. 2. Static model: zero buffer objects are configured on admin down ports. - How to verify it Unit test and manually Signed-off-by: Stephen Sun <stephens@nvidia.com>
…1897) This is to cherry-pick community PR #1822 to 202106. - What I did Db migrator support reclaiming reserved buffer for unused ports As there is no empty slot for database version between 202106 and master (202111), this migration will be done regardless of whether database version is changed. The DB migrator should be idempotent. - How I did it For admin down ports, if the buffer objects configuration aligns with default configuration, set the buffer objects configuration as: 1. Dynamic model: all normal buffer objects are configured on admin down ports. Buffer manager will apply zero profiles on admin down ports. 2. Static model: zero buffer objects are configured on admin down ports. - How to verify it 1. Unit test. 2. Manually test.
What I did
Db migrator support reclaiming reserved buffer for unused ports
Signed-off-by: Stephen Sun stephens@nvidia.com
How I did it
For admin down ports, if the buffer objects configuration aligns with default configuration, set the buffer objects configuration as:
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)