Network Configuration
Change fabric(租户网)network MTU larger than 1580 bytes
ifconfig em1 mtu 1580
Configure PLUMgrid Services on Gateway nodes
Gateway Configuration
1.Remove openvswitch
rmmod openvswitch
2.安裝相關套件
yum install -y kmod-iovisor-1.0.6_32_g9c1753e-0.3.10.0_327.el7.x86_64.el7.x86_64.rpm
yum install -y plumgrid-lxc-5.2-0.b8.20160902.053233.x86_64.rpm
yum install -y plumgrid-pythonlib-5.2-0.b8.x86_64.rpm
3.Install the PLUMgrid networking module
yum install -y python-pip
pip install networking-plumgrid==2016.1.1.2
NOTE: 你也可以直接到Pypi下載plumgrid-2016.1.1.2.tar.gz 安裝。
4.Enable IPv4 forwarding:
$ sysctl -w net.ipv4.ip_forward=1
5.Edit /etc/sysctl.conf and add the following content to it:
net.ipv4.ip_forward=1
6.Create the file, /etc/sudoers.d/ifc_ctl_sudoers and add the following content to it:
nova ALL=(root) NOPASSWD: /opt/pg/bin/ifc_ctl_pp *
Modify permissions for /etc/sudoers.d/ifc_ctl_sudoers
chown root:root /etc/sudoers.d/ifc_ctl_sudoers
chmod 644 /etc/sudoers.d/ifc_ctl_sudoers
Configure PLUMgrid Services on Gateway nodes
1.Create /var/lib/libvirt/filesystems/plumgrid-data/conf/pg/plumgrid.conf and add the following content:
plumgrid_ip=<Management IP address of PLUMgrid Director>
plumgrid_port=8001
mgmt_dev=<Management Interface>
label=<HOSTNAME OF THE MACHINE>
plumgrid_rsync_port=2222
plumgrid_rest_addr=0.0.0.0:9180
fabric_mode=host
plumgrid_syslog_ng_ip=
plumgrid_syslog_ng_port=
plumgrid_monitor_interval=
start_plumgrid_iovisor=yes
start_plumgrid=`/opt/pg/scripts/pg_is_director.sh $plumgrid_ip`
location=
2.Add hostname of the Gateway node to the file /var/lib/libvirt/filesystems/plumgrid-data/conf/etc/hostname. NOTE: Create the file, if it does not exist. The hostname of the node can be found by running the command.
hostname -f
3.Create the file /var/lib/libvirt/filesystems/plumgrid-data/conf/etc/hosts and add the following content to it:
127.0.0.1 localhost
127.0.1.1 <FQDN> <Hostname>
4.Create the file, /var/lib/libvirt/filesystems/plumgrid-data/conf/pg/ifcs.conf and add the following content to it:
<fabric_interface e.g. br-fabric> = fabric_core host
<external access interface e.g. ens4> = access_phys
5.Restart the PLUMgrid service:
service plumgrid start