Quantum basic RDO setup (grizzly) to have original LAN as external on Fedora 19

September 20, 2013
Follow as normal http://openstack.redhat.com/Neutron-Quickstart. Only if you have one Ethernet interface on box then do it,
otherwise it’s easy to keep native names for OVS ports.
When done switch to eth0 per

http://unix.stackexchange.com/questions/81834/how-can-i-change-the-default-ens33-network-device-to-old-eth0-on-fedora-19

      1.Remove biosdevname if it is installed. (yum remove biosdevname
      2. Disable the udev rule: ln -s /dev/null /etc/udev/rules.d/80-net-name-slot.rules
      3. Reboot
and  create under /etc/sysconfig/network-scripts.

[root@localhost network-scripts]# cat ifcfg-br-ex

DEVICE=”br-ex”
BOOTPROTO=”static”
IPADDR=”192.168.1.52″
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@localhost network-scripts]# cat ifcfg-eth0

NAME=”eth0″
HWADDR=90:E6:BA:2D:11:EB
ONBOOT=”no”
TYPE=”OVSPort”
DEVICETYPE=”ovs”
OVS_BRIDGE=br-ex
NM_CONTROLLED=no
IPV6INIT=no

Then enable network service and reboot.
Turn off interface eth0 , update ONBOOT=”no” to ONBOOT=”yes” in ifcfg-eth0, then  restart network service.
In dashboard environment delete router1 and public network.
Create router2 and internal interface to private network.
#   source keystonerc_admin
#   nova secgroup-add-rule default icmp -1 -1 0.0.0.0/0
#   nova secgroup-add-rule default tcp 22 22 0.0.0.0/0
#   quantum net-create public –router:external=True
#   quantum subnet-create public 192.168.1.0/24 –name vlan \
     –enable_dhcp False –allocation_pool  \
     start=192.168.1.57, end=192.168.1.62  \
–gateway 192.168.1.1
#  quantum floatingip-create public
***********

Next step :

***********
#  source keystonerc_admin
#  EXTERNAL_NETWORK_ID=`quantum net-list | grep public | awk ‘{ print $2 }’`
# quantum router-gateway-set router2  $EXTERNAL_NETWORK_ID
# INT_SUBNET_ID=`quantum subnet-list | grep private_subnet | awk ‘{ print $2}’`
# quantum subnet-update $INT_SUBNET_ID –dns_nameservers list=true 83.221.202.254
# quantum subnet-update $INT_SUBNET_ID –gateway_ip 10.0.0.1
**************************************************************************
Router2 and internal interface to private network may be also created via CLI:
**************************************************************************

# EXTERNAL_NETWORK_ID=`quantum net-list | grep public | awk ‘{ print $2 }’`
# INT_SUBNET_ID=`quantum subnet-list | grep private_subnet | awk ‘{ print $2}’`
# SERVICE_TENANT_ID=`keystone tenant-list | grep service | awk ‘{ print $2}’`
# quantum router-create –name router2 –tenant-id $SERVICE_TENANT_ID router2
# quantum router-gateway-set router2  $EXTERNAL_NETWORK_ID
# quantum router-interface-add router2  $INT_SUBNET_ID
# quantum subnet-update $INT_SUBNET_ID –dns_nameservers list=true 83.221.202.254
# quantum subnet-update $INT_SUBNET_ID –gateway_ip 10.0.0.1

View  http://openstack.redhat.com/forum/discussion/196/quantum-basic-setup/p1

View snapshots at  http://bderzhavets.blogspot.ru/2013/09/quantum-basic-rdo-setup-grizzly-to-have_16.html

To make configuration persistent between reboots due to known bugs

Bug 981583 - Openstack firewall rules are not enabled after reboot   

https://bugzilla.redhat.com/show_bug.cgi?id=981583

Bug 981652 - firewalld does not cover openstack/packstack use case   

https://bugzilla.redhat.com/show_bug.cgi?id=981652

Run:-

# yum -y install iptables-services
# systemctl disable firewalld
# systemctl enable iptables

Remote noVNC cloud instances access via web browser:

[root@localhost ~(keystone_admin)]# nova list
+————————————–+————+———–+——————————–+
| ID                                   | Name       | Status    | Networks           |
+————————————–+————+———–+——————————–+
| 27616e5c-a08d-4c18-8366-038a03dec77c    | Ubuntu1310 | ACTIVE    | private=10.0.0.6, 192.168.1.63 |
| ca57df26-ae59-4ea0-a9c3-b21b1e862947    | VF19BD   | SUSPENDED | private=10.0.0.3, 192.168.1.59 |
| d37ccd48-0ba4-4e28-aa0b-eb43deb8b948 | WinSRV2012 | ACTIVE    | private=10.0.0.5, 192.168.1.61 |
+————————————–+————+———–+——————————–+
[root@localhost ~(keystone_admin)]# nova get-vnc-console 27616e5c-a08d-4c18-8366-038a03dec77c novnc
+——-+————————————————————————————+
| Type  | Url                                                                              |
+——-+————————————————————————————+
| novnc | http://192.168.1.145:6080/vnc_auto.html?token=f8945baa-37bd-4c0c-abd4-17fb4e93e163 |
+——-+————————————————————————————+
[root@localhost ~(keystone_admin)]# nova get-vnc-console d37ccd48-0ba4-4e28-aa0b-eb43deb8b948 novnc
+——-+————————————————————————————+
| Type  | Url                                                                              |
+——-+————————————————————————————+
| novnc | http://192.168.1.145:6080/vnc_auto.html?token=093f7649-e478-48e3-aaed-41ed207dff6e |
+——-+————————————————————————————+


Quantum basic RDO setup (grizzly) to have original LAN as external on CentOS 6.4

September 15, 2013

Attempting to follow http://allthingsopen.com/2013/08/23/openstack-packstack-installation-with-external-connectivity/
I’ve got an error after starting :-
# packstack –allinone –quantum-l3-ext-bridge=eth0
It reports that ovs port eth0 already exists. Approach bellow in general follows RDO’s discussion at http://openstack.redhat.com/forum/discussion/196/quantum-basic-setup/p1

Follow as normal http://openstack.redhat.com/Neutron-Quickstart
When done create under /etc/sysconfig/network-scripts

[root@Server64 network-scripts]# cat ifcfg-br-ex
DEVICE=”br-ex”
BOOTPROTO=”none”
IPADDR=”192.168.1.42″
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@Server64 network-scripts]# cat ifcfg-eth0
DEVICE=”eth0″
ONBOOT=”yes”
# HWADDR=”1C:C1:DE:76:19:70″
HWADDR=”00:22:15:63:E4:E2″
TYPE=”OVSPort”
DEVICETYPE=”ovs”
OVS_BRIDGE=br-ex
NM_CONTROLLED=no
IPV6INIT=no

Run script as root :-

for i in /etc/quantum/*.ini
do
sed -i “s/^[# ]*ovs_use_veth.*$/ovs_use_veth = True/g” $i
done

sed -i \
-e “s/^[# ]*enable_isolated_metadata.*$/enable_isolated_metadata = True/g” \
-e “s/^[# ]*enable_metadata_network.*$/enable_metadata_network = True/g”  \
/etc/quantum/dhcp_agent.ini

# chkconfig network on

REBOOT
Disable autoconnect eth0.
REBOOT

Remove old puplic (external network) and create new one as required.
Recreate router in dashboard environment and add internal interface to
private network

#   source keystonerc_admin
#   nova secgroup-add-rule default icmp -1 -1 0.0.0.0/0
#   nova secgroup-add-rule default tcp 22 22 0.0.0.0/0
#   quantum net-create public –router:external=True
#   quantum subnet-create public 192.168.1.0/24 –name vlan –enable_dhcp False –allocation_pool start=192.168.1.57,end=192.168.1.62 \
–  gateway 192.168.1.1
#   quantum floatingip-create public

#   quantum net-list
[root@Server64 ~(keystone_admin)]# quantum router-list
+————————————–+———+——————————————————–+
| id                                   | name    | external_gateway_info                                  |
+————————————–+———+——————————————————–+
| c56c1cc1-a11b-454c-9ccb-17dc7e62f475 | router1 |
+————————————–+———+——————————————————–+
[root@Server64 ~(keystone_admin)]# quantum net-list
+————————————–+———+—————————————————–+
| id                                   | name    | subnets                                             |
+————————————–+———+—————————————————–+
| 6823b670-231c-4b31-9325-12dc098087b2 | private | 203320cc-cd60-486d-b092-eec99740c4cc 10.0.0.0/24    |
| c9615975-beb4-461a-9aad-b740a3350bf5 | public  | 40568df0-9bae-4578-8ae9-56d0ae7d4a2e 192.168.1.0/24 |
+————————————–+———+—————————————————–+
#   quantum router-gateway-set c56c1cc1-a11b-454c-9ccb-17dc7e62f475 c9615975-beb4-461a-9aad-b740a3350bf5

[root@Server64 ~(keystone_admin)]# quantum subnet-list
+————————————–+—————-+—————-+————————————————–+
| id                                   | name           | cidr           | allocation_pools                                 |
+————————————–+—————-+—————-+————————————————–+
| 203320cc-cd60-486d-b092-eec99740c4cc | private_subnet | 10.0.0.0/24    | {“start”: “10.0.0.2″, “end”: “10.0.0.254″}       |
| 40568df0-9bae-4578-8ae9-56d0ae7d4a2e | vlan           | 192.168.1.0/24 | {“start”: “192.168.1.57″, “end”: “192.168.1.62″} |
+————————————–+—————-+—————-+————————————————–+
[root@Server64 ~(keystone_admin)]#  quantum subnet-update 203320cc-cd60-486d-b092-eec99740c4cc  –dns_nameservers list=true 83.221.202.254
Updated subnet: 203320cc-cd60-486d-b092-eec99740c4cc
[root@RServer64 ~(keystone_admin)]#  quantum subnet-update 203320cc-cd60-486d-b092-eec99740c4cc  –gateway_ip 10.0.0.1
Updated subnet: 203320cc-cd60-486d-b092-eec99740c4cc

In other way it may look like :-

# EXTERNAL_NETWORK_ID=`quantum net-list | grep public | awk ‘{ print $2 }’`
# quantum router-gateway-set router1 $EXTERNAL_NETWORK_ID
# INT_SUBNET_ID=`quantum subnet-list | grep private_subnet | awk ‘{ print $2}’`
# quantum subnet-update $INT_SUBNET_ID –dns_nameservers list=true 83.221.202.254
# quantum subnet-update $INT_SUBNET_ID –gateway_ip 10.0.0.1

For better snapshots view another blog entry :-

http://bderzhavets.blogspot.ru/2013/09/quantum-basic-rdo-setup-grizzly-to-have.html

Dashboard

Running F19 instance routed to orinal LAN as external

Running Internet browser on F19 instance  via original router on the LAN

References
1.http://openstack.redhat.com/forum/discussion/196/quantum-basic-setup/p1


Follow

Get every new post delivered to your Inbox.