d3f3ac6411
Why I did it All these 3 services started after swss service, which used to start after interface-config service. But #13084 remove the time constraints for swss. After that, these 3 services has the chance of start earlier when the inteface-config service is restarting the networking service, which could cause db connect request to fail. How I did it Delay mux/sflow/snmp timer after the interface-config service. How to verify it PR test. Config reload can repro the issue in 1-3 retries. With this change. config reload run 30+ iterations without hitting the issue. Signed-off-by: Ying Xie <ying.xie@microsoft.com>
23 lines
643 B
Django/Jinja
23 lines
643 B
Django/Jinja
[Unit]
|
|
Description=MUX Cable Container
|
|
Requires=database.service updategraph.service swss.service
|
|
After=swss.service interfaces-config.service
|
|
BindsTo=sonic.target
|
|
After=sonic.target
|
|
StartLimitIntervalSec=1200
|
|
StartLimitBurst=3
|
|
|
|
[Service]
|
|
User={{ sonicadmin_user }}
|
|
ExecStartPre=/usr/local/bin/write_standby.py
|
|
ExecStartPre=/usr/local/bin/mark_dhcp_packet.py
|
|
ExecStartPre=/usr/bin/{{docker_container_name}}.sh start
|
|
ExecStart=/usr/bin/{{docker_container_name}}.sh wait
|
|
ExecStop=/usr/bin/{{docker_container_name}}.sh stop
|
|
ExecStopPost=/usr/local/bin/write_standby.py --shutdown mux
|
|
Restart=always
|
|
RestartSec=30
|
|
|
|
[Install]
|
|
WantedBy=sonic.target
|