From: Mark Goddard <mark@stackhpc.com>
Sent: Friday, October 30, 2020 4:37 AM
To: Radosław Piliszek <radoslaw.piliszek@gmail.com>
Cc: Braden, Albert <C-Albert.Braden@charter.com>; OpenStack Discuss <openstack-discuss@lists.openstack.org>
Subject: Re: [kolla] Setting up eth1 on VM for AIO

 

On Thu, 29 Oct 2020 at 16:20, Radosław Piliszek <radoslaw.piliszek@gmail.com> wrote:

Hi Albert!

Sorry for top posting but I don't really see which part to quote would
be best so they all lose. :D

Indeed, it's tricky to handle this if you are not a fan of linux networking.
I guess we should document an example way....

Anyhow, the way e.g. Kayobe handles it for users (as it deals with
baremetal details) is to use bridges and veths.
Basically, you create a bridge, attach it to the expected interface,
set any networking you still want on that network for this host on
this bridge.
Then, you create a veth pair and connect one end to it and the second
one is given to neutron.

>Alternatively, if this is just for development, you can use a dummy interface.

> 

>ip link add link eth1 type dummy

> 

>It's not persistent, but good enough for testing. If you need external network access from it you could add a MASQUERADE iptables rule and enable the IP >forwarding sysctl. 

 

That seems to be working. After googling a bit I was able to make it persistent:

 

[root@adjutant-poc ~]# cat /etc/modules-load.d/dummy.conf

dummy

 

[root@adjutant-poc ~]# cat /etc/modprobe.d/dummy.conf

install dummy /sbin/modprobe --ignore-install dummy; /sbin/ip link set name eth1 dev dummy0

 

[root@adjutant-poc ~]# cat /etc/sysconfig/network-scripts/ifcfg-eth1

NAME=eth1

BOOTPROTO=none

DEVICE=eth1

ONBOOT=yes

TYPE=Ethernet

NM_CONTROLLED=no

 

[root@adjutant-poc ~]# ip a

1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000

    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00

    inet 127.0.0.1/8 scope host lo

       valid_lft forever preferred_lft forever

    inet6 ::1/128 scope host

       valid_lft forever preferred_lft forever

2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 8950 qdisc pfifo_fast state UP group default qlen 1000

    link/ether fa:16:3e:22:c4:e2 brd ff:ff:ff:ff:ff:ff

    inet 192.168.1.83/22 brd 192.168.3.255 scope global dynamic eth0

       valid_lft 85821sec preferred_lft 85821sec

    inet6 fe80::f816:3eff:fe22:c4e2/64 scope link

       valid_lft forever preferred_lft forever

3: eth1: <BROADCAST,NOARP,UP,LOWER_UP> mtu 1500 qdisc noqueue state UNKNOWN group default qlen 1000

    link/ether 7e:e1:fe:31:c9:2e brd ff:ff:ff:ff:ff:ff

    inet6 fe80::7ce1:feff:fe31:c92e/64 scope link

       valid_lft forever preferred_lft forever

 

-yoctozepto

On Thu, Oct 29, 2020 at 12:49 PM Braden, Albert
<C-Albert.Braden@charter.com> wrote:
>
> I’m trying to setup an allinone kolla-ansible Train POC on a VM, and I’m following the instructions here:
>
>
>
> https://docs.openstack.org/kolla-ansible/train/user/quickstart.html
>
>
>
> Under “Prepare initial configuration” where it talks about globals.yml, it says I need 2 network interfaces:
>
>
>
> network_interface: "eth0"
>
> neutron_external_interface: "eth1"
>
>
>
> My VM has a private IP and a floating IP that I use to ssh to it:
>
>
>
> | ID                                   | Name              | Status  | Networks                              | Image           | Flavor         |
>
> | 41f6782a-8ca8-4ab4-8fdc-776584139ba0 | adjutant-poc      | ACTIVE  | private=<primary IP>, <floating IP>  |                 | s1-standard-08 |
>
>
>
> I tried various options for eth1 but I can’t seem to get it to work:
>
>
>
> [root@adjutant-poc network-scripts]# cat /etc/sysconfig/network-scripts/ifcfg-eth1
>
> BOOTPROTO=dhcp
>
> DEVICE=eth1
>
> ONBOOT=yes
>
> TYPE=Ethernet
>
> NM_CONTROLLED=no
>
>
>
> I tried creating another port and adding it but that didn’t seem to make a difference. What am I doing wrong? Do I really need 2 network interfaces on the VM? If so, what’s the correct way to add one?
>
>
>
> [root@adjutant-poc network-scripts]# service network restart
>
> Restarting network (via systemctl):  Job for network.service failed because the control process exited with error code. See "systemctl status network.service" and "journalctl -xe" for details.
>
>                                                           [FAILED]
>
>
>
> Log:
>
>
>
> http://paste.debian.net/1168982/
>
>
>
> I apologize for the nonsense below. So far I have not been able to stop it from being attached to my external emails. I'm working on it.
>
>
>
> The contents of this e-mail message and
> any attachments are intended solely for the
> addressee(s) and may contain confidential
> and/or legally privileged information. If you
> are not the intended recipient of this message
> or if this message has been addressed to you
> in error, please immediately alert the sender
> by reply e-mail and then delete this message
> and any attachments. If you are not the
> intended recipient, you are notified that
> any use, dissemination, distribution, copying,
> or storage of this message or any attachment
> is strictly prohibited.

The contents of this e-mail message and
any attachments are intended solely for the
addressee(s) and may contain confidential
and/or legally privileged information. If you
are not the intended recipient of this message
or if this message has been addressed to you
in error, please immediately alert the sender
by reply e-mail and then delete this message
and any attachments. If you are not the
intended recipient, you are notified that
any use, dissemination, distribution, copying,
or storage of this message or any attachment
is strictly prohibited.