mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-15 14:53:44 +00:00
If you can't set hashsize on nf_conntrack don't fail
This commit is contained in:
parent
3c0da8609b
commit
8d57fe7c48
@ -88,7 +88,10 @@ func (rct realConntracker) SetMax(max int) error {
|
|||||||
}
|
}
|
||||||
// TODO: generify this and sysctl to a new sysfs.WriteInt()
|
// TODO: generify this and sysctl to a new sysfs.WriteInt()
|
||||||
rct.logger.Info("Setting conntrack hashsize", "conntrackHashsize", max/4)
|
rct.logger.Info("Setting conntrack hashsize", "conntrackHashsize", max/4)
|
||||||
return writeIntStringFile("/sys/module/nf_conntrack/parameters/hashsize", max/4)
|
if err := writeIntStringFile("/sys/module/nf_conntrack/parameters/hashsize", max/4); err != nil {
|
||||||
|
rct.logger.Error(err, "failed to set conntrack hashsize", "conntrackHashsize", max/4)
|
||||||
|
}
|
||||||
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func (rct realConntracker) SetTCPEstablishedTimeout(seconds int) error {
|
func (rct realConntracker) SetTCPEstablishedTimeout(seconds int) error {
|
||||||
|
Loading…
Reference in New Issue
Block a user