2020-03-31 12:06:19 -05:00
|
|
|
[Unit]
|
|
|
|
Description=TEAMD container
|
|
|
|
After=swss{% if multi_instance == 'true' %}@%i{% endif %}.service
|
[multi_asic][vs]: Add dependency in teamd service to start after topology service(#6594)
[multi_asic][vs]: Add dependency in teamd service to start after topology service.
- Why I did it
In multi-asic VS, topology service is run after database service to set up the internal asic topology.
swss and syncd have a dependency to start after topology service is run so that the interfaces are moved to right namespace and created in the right namespace. In case of multi-asic vs, during the initial boot up, when there is no configuration added, teamd service starts and swss/syncd do not start as topology service does not start. Upon loading configuration using config_db or minigraph, swss and sycnd start up , but teamd is not restarted as swss is not stopped and started. This causes teamd to be in a bad state and requires a reload of config.
- How I did it
Add dependency in teamd service to start after topology service is completed.
- How to verify it
No change in single asic vs or platform.
No change in multi-asic regular image.
Change only in multi-asic VS. Bring up a multi-asic VS image without any configration, teamd service will fail to start due to dependency failure. Load minigraph, start topology service, load configuration, ensure all services come up.
Signed-off-by: SuvarnaMeenakshi <sumeenak@microsoft.com>
2021-02-04 16:10:56 -06:00
|
|
|
{% if multi_instance == 'true' and sonic_asic_platform == 'vs' %}
|
|
|
|
Requires=topology.service
|
|
|
|
After=topology.service
|
|
|
|
{% endif %}
|
2020-03-31 12:06:19 -05:00
|
|
|
Requires=updategraph.service
|
|
|
|
After=updategraph.service
|
2021-02-25 06:26:24 -06:00
|
|
|
BindsTo=sonic.target
|
|
|
|
After=sonic.target
|
2020-03-31 12:06:19 -05:00
|
|
|
Before=ntp-config.service
|
|
|
|
StartLimitIntervalSec=1200
|
|
|
|
StartLimitBurst=3
|
|
|
|
|
|
|
|
[Service]
|
|
|
|
User={{ sonicadmin_user }}
|
2020-11-13 15:34:18 -06:00
|
|
|
ExecStartPre=/usr/local/bin/{{docker_container_name}}.sh start{% if multi_instance == 'true' %} %i{% endif %}
|
|
|
|
ExecStart=/usr/local/bin/{{docker_container_name}}.sh wait{% if multi_instance == 'true' %} %i{% endif %}
|
|
|
|
ExecStop=/usr/local/bin/{{docker_container_name}}.sh stop{% if multi_instance == 'true' %} %i{% endif %}
|
2020-03-31 12:06:19 -05:00
|
|
|
RestartSec=30
|
|
|
|
|
|
|
|
[Install]
|
2021-02-25 06:26:24 -06:00
|
|
|
WantedBy=sonic.target
|