Re: [PATCH] ipv4: in new netns initialize sysctls in net.ipv4.conf.* with defaults

2016-02-25 Thread David Miller
From: Nicolas Dichtel Date: Thu, 25 Feb 2016 15:20:48 +0100 > Le 24/02/2016 23:05, Eric W. Biederman a écrit : > [snip] >> In the general case the current behavior is random and not something >> applications can count on, and we would do well to fix it so it is >> less >> random. In particular c

Re: [PATCH] ipv4: in new netns initialize sysctls in net.ipv4.conf.* with defaults

2016-02-25 Thread Nicolas Dichtel
Le 24/02/2016 23:05, Eric W. Biederman a écrit : [snip] In the general case the current behavior is random and not something applications can count on, and we would do well to fix it so it is less random. In particular consider the case of an application in a non-initial network namespace creati

Re: [PATCH] ipv4: in new netns initialize sysctls in net.ipv4.conf.* with defaults

2016-02-24 Thread Eric W. Biederman
David Miller writes: > From: Konstantin Khlebnikov > Date: Sun, 21 Feb 2016 10:11:02 +0300 > >> Currently initial net.ipv4.conf.all.* and net.ipv4.conf.default.* are >> copied from init network namespace because static structures are used >> for init_net. This makes no sense because new netns mi

Re: [PATCH] ipv4: in new netns initialize sysctls in net.ipv4.conf.* with defaults

2016-02-24 Thread David Miller
From: Konstantin Khlebnikov Date: Wed, 24 Feb 2016 08:16:59 +0300 > Major kernel upgrades always break something in weird setups. > This shouldn't block bug fixing. A bug for you is a feature for another person. I'm standing by my position, and will not apply this and break existing setups, sor

Re: [PATCH] ipv4: in new netns initialize sysctls in net.ipv4.conf.* with defaults

2016-02-23 Thread Konstantin Khlebnikov
On Wed, Feb 24, 2016 at 2:21 AM, David Miller wrote: > From: Konstantin Khlebnikov > Date: Sun, 21 Feb 2016 10:11:02 +0300 > >> Currently initial net.ipv4.conf.all.* and net.ipv4.conf.default.* are >> copied from init network namespace because static structures are used >> for init_net. This make

Re: [PATCH] ipv4: in new netns initialize sysctls in net.ipv4.conf.* with defaults

2016-02-23 Thread David Miller
From: Konstantin Khlebnikov Date: Sun, 21 Feb 2016 10:11:02 +0300 > Currently initial net.ipv4.conf.all.* and net.ipv4.conf.default.* are > copied from init network namespace because static structures are used > for init_net. This makes no sense because new netns might be created > from any netns

Re: [PATCH] ipv4: in new netns initialize sysctls in net.ipv4.conf.* with defaults

2016-02-21 Thread Eric W. Biederman
Konstantin Khlebnikov writes: > Currently initial net.ipv4.conf.all.* and net.ipv4.conf.default.* are > copied from init network namespace because static structures are used > for init_net. This makes no sense because new netns might be created > from any netns. This patch makes private copy also

Re: [PATCH] ipv4: in new netns initialize sysctls in net.ipv4.conf.* with defaults

2016-02-21 Thread Vasily Averin
Konstantin, I've investigated question with sysctls initialization inside namespaces some time ago. IIRC I've found people expect that sysctl values should be inherited from parent namespace. It allows node admin to adjust unsafe pre-compiled settings, and prepare adequate defaults before creat

[PATCH] ipv4: in new netns initialize sysctls in net.ipv4.conf.* with defaults

2016-02-21 Thread Konstantin Khlebnikov
Currently initial net.ipv4.conf.all.* and net.ipv4.conf.default.* are copied from init network namespace because static structures are used for init_net. This makes no sense because new netns might be created from any netns. This patch makes private copy also for init netns if network namespaces ar

Re: [PATCH] ipv4: in new netns initialize sysctls in net.ipv4.conf.* with defaults

2016-02-21 Thread Konstantin Khlebnikov
On 21.02.2016 12:25, Vasily Averin wrote: Konstantin, I've investigated question with sysctls initialization inside namespaces some time ago. IIRC I've found people expect that sysctl values should be inherited from parent namespace. It allows node admin to adjust unsafe pre-compiled settings,