Add setmtu command, fix bond lifetime issue

This commit is contained in:
Joseph Henry 2023-08-15 12:59:58 -07:00
parent e18172d434
commit b8b5d0bff8
No known key found for this signature in database
GPG key ID: C45B33FF5EBC9344
10 changed files with 228 additions and 43 deletions

View file

@ -456,6 +456,26 @@ class Bond {
*/
static SharedPtr<Bond> getBondByPeerId(int64_t identity);
/**
* Set MTU for link by given interface name and IP address (across all bonds)
*
* @param mtu MTU to be used on this link
* @param ifStr interface name to match
* @param ipStr IP address to match
* @return Whether the MTU was set
*/
static bool setAllMtuByTuple(uint16_t mtu, const std::string& ifStr, const std::string& ipStr);
/**
* Set MTU for link by given interface name and IP address
*
* @param mtu MTU to be used on this link
* @param ifStr interface name to match
* @param ipStr IP address to match
* @return Whether the MTU was set
*/
bool setMtuByTuple(uint16_t mtu, const std::string& ifStr, const std::string& ipStr);
/**
* Add a new bond to the bond controller.
*