The procedure below has been used to create a 3-node OPNFV install using Intel NUC i7 nodes with 16GB RAM, 250MB SSD, and 1 TB HDD. The install uses one NUC for the Jumphost, and one each for the controller (OpenStack + ODL) and the compute nodes.
ip addr
su visudo opnfv ALL=(ALL) ALL
sudo yum -y update
sudo shutdown -r 0
sudo vi /etc/hostname jumphost1.opnfv.org
sudo systemctl stop NetworkManager sudo systemctl disable NetworkManager
sudo vi /etc/sysconfig/network-scripts/ifcfg-enp0s25 TYPE="Ethernet" BOOTPROTO="static" IPADDR=192.168.1.201 NETMASK=255.255.255.0 GATEWAY=192.168.1.1 NM_CONTROLLED="no" (rest as-is)
sudo service network restart sudo setenforce 0
sudo vi /etc/resolv.conf nameserver 8.8.8.8 nameserver 8.8.4.4
sudo setenforce 0 sudo sed -i 's/SELINUX=.*/SELINUX=permissive/' /etc/selinux/config
sudo systemctl stop firewalld sudo systemctl disable firewalld
sudo yum -y install ntp sudo systemctl start ntpd date
sudo yum -y install net-tools
sudo yum -y install git cd ~
git clone https://blsaws@gerrit.opnfv.org/gerrit/genesis
curl "https://gerrit.opnfv.org/gerrit/gitweb?p=genesis.git;a=snapshot;h=756ee8c81cfac9a69e8f67811429e63da9af6480;sf=tgz" -o genesis-756ee8c.tar.gz gzip -d genesis-756ee8c.tar.gz tar -xvf genesis-756ee8c.tar
vi ~/genesis-756ee8c/foreman/ci/bootstrap.sh if ! git clone -b opnfv https://github.com/blsaws/khaleesi.git; then
vi ~/genesis-756ee8c/foreman/ci/opnfv_ksgen_settings_no_HA.yml
# Jumphost1:
# (for compute1:)
name: oscompute1.{{ domain_name }}
hostname: oscompute1.{{ domain_name }}
short_name: oscompute1
mac_address: "<compute1-mac>"
# (for controller1:)
name: oscontroller1.{{ domain_name }}
hostname: oscontroller1.{{ domain_name }}
short_name: oscontroller1
mac_address: "<controller1-mac>"
private_mac: "<controller1-mac>"
# Jumphost2:
# (for compute1:)
name: oscompute1.{{ domain_name }}
hostname: oscompute1.{{ domain_name }}
short_name: oscompute1
mac_address: "<compute1-mac>"
# (for controller1:)
name: oscontroller1.{{ domain_name }}
hostname: oscontroller1.{{ domain_name }}
short_name: oscontroller1
mac_address: "<controller1-mac>"
private_mac: "<controller1-mac>"
cd /opt sudo git clone -b opnfv https://github.com/blsaws/khaleesi.git
sudo vi /opt/khaleesi/wakenodes.sh # !/bin/bash yum -y install net-tools ether-wake <compute1-mac> ether-wake <controller1-mac>
sudo vi /opt/khaleesi/roles/get_nodes/foreman/tasks/main.yml - script: /opt/khaleesi/wakenodes.sh
sudo vi /opt/khaleesi/library/foreman.py # bryan_att modified to skip IPMI stuff module.exit_json(changed=True, msg="Rebuilding Node") # change elif to if so the module.exit is outside the previous if block if ipmi_host is None:
cd ~/genesis-756ee8c/foreman/ci/ sudo ./deploy.sh -single_baremetal_nic enp0s25 -base_config /home/opnfv/genesis-756ee8c/foreman/ci/opnfv_ksgen_settings_no_HA.yml
su cd /var/opt/opnfv/foreman_vm vagrant destroy -f cd - rm -rf /var/opt/opnfv exit rm /home/opnfv/.ssh/known_hosts
vi /etc/neutron/plugin.ini # add to end [ovs] bridge_mappings = physnet1:br-ex # comment out "flat_networks =*" and add under it flat_networks = physnet1
openstack-service restart neutron
vi /etc/sysconfig/network-scripts/ifcfg-br-ex DEVICE=br-ex DEVICETYPE=ovs IPADDR=192.168.1.204 NETMASK=255.255.255.0 GATEWAY=192.168.1.1 BOOTPROTO=static ONBOOT=yes TYPE=OVSBridge PROMISC=yes PEERDNS=no
[root@oscontroller1 ~]# ovs-vsctl show
22ba4760-889c-4341-b8d6-445c53ac5aaa
Manager "tcp:192.168.1.204:6640"
is_connected: true
Bridge br-ex
Controller "tcp:192.168.1.204:6633"
is_connected: true
Port "enp0s25"
Interface "enp0s25"
Port br-ex
Interface br-ex
type: internal
Bridge br-int
Controller "tcp:192.168.1.204:6633"
is_connected: true
fail_mode: secure
Port br-int
Interface br-int
ovs_version: "2.3.1"
vi /etc/sysconfig/network-scripts/ifcfg-enp0s25 NAME="enp0s25" DEVICE="enp0s25" ONBOOT=yes NETBOOT=yes (leave UUID line as is, replace rest with the below) BOOTPROTO=static TYPE=OVSPort OVS_BRIDGE=br-ex PROMISC=yes IPV4_FAILURE_FATAL=no PEERDNS=no PEERROUTES=yes
systemctl restart network
vi admin-openrc.sh (paste contents) source admin-openrc.sh
neutron net-create external1 -- --router:external=true --provider:network_type=flat --provider:physical_network=physnet1
Created a new network:
+---------------------------+--------------------------------------+
| Field | Value |
+---------------------------+--------------------------------------+
| admin_state_up | True |
| id | d7868a94-47ec-4ec7-93cc-645d3bc45898 |
| name | external1 |
| provider:network_type | flat |
| provider:physical_network | physnet1 |
| provider:segmentation_id | |
| router:external | True |
| shared | False |
| status | ACTIVE |
| subnets | |
| tenant_id | c3b15e900f0f4c7ab01576bb28d34f10 |
+---------------------------+--------------------------------------+
neutron subnet-create --disable-dhcp external1 192.168.1.0/24
Created a new subnet:
+-------------------+--------------------------------------------------+
| Field | Value |
+-------------------+--------------------------------------------------+
| allocation_pools | {"start": "192.168.1.2", "end": "192.168.1.254"} |
| cidr | 192.168.1.0/24 |
| dns_nameservers | |
| enable_dhcp | False |
| gateway_ip | 192.168.1.1 |
| host_routes | |
| id | 2a6a6be2-2ea2-4a38-84cd-3a2e9e3197e8 |
| ip_version | 4 |
| ipv6_address_mode | |
| ipv6_ra_mode | |
| name | |
| network_id | d7868a94-47ec-4ec7-93cc-645d3bc45898 |
| tenant_id | c3b15e900f0f4c7ab01576bb28d34f10 |
+-------------------+--------------------------------------------------+
==> default:
==> default: TASK: [get_nodes/foreman | make a list] ***************************************
==> default: [[ previous task time: 0:00:00.015421 = 0.02s / 1597.81s ]]
==> default: ok: [localhost]
==> default:
==> default: TASK: [get_nodes/foreman | debug var=nodes_list] ******************************
==> default: [[ previous task time: 0:00:00.008785 = 0.01s / 1597.81s ]]
==> default: ok: [localhost] => {
==> default: "var": {
==> default: "nodes_list": [
==> default: "oscontroller1.opnfv.com",
==> default: "oscompute1.opnfv.com"
==> default: ]
==> default: }
==> default: }
==> default:
==> default: TASK: [get_nodes/foreman | Wait for puppet to complete] ***********************
==> default: [[ previous task time: 0:00:00.008461 = 0.01s / 1597.82s ]]
==> default: changed: [localhost]
==> default:
==> default: msg:
==> default: Nodes are Active
==> default:
==> default: TASK: [get_nodes/foreman | Print host openstack network type (nova/neutron)]
***
==> default: [[ previous task time: 0:12:01.201807 = 721.20s / 2319.02s ]]
==> default: ok: [localhost] => {
==> default: "var": {
==> default: "provisioner.network.type": "nova"
==> default: }
==> default: }
==> default:
==> default: TASK: [get_nodes/foreman | debug var=nodes_created] ***************************
==> default: [[ previous task time: 0:00:00.010205 = 0.01s / 2319.03s ]]
==> default: skipping: [localhost]
==> default:
==> default: TASK: [get_nodes/foreman | debug var=hostvars] ********************************
==> default: [[ previous task time: 0:00:00.023453 = 0.02s / 2319.06s ]]
==> default: skipping: [localhost]
==> default:
==> default: PLAY RECAP ********************************************************************
==> default: localhost : ok=60 changed=41 unreachable=0 failed=0
==> default: [[ previous task time: 0:00:00.032833 = 0.03s / 2319.09s ]]
==> default: [[ previous play time: 0:26:37.803885 = 1597.80s / 2319.09s ]]
==> default: [[ previous playbook time: 0:38:39.090976 = 2319.09s / 2319.09s ]]
==> default: [[ previous total time: 0:38:39.091181 = 2319.09s / 0.00s ]]
==> default: Exit cleanup ... init.print_result
==> default: running: init.print_result
==> default: ./run.sh: PASSED
==> default: Running provisioner: shell...
default: Running: /tmp/vagrant-shell20150920-11687-22sn6.sh
==> default: Resizing physical volume
==> default: Physical volume "/dev/sda2" changed
==> default: 1 physical volume(s) resized / 0 physical volume(s) not resized
==> default: New physical volume size: 39
==> default: Resizing logical volume
==> default: Extending logical volume root to 38.48 GiB
==> default: Logical volume root successfully resized
==> default: Filesystem resized to: 39G
Foreman VM is up!
[opnfv@jumphost2 ci]$