From: zhuyj <zyjzyj2000@gmail.com>
To: Cong Wang <cwang@twopensource.com>
Cc: "David S. Miller" <davem@davemloft.net>,
Hong Zhiguo <honkiko@gmail.com>,
LKML <linux-kernel@vger.kernel.org>,
netdev <netdev@vger.kernel.org>,
"Tao, Yue" <Yue.Tao@windriver.com>,
Alexandre Dietsch <alexandre.dietsch@windriver.com>,
zhuyj <zyjzyj2000@gmail.com>
Subject: Re: ipv4: net namespace does not inherit network configurations
Date: Thu, 31 Jul 2014 09:59:12 +0800 [thread overview]
Message-ID: <53D9A2F0.4040808@gmail.com> (raw)
In-Reply-To: <CAHA+R7MC2gKeSWqR8pDDX26D-Th4BG1AveM+HseMMPjLBJuWDw@mail.gmail.com>
On 07/30/2014 01:48 AM, Cong Wang wrote:
> On Tue, Jul 29, 2014 at 2:29 AM, zhuyj <zyjzyj2000@gmail.com> wrote:
>> Hi,all
>>
>> I did a test on kernel3.16 rc6:
>>
>> root@qemu1:~# echo 1 > /proc/sys/net/ipv6/conf/all/forwarding
>> root@qemu1:~# echo 1 > /proc/sys/net/ipv4/conf/all/forwarding
>> root@qemu1:~# ip netns list
>> root@qemu1:~# ip netns add fib1
>> root@qemu1:~# ip netns exec fib1 bash
>> root@qemu1:~# cat /proc/sys/net/ipv6/conf/all/forwarding
>> 0
>> root@qemu1:~# cat /proc/sys/net/ipv4/conf/all/forwarding
>> 1
>>
>> The behavior of ipv4 and ipv6 is very inconsistent. I checked
>> the kernel source code. I found that from this patch
>> [ipv6: fix bad free of addrconf_init_net], the above difference
>> appeared.
>>
>> Since a net namespace is independent to another. That is, there
>> is no any relationship between the net namespaces. So the behavior
>> of ipv4 is not correct.
>>
> Well, they are already independent, not shared, just that the initial
> value is duplicated from init_net for IPv4.
>
> This change might break existing applications which rely on this
> behavior, but given IPv6 change is almost the same, I think it's ok.
>
> BTW, you need to submit a patch as normal, instead of as an attachment.
>
OK. Thanks a lot.
Zhu Yanjun
next prev parent reply other threads:[~2014-07-31 1:59 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-29 9:29 ipv4: net namespace does not inherit network configurations zhuyj
2014-07-29 17:48 ` Cong Wang
2014-07-31 1:59 ` zhuyj [this message]
2014-10-13 8:20 ` zhuyj
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=53D9A2F0.4040808@gmail.com \
--to=zyjzyj2000@gmail.com \
--cc=Yue.Tao@windriver.com \
--cc=alexandre.dietsch@windriver.com \
--cc=cwang@twopensource.com \
--cc=davem@davemloft.net \
--cc=honkiko@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.