Skip to content

Commit

Permalink
[vlanmgr] Disable arp_evict_nocarrier for vlan host intf
Browse files Browse the repository at this point in the history
Signed-off-by: Longxiang Lyu <[email protected]>
  • Loading branch information
lolyu committed Oct 6, 2022
1 parent 31c9321 commit cc21284
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions cfgmgr/vlanmgr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,11 @@ bool VlanMgr::addHostVlan(int vlan_id)
std::string res;
EXEC_WITH_ERROR_THROW(cmds, res);

res.clear();
const std::string echo_cmd = std::string("")
+ ECHO_CMD + " 0 > /proc/sys/net/ipv4/conf/" + VLAN_PREFIX + std::to_string(vlan_id) + "/arp_evict_nocarrier";
swss::exec(echo_cmd, res);

return true;
}

Expand Down

0 comments on commit cc21284

Please sign in to comment.