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

Vlanmgrd handling of portchannel does not exist more gracefully. #3367

Open
wants to merge 11 commits into
base: master
Choose a base branch
from
18 changes: 17 additions & 1 deletion cfgmgr/vlanmgr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,17 @@ bool VlanMgr::addHostVlanMember(int vlan_id, const string &port_alias, const str
cmds << BASH_CMD " -c " << shellquote(inner.str());

std::string res;
EXEC_WITH_ERROR_THROW(cmds.str(), res);
try
{
EXEC_WITH_ERROR_THROW(cmds.str(), res);
}
catch (const std::runtime_error& e)
{
if (!isMemberStateOk(port_alias))
return false;
else
EXEC_WITH_ERROR_THROW(cmds.str(), res);
}

return true;
}
Expand Down Expand Up @@ -632,6 +642,12 @@ void VlanMgr::doVlanMemberTask(Consumer &consumer)

m_vlanMemberReplay.erase(kfvKey(t));
}
else
{
SWSS_LOG_INFO("Netdevice for %s not ready, delaying", kfvKey(t).c_str());
it++;
continue;
}
}
else if (op == DEL_COMMAND)
{
Expand Down
Loading