LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 04-16-2015, 09:42 AM   #1
hirura
LQ Newbie
 
Registered: Apr 2015
Posts: 1

Rep: Reputation: Disabled
inter netns container connection problem


Hello.

I have a problem using "ip netns" containers.

I made two netns containers with different vlans on one Linux machine. And I'd like to communicate two netns container through L2SW.

L2SW and host Linux machine is connected as follows:
Host[eno1] - L2SW[0/0] (vlan trunk connection)
In host:
eno1 - br0 (br0 is bridge)
br0 - veth00 (veth00 is one of the veth pair of veth00 and veth01)
br0 - veth10 (veth10 is one of the veth pair of veth10 and veth11)
In container1:
veth01 has vlan 4001
In container2:
veth11 has vlan 4011
In L2SW:
L2SW[0/1] - L2SW[0/2] (0/1 is access vlan 4001 and 0/2 is access vlan 4011)

In this connection setting, I'd like to execute ping/curl/... from container1 to container2.
But it failed.
The container1 learned container2's veth11 MAC address. But the container2's arp table is "container1's IP address: incomplete".

The commands of L2SW and Linux machine are following.
Does anyone have any idea?

L2SW:
vlan:
vlan 4001,4011
0/0:
mode trunk
allowed vlan 4001,4011
0/1:
mode access
vlan 4001
0/2:
mode access
vlan 4011

Host:
Version:
uname -a
Linux pi 3.10.0-123.20.1.el7.x86_64 #1 SMP Thu Jan 29 18:05:33 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux

Command:

ip link add name br0 type bridge
ip link set dev br0 up
ip link set dev eno1 master br0

ip netns add ns4001
ip netns exec ns4001 ip link set dev lo up
ip link add name veth00 type veth peer name veth01
ip link set dev veth00 up
ip link set dev veth01 netns ns4001
ip netns exec ns4001 ip link add name veth01.4001 link veth01 type vlan id 4001
ip netns exec ns4001 ip addr add 192.168.20.2/24 dev veth01.4001
ip netns exec ns4001 ip link set dev veth01 up
ip netns exec ns4001 ip link set dev veth01.4001 up
ip link set dev veth00 master br0

ip netns add ns4011
ip netns exec ns4011 ip link set dev lo up
ip link add name veth10 type veth peer name veth11
ip link set dev veth10 up
ip link set dev veth11 netns ns4011
ip netns exec ns4011 ip link add name veth11.4011 link veth11 type vlan id 4011
ip netns exec ns4011 ip addr add 192.168.20.3/24 dev veth11.4011
ip netns exec ns4011 ip link set dev veth11 up
ip netns exec ns4011 ip link set dev veth11.4011 up
ip link set dev veth10 master br0

ip netns exec ns4001 ping 192.168.20.3
...failed...
Attached Thumbnails
Click image for larger version

Name:	image.png
Views:	26
Size:	112.2 KB
ID:	18142  

Last edited by hirura; 04-16-2015 at 09:51 AM. Reason: attached network image
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
openSuSE 11.2 - now has nscd and netns running - never did before Lunar Linux - Networking 0 01-26-2012 02:22 PM
[SOLVED] Inter process and inter computer communication jthjth Linux - Newbie 1 12-27-2011 03:53 PM
inter net connection in fedora 10 pundari Linux - Newbie 3 09-19-2011 02:28 PM
Inter net connection using USB to USB modems( BSNL Clarity IIA) akoyavk Linux - Newbie 1 12-24-2009 01:50 AM
Help diagnosing a slow inter-network connection. JELG Linux - Networking 3 10-18-2007 01:51 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 02:13 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration