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

[Dynamic buffer calc] Support dynamic buffer calculation #4881

Merged

Commits on Dec 6, 2020

  1. [Dynamic buffer calculation] Support dynamic buffer calculation

    1. add tables required for the feature:
     - ASIC_TABLE in platform/mellanox/asic_table.j2 (Mellanox specific)
     - PERIPHERAL_TABLE in platform/mellanox/peripheral_table.j2 (Mellanox specific)
     - PORT_PERIPHERAL_TABLE on a per-platform basis in device/mellanox/x86_64-mlnx_msn3800-r0/port_peripheral_config.j2 (Mellanox specific)
     - DEFAULT_LOSSLESS_BUFFER_PARAMETER and LOSSLESS_TRAFFIC_PATTERN in files/build_templates/buffers_config.j2
     - Add lossless PGs (3-4) for each port in files/build_templates/buffers_config.j2
    2. copy the newly introduced j2 files into image and rendering them when system starts
    3. update the CLI options for buffermgrd so that it can start with dynamic mode
    4. Adjust the order in which swss daemons start, making buffermgrd start before orchagent.
       This is to make sure buffermgrd can get everything ready before orchagent starts especially during warm reboot.
    5. Optimize the way in which orchagent fetches the asic vendor name:
     - fetch the vendor name when creates the docker and pass it as a docker environment variable
     - orchagent and buffermgrd can use this passed-in variable
    6. Clear buffer related tables from STATE_DB when swss docker starts
    7. Update the src/sonic-config-engine/tests/sample_output/buffers-dell6100.json according to the buffer_config.j2
    8. Remove buffer pool sizes for ingress pools and egress_lossy_pool
       Update the buffer settings for dynamic buffer calculation
    
    Signed-off-by: Stephen Sun <stephens@nvidia.com>
    stephenxs committed Dec 6, 2020
    Configuration menu
    Copy the full SHA
    c9a6731 View commit details
    Browse the repository at this point in the history
  2. Update the upgrading behavior according to the discussion with MSFT

    1. If all the buffer configuration aligns the default, use dynamic
    buffer calculation mode. Otherwise, use the traditional mode
    2. Dynamic mode is adopted in switches newly installed from scratch and
    traditional mode in switches installed from ninigraph
    This is done by:
    - introducing a wrapper to buffermgrd, which enables it to test which
    mode is adopted and feed buffermgrd with corresponding CLI arguments
    - preparing default buffer configuration templates for both dynamic and
    traditional mode for each SKU
    - introduce "buffer_model" in DEVICE_METADATA|localhost for mellanox platform
    
    Signed-off-by: Stephen Sun <stephens@nvidia.com>
    stephenxs committed Dec 6, 2020
    Configuration menu
    Copy the full SHA
    66fe33a View commit details
    Browse the repository at this point in the history
  3. Fix vs image building issues

    Signed-off-by: Stephen Sun <stephens@nvidia.com>
    stephenxs committed Dec 6, 2020
    Configuration menu
    Copy the full SHA
    2e7a61c View commit details
    Browse the repository at this point in the history
  4. Always initialize buffer_model

    - For Mellanox, dynamic by default
    - For other vendors, traditional mode.
    
    Signed-off-by: Stephen Sun <stephens@nvidia.com>
    stephenxs committed Dec 6, 2020
    Configuration menu
    Copy the full SHA
    ab20f9c View commit details
    Browse the repository at this point in the history
  5. Fix error in docker-orchagent/supervisor.conf

    Signed-off-by: Stephen Sun <stephens@nvidia.com>
    stephenxs committed Dec 6, 2020
    Configuration menu
    Copy the full SHA
    1aab411 View commit details
    Browse the repository at this point in the history
  6. Correct the peer MTU which should be 1k in LOSSLESS_TRAFFIC_PATTERN t…

    …able
    
    Signed-off-by: Stephen Sun <stephens@nvidia.com>
    stephenxs committed Dec 6, 2020
    Configuration menu
    Copy the full SHA
    7e6bc5d View commit details
    Browse the repository at this point in the history

Commits on Dec 8, 2020

  1. buffermgrd: provide the peripheral_table.json only if it exists

    Signed-off-by: Stephen Sun <stephens@nvidia.com>
    stephenxs committed Dec 8, 2020
    Configuration menu
    Copy the full SHA
    f09e695 View commit details
    Browse the repository at this point in the history