mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-09-24 16:03:43 +08:00
hostman: fix setting mtu for tunnel padding
This commit is contained in:
@@ -105,7 +105,7 @@ func (d *SBaseBridgeDriver) BringupInterface() error {
|
||||
for _, inf := range infs {
|
||||
cmd := []string{"ifconfig", inf.String(), "up"}
|
||||
if options.HostOptions.TunnelPaddingBytes > 0 {
|
||||
cmd = append(cmd, "mtu", fmt.Sprintf("%d", options.HostOptions.TunnelPaddingBytes))
|
||||
cmd = append(cmd, "mtu", fmt.Sprintf("%d", 1500+options.HostOptions.TunnelPaddingBytes))
|
||||
}
|
||||
if _, err := procutils.NewCommand(cmd[0], cmd[1:]...).Output(); err != nil {
|
||||
return err
|
||||
|
||||
Reference in New Issue
Block a user