Skip to content

Commit c7a0f8e

Browse files
authored
Merge branch 'sonic-net:master' into vrrp_orch
2 parents 9c02f43 + a8c358f commit c7a0f8e

17 files changed

+1681
-65
lines changed

cfgmgr/vlanmgr.cpp

+17-1
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,17 @@ bool VlanMgr::addHostVlanMember(int vlan_id, const string &port_alias, const str
221221
cmds << BASH_CMD " -c " << shellquote(inner.str());
222222

223223
std::string res;
224-
EXEC_WITH_ERROR_THROW(cmds.str(), res);
224+
try
225+
{
226+
EXEC_WITH_ERROR_THROW(cmds.str(), res);
227+
}
228+
catch (const std::runtime_error& e)
229+
{
230+
if (!isMemberStateOk(port_alias))
231+
return false;
232+
else
233+
EXEC_WITH_ERROR_THROW(cmds.str(), res);
234+
}
225235

226236
return true;
227237
}
@@ -632,6 +642,12 @@ void VlanMgr::doVlanMemberTask(Consumer &consumer)
632642

633643
m_vlanMemberReplay.erase(kfvKey(t));
634644
}
645+
else
646+
{
647+
SWSS_LOG_INFO("Netdevice for %s not ready, delaying", kfvKey(t).c_str());
648+
it++;
649+
continue;
650+
}
635651
}
636652
else if (op == DEL_COMMAND)
637653
{

0 commit comments

Comments
 (0)