Ask Your Question
0

How to get external and management network on same NIC ?

asked 2014-05-28 17:49:09 -0500

Jo gravatar image

updated 2014-05-29 07:27:27 -0500

Hi !

I'm trying to set up OpenStack like this :

I have my management network, and external network on the same physical interface.

My network config on the Network node (running Neutron) is like this :

auto eth0
iface eth0 inet static
 address 10.0.0.21
 netmask 255.255.255.0
 gateway 10.0.0.254

auto eth0:1
iface eth0:1 inet static
 address 10.0.1.21
 netmask 255.255.255.0

auto eth0:2
iface eth0:2 inet manual
 up ip link set dev $IFACE up
 down ip link set dev $IFACE down

Unfortunately, the eth0:2 refuse to bring up without IP Address. So, I'm stuck, OpenvSwitch can't use it into his external bridge.

I've tried to create a MacVLAN interface, but without success.

Have you any hint to help me ?

Thanks.

EDIT :

network:~# ovs-vsctl show
4ff29121-f407-426e-84ce-cebdbb813c37
    Bridge br-tun
        Port br-tun
            Interface br-tun
                type: internal
        Port patch-int
            Interface patch-int
                type: patch
                options: {peer=patch-tun}
        Port "gre-0afdfb1f"
            Interface "gre-0afdfb1f"
                type: gre
                options: {in_key=flow, local_ip="10.0.1.21", out_key=flow, remote_ip="10.0.1.31"}
    Bridge br-int
        Port "tapba6e2cdd-2e"
            tag: 2
            Interface "tapba6e2cdd-2e"
                type: internal
        Port "tapbcf2133c-02"
            tag: 1
            Interface "tapbcf2133c-02"
                type: internal
        Port br-int
            Interface br-int
                type: internal
        Port patch-tun
            Interface patch-tun
                type: patch
                options: {peer=patch-int}
        Port "qr-b9589121-45"
            tag: 1
            Interface "qr-b9589121-45"
                type: internal
    Bridge br-ex
        Port br-ex
            Interface br-ex
                type: internal
        Port "qg-229b5ed7-0a"
            Interface "qg-229b5ed7-0a"
                type: internal
        Port "eth0"
            Interface "eth0"
    ovs_version: "2.0.1"


compute:~# ovs-vsctl show
ce1312a8-e9f1-45d8-862b-6e7351c36e64
    Bridge br-tun
        Port patch-int
            Interface patch-int
                type: patch
                options: {peer=patch-tun}
        Port br-tun
            Interface br-tun
                type: internal
        Port "gre-0afdfb15"
            Interface "gre-0afdfb15"
                type: gre
                options: {in_key=flow, local_ip="10.0.1.31", out_key=flow, remote_ip="10.0.1.21"}
    Bridge br-int
        Port patch-tun
            Interface patch-tun
                type: patch
                options: {peer=patch-int}
        Port "qvo49467d22-29"
            tag: 4
            Interface "qvo49467d22-29"
        Port "qvo5243cd96-72"
            tag: 4
            Interface "qvo5243cd96-72"
        Port br-int
            Interface br-int
                type: internal
    ovs_version: "2.0.1"

compute:~# brctl show
bridge name     bridge id               STP enabled     interfaces
qbr49467d22-29          8000.32d7b2175502       no              qvb49467d22-29
                                                        tap49467d22-29
qbr5243cd96-72          8000.ee566214aa3c       no              qvb5243cd96-72
                                                        tap5243cd96-72

EDIT2 :

This error occurs when I try to attach a floating IP to my VM in ext network :

External network xxx is not reachable from subnet yyy. Therefore, cannot associate Port zzz with a Floating IP
edit retag flag offensive close merge delete

2 answers

Sort by ยป oldest newest most voted
3

answered 2014-05-28 19:00:32 -0500

dbaxps gravatar image
On RH's systems I manage as follows :-

[root@icehouse1 network-scripts(keystone_admin)]# cat ifcfg-br-ex
DEVICE="br-ex"
BOOTPROTO="static"
IPADDR="192.168.1.127"
NETMASK="255.255.255.0"
DNS1="83.221.202.254"
BROADCAST="192.168.1.255"
GATEWAY="192.168.1.1"
NM_CONTROLLED="no"
DEFROUTE="yes"
IPV4_FAILURE_FATAL="yes"
IPV6INIT=no
ONBOOT="yes"
TYPE="OVSBridge"
DEVICETYPE="ovs"

[root@icehouse1 network-scripts(keystone_admin)]# cat ifcfg-eth0
DEVICE="eth0"
ONBOOT="yes"
TYPE="OVSPort"
DEVICETYPE="ovs"
OVS_BRIDGE=br-ex
NM_CONTROLLED=no
IPV6INIT=no

[root@icehouse1 ~(keystone_admin)]# ovs-vsctl add-port  br-ex eth0

In other words I make eth0 OVS port of OVS bridge br-ex and assign IP of eth0 to br-ex
edit flag offensive delete link more

Comments

Well, thanks to you two, I got something new. Both virtual router IP and management IP respond to a ping.

But I still got an issue. My VMs are unable to ping their gateway. I can see ARP Requests from VM into br-ex but no response from virtual router.

Any idea ?

Thanks.

Jo gravatar imageJo ( 2014-05-29 04:40:30 -0500 )edit

Please, post ovs-vsctl show on Controller && Compute and brctl show on Compute ( when your VM is running).

dbaxps gravatar imagedbaxps ( 2014-05-29 05:03:26 -0500 )edit

Post edited with these information.

Jo gravatar imageJo ( 2014-05-29 05:45:17 -0500 )edit
  1. Does your VM complaining 169.254.169.254 at boot up ?
  2. When you log into VM does it have private IP ?
  3. ip netns | grep your-router-id
  4. ip netns | grep your-private-network-id
dbaxps gravatar imagedbaxps ( 2014-05-29 06:06:41 -0500 )edit
  1. Nope
    1. Neither
    2. Returns a namespace with my router-id
    3. I found no namespace with any network-id (private or not)

When I try to attach a floating IP to my VM in ext network : External network xxx is not reachable from subnet yyy. Therefore, cannot associate Port zzz with a Floating IP

Jo gravatar imageJo ( 2014-05-29 07:26:02 -0500 )edit
1

answered 2014-05-29 00:39:46 -0500

SGPJ gravatar image

You can do this after above steps: sudo ovs-vsctl --no-wait -- --may-exist add-port br-ex eth0

it worked for me.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2014-05-28 17:49:09 -0500

Seen: 2,402 times

Last updated: May 29 '14