All new accounts created on Gitlab now require administrator approval. If you invite any collaborators, please let Flux staff know so they can approve the accounts.

Commit 40c954ce authored by David Johnson's avatar David Johnson

Merge remote-tracking branch 'origin/master' into stein

parents e31e6bf3 e7157690
...@@ -126,7 +126,14 @@ pc.defineParameter("sharedVlanAddress","Shared VLAN IP Address", ...@@ -126,7 +126,14 @@ pc.defineParameter("sharedVlanAddress","Shared VLAN IP Address",
pc.defineParameter("computeNodeCountSite2", "Number of compute nodes at Site 2", pc.defineParameter("computeNodeCountSite2", "Number of compute nodes at Site 2",
portal.ParameterType.INTEGER, 0,advanced=True, portal.ParameterType.INTEGER, 0,advanced=True,
longDescription="You can add additional compute nodes from other CloudLab clusters, allowing you to experiment with remote VMs controlled from the central controller at the first site.") longDescription="You can add additional compute nodes from other CloudLab clusters, allowing you to experiment with remote VMs controlled from the central controller at the first site.")
pc.defineParameter("osNodeTypeSite2", "Site 2 Hardware Type",
portal.ParameterType.NODETYPE, "",
longDescription="A specific hardware type to use for each node at Site 2. Cloudlab clusters all have machines of specific types. When you set this field to a value that is a specific hardware type, you will only be able to instantiate this profile on clusters with machines of that type. If unset, when you instantiate the profile, the resulting experiment may have machines of any available type allocated.",
advanced=True)
pc.defineParameter("resizeRoot","Resize Root Filesystem",
portal.ParameterType.STRING,"",advanced=True,
longDescription="If set to 0 or integer, this will expand your root filesystem on each node. In order to make the expansion possible, the swap and other unused partitions will be deleted. If you set this parameter to 0, the maximum amount of space on the device hosting the root filesystem will be used. If set to integer >0, your root filesystem will be expanding to that size in GB. Do not append a postfix; even if you do, it will be ignored and the integer value will be interpreted in GB.")
pc.defineParameter("swiftLVSize", "Swift Logical Volume Size", pc.defineParameter("swiftLVSize", "Swift Logical Volume Size",
portal.ParameterType.INTEGER,4,advanced=True, portal.ParameterType.INTEGER,4,advanced=True,
longDescription="The necessary space in GB to reserve for each of two Swift backing store volumes, when it is possible to use logical volumes. Nearly all Cloudlab machines do support logical volumes. Ensure that the total disk space requested (20GB root + 2x Swift LV size + 1x Glance LV size) is less than the total disk space available on the node type you want to run on.") longDescription="The necessary space in GB to reserve for each of two Swift backing store volumes, when it is possible to use logical volumes. Nearly all Cloudlab machines do support logical volumes. Ensure that the total disk space requested (20GB root + 2x Swift LV size + 1x Glance LV size) is less than the total disk space available on the node type you want to run on.")
...@@ -840,7 +847,14 @@ if params.controllerHost != params.networkManagerHost: ...@@ -840,7 +847,14 @@ if params.controllerHost != params.networkManagerHost:
if params.networkManagerDiskImage: if params.networkManagerDiskImage:
networkManager.disk_image = params.networkManagerDiskImage networkManager.disk_image = params.networkManagerDiskImage
else: else:
networkManager.disk_image = "urn:publicid:IDN+%s+image+%s//%s%s%s" % (image_urn,image_project,image_os,image_tag_nm,image_tag_rel) nmreltag = image_tag_rel
# If we don't have an image tag, or we are using a standard
# image, there will be no release tag either. The latter case
# is possible because we no longer build OSNM images for >=
# Rocky.
if image_tag_nm == '' or image_tag_nm == '-STD':
nmreltag = ''
networkManager.disk_image = "urn:publicid:IDN+%s+image+%s//%s%s%s" % (image_urn,image_project,image_os,image_tag_nm,nmreltag)
if firewalling and setfwdesire: if firewalling and setfwdesire:
networkManager.Desire('firewallable','1.0') networkManager.Desire('firewallable','1.0')
i = 0 i = 0
...@@ -901,9 +915,10 @@ for (siteNumber,cpnameList) in computeNodeNamesBySite.iteritems(): ...@@ -901,9 +915,10 @@ for (siteNumber,cpnameList) in computeNodeNamesBySite.iteritems():
for cpname in cpnameList: for cpname in cpnameList:
cpnode = RSpec.RawPC(cpname) cpnode = RSpec.RawPC(cpname)
nodes[cpname] = cpnode nodes[cpname] = cpnode
if params.osNodeType: if params.osNodeType and siteNumber == 1:
cpnode.hardware_type = params.osNodeType cpnode.hardware_type = params.osNodeType
pass elif params.osNodeTypeSite2 and siteNumber == 2:
cpnode.hardware_type = params.osNodeTypeSite2
cpnode.Site(str(siteNumber)) cpnode.Site(str(siteNumber))
if params.computeDiskImage: if params.computeDiskImage:
cpnode.disk_image = params.computeDiskImage cpnode.disk_image = params.computeDiskImage
...@@ -1190,6 +1205,9 @@ class Parameters(RSpec.Resource): ...@@ -1190,6 +1205,9 @@ class Parameters(RSpec.Resource):
param = ET.SubElement(el,paramXML) param = ET.SubElement(el,paramXML)
param.text = "GLANCE_LV_SIZE=%d" % (int(params.glanceLVSize)) param.text = "GLANCE_LV_SIZE=%d" % (int(params.glanceLVSize))
param = ET.SubElement(el,paramXML)
param.text = "RESIZEROOT=%s" % (params.resizeRoot)
return el return el
pass pass
......
...@@ -83,7 +83,7 @@ if [ $? -eq 0 -a "$COMPUTE_EXTRA_NOVA_DISK_SPACE" = "1" ]; then ...@@ -83,7 +83,7 @@ if [ $? -eq 0 -a "$COMPUTE_EXTRA_NOVA_DISK_SPACE" = "1" ]; then
mkfs.ext3 /dev/$VGNAME/nova mkfs.ext3 /dev/$VGNAME/nova
fi fi
mkdir -p /mnt/var-lib-nova mkdir -p /mnt/var-lib-nova
echo "/dev/$VGNAME/nova /mnt/var-lib-nova none defaults,bind 0 0" \ echo "/dev/$VGNAME/nova /mnt/var-lib-nova none defaults 0 0" \
>> /etc/fstab >> /etc/fstab
mount /dev/$VGNAME/nova /mnt/var-lib-nova mount /dev/$VGNAME/nova /mnt/var-lib-nova
chown nova:nova /mnt/var-lib-nova chown nova:nova /mnt/var-lib-nova
...@@ -108,7 +108,7 @@ elif [ "$COMPUTE_EXTRA_NOVA_DISK_SPACE" = "1" ]; then ...@@ -108,7 +108,7 @@ elif [ "$COMPUTE_EXTRA_NOVA_DISK_SPACE" = "1" ]; then
mkfs.ext3 /dev/$VGNAME/nova mkfs.ext3 /dev/$VGNAME/nova
fi fi
mkdir -p /mnt/var-lib-nova mkdir -p /mnt/var-lib-nova
echo "/dev/$VGNAME/nova /mnt/var-lib-nova none defaults,bind 0 0" \ echo "/dev/$VGNAME/nova /mnt/var-lib-nova none defaults 0 0" \
>> /etc/fstab >> /etc/fstab
mount /dev/$VGNAME/nova /mnt/var-lib-nova mount /dev/$VGNAME/nova /mnt/var-lib-nova
chown nova:nova /mnt/var-lib-nova chown nova:nova /mnt/var-lib-nova
......
...@@ -352,7 +352,7 @@ EOF ...@@ -352,7 +352,7 @@ EOF
chmod 750 /etc/etcd chmod 750 /etc/etcd
else else
cat <<EOF >/etc/default/etcd cat <<EOF >/etc/default/etcd
ETCD_NAME="controller" ETCD_NAME="$CONTROLLER"
ETCD_DATA_DIR="/var/lib/etcd" ETCD_DATA_DIR="/var/lib/etcd"
ETCD_INITIAL_CLUSTER_STATE="new" ETCD_INITIAL_CLUSTER_STATE="new"
ETCD_INITIAL_CLUSTER_TOKEN="etcd-cluster-01" ETCD_INITIAL_CLUSTER_TOKEN="etcd-cluster-01"
...@@ -382,13 +382,14 @@ if [ -z "${KEYSTONE_DBPASS}" ]; then ...@@ -382,13 +382,14 @@ if [ -z "${KEYSTONE_DBPASS}" ]; then
echo "grant all privileges on keystone.* to 'keystone'@'%' identified by '$KEYSTONE_DBPASS'" | mysql -u root --password="$DB_ROOT_PASS" echo "grant all privileges on keystone.* to 'keystone'@'%' identified by '$KEYSTONE_DBPASS'" | mysql -u root --password="$DB_ROOT_PASS"
maybe_install_packages keystone ${PYPKGPREFIX}-keystoneclient maybe_install_packages keystone ${PYPKGPREFIX}-keystoneclient
if [ $OSVERSION -ge $OSKILO ]; then if [ $OSVERSION -ge $OSKILO -o $KEYSTONEUSEWSGI -eq 1 ]; then
maybe_install_packages apache2 maybe_install_packages apache2
if [ $ISPYTHON3 -eq 1 ]; then if [ $ISPYTHON3 -eq 1 ]; then
maybe_install_packages libapache2-mod-wsgi-py3 maybe_install_packages libapache2-mod-wsgi-py3
else else
maybe_install_packages libapache2-mod-wsgi maybe_install_packages libapache2-mod-wsgi
fi fi
a2enmod wsgi
fi fi
ADMIN_TOKEN=`$PSWDGEN` ADMIN_TOKEN=`$PSWDGEN`
...@@ -581,6 +582,7 @@ EOF ...@@ -581,6 +582,7 @@ EOF
ln -s /etc/apache2/mods-available/wsgi.load \ ln -s /etc/apache2/mods-available/wsgi.load \
/etc/apache2/mods-enabled/ /etc/apache2/mods-enabled/
fi fi
a2ensite keystone
fi fi
if [ $OSVERSION -le $OSJUNO -o $KEYSTONEUSEWSGI -eq 0 ]; then if [ $OSVERSION -le $OSJUNO -o $KEYSTONEUSEWSGI -eq 0 ]; then
...@@ -1249,6 +1251,13 @@ EOF ...@@ -1249,6 +1251,13 @@ EOF
crudini --set /etc/nova/nova.conf vnc server_listen ${MGMTIP} crudini --set /etc/nova/nova.conf vnc server_listen ${MGMTIP}
crudini --set /etc/nova/nova.conf vnc server_proxyclient_address ${MGMTIP} crudini --set /etc/nova/nova.conf vnc server_proxyclient_address ${MGMTIP}
fi fi
#
# consoleauth is being deprecated as of Rocky.
#
# https://docs.openstack.org/nova/rocky/configuration/config.html#workarounds.enable_consoleauth
if [ $OSVERSION -ge $OSROCKY ]; then
crudini --set /etc/nova/nova.conf workarounds enable_consoleauth true
fi
# #
# Apparently on Kilo and before, the default filters did not include # Apparently on Kilo and before, the default filters did not include
...@@ -1653,6 +1662,8 @@ if [ -z "${NEUTRON_DBPASS}" ]; then ...@@ -1653,6 +1662,8 @@ if [ -z "${NEUTRON_DBPASS}" ]; then
if [ $OSVERSION -ge $OSROCKY ]; then if [ $OSVERSION -ge $OSROCKY ]; then
crudini --set /etc/neutron/neutron.conf oslo_concurrency \ crudini --set /etc/neutron/neutron.conf oslo_concurrency \
lock_path /var/lib/neutron/lock lock_path /var/lib/neutron/lock
crudini --set /etc/neutron/neutron.conf DEFAULT \
lock_path /var/lib/neutron/lock
mkdir -p /var/lib/neutron/lock/ mkdir -p /var/lib/neutron/lock/
chown neutron:neutron /var/lib/neutron/lock chown neutron:neutron /var/lib/neutron/lock
fi fi
......
...@@ -22,12 +22,15 @@ fi ...@@ -22,12 +22,15 @@ fi
# Setup nginx to show our setup/config directory. # Setup nginx to show our setup/config directory.
# #
if [ "$HOSTNAME" = "$CONTROLLER" ]; then if [ "$HOSTNAME" = "$CONTROLLER" ]; then
ngfailed=0
maybe_install_packages nginx maybe_install_packages nginx
ngfailed=$?
# Always remove default nginx site-enabled file, since apache must # Always remove default nginx site-enabled file, since apache must
# listen on port 80. But if apache2 ran prior to nginx, nginx # listen on port 80. But if apache2 ran prior to nginx, nginx
# install may have failed; if so, remove its default enabled site. # install may have failed; if so, remove its default enabled site.
if [ ! $? -eq 0 ]; then rm -f /etc/nginx/sites-available/default \
rm -f /etc/nginx/sites-enabled/default /etc/nginx/sites-enabled/default
if [ ! $ngfailed -eq 0 ]; then
maybe_install_packages nginx maybe_install_packages nginx
fi fi
rm -f /etc/nginx/sites-enabled/default rm -f /etc/nginx/sites-enabled/default
...@@ -61,6 +64,11 @@ EOF ...@@ -61,6 +64,11 @@ EOF
fi fi
logtstart "driver" logtstart "driver"
#
# Maybe expand the rootfs.
#
$DIRNAME/setup-grow-rootfs.sh 1> $OURDIR/setup-grow-rootfs.log 2>&1
# Copy our source code into $OURDIR for future use: # Copy our source code into $OURDIR for future use:
echo "*** Copying source code into $OURDIR/bin ..." echo "*** Copying source code into $OURDIR/bin ..."
mkdir -p $OURDIR/bin mkdir -p $OURDIR/bin
......
#!/bin/sh
#
# If user wants to resize the rootfs to the max, try to do that.
#
set -x
if [ $EUID -ne 0 ] ; then
echo "This script must be run as root" 1>&2
exit 1
fi
# Grab our libs
. "`dirname $0`/setup-lib.sh"
logtstart "grow-rootfs"
if [ -z "$RESIZEROOT" ]; then
logtend "grow-rootfs"
exit 0
fi
if [ -z "$IMPOTENT" ]; then
IMPOTENT=0
fi
if [ -z "$NODELETE" ]; then
NODELETE=0
fi
# Remove any existing temp files.
rm -fv /tmp/sfdisk.orig /tmp/sfdisk.new /tmp/sfdisk.new \
/tmp/sfdisk.nextstart /tmp/sfdisk.parts-to-delete
# Find the root partition's parent disk.
eval `lsblk -n -P -b -o NAME,FSTYPE,MOUNTPOINT,PARTTYPE,PARTUUID,TYPE,PKNAME,SIZE | grep 'MOUNTPOINT="/"'`
ROOTPARENT=$PKNAME
ROOT=$NAME
if [ -z "$ROOTPARENT" -o -z "$ROOT" ]; then
echo "ERROR: unable to find root device or root parent disk; aborting!"
exit 1
fi
# Find root partition number.
ROOTPARTNO=`echo "$ROOT" | sed -ne "s/^${ROOTPARENT}p\([0-9]*\)$/\1/p"`
if [ ! $? -eq 0 -o -z "$ROOTPARTNO" ]; then
ROOTPARTNO=`echo "$NAME" | sed -ne "s/^${ROOTPARENT}\([0-9]*\)$/\1/p"`
fi
if [ -z "$ROOTPARTNO" ]; then
echo "ERROR: could not determine the root partition number; aborting!"
exit 1
fi
# Save off the original partition table, and create a new one to modify.
sfdisk -d /dev/$ROOTPARENT > /tmp/sfdisk.orig
cp -p /tmp/sfdisk.orig /tmp/sfdisk.new
if [ $NODELETE -eq 0 ]; then
# Swapoff all swap devices if we are not impotent; they will be
# removed.
for dev in `blkid -t TYPE=swap | cut -d: -f1 | xargs` ; do
if [ ! $IMPOTENT -eq 1 ]; then
swapoff $dev
if [ ! $? -eq 0 ]; then
echo "ERROR: failed to swapoff $dev; aborting!"
exit 1
fi
fi
done
# Figure out which partitions to remove. We remove any partition on
# the rootparent with FSTYPE="" and MOUNTPOINT="" and
# PARTUUID=(0fc63daf-8483-4772-8e79-3d69d8477de4|00000000-0000-0000-0000-000000000000|0657FD6D-A4AB-43C4-84E5-0933C84B4F4F|0x83|0x82|0x0).
PARTS=""
lsblk -a -n -P -b -o NAME,FSTYPE,MOUNTPOINT,PARTTYPE,PARTUUID,TYPE,PKNAME,SIZE | grep "PKNAME=\"${ROOTPARENT}\"" | while read line ; do
eval "$line"
if [ "$FSTYPE" != swap -a \( -n "$FSTYPE" -o -n "$MOUNTPOINT" \) ]; then
continue
fi
echo "$PARTTYPE" | grep -qEi '^(0fc63daf-8483-4772-8e79-3d69d8477de4|00000000-0000-0000-0000-000000000000|0657FD6D-A4AB-43C4-84E5-0933C84B4F4F|0x83|0x82|0x0)$'
if [ ! $? -eq 0 ]; then
continue
fi
# Now extract the partition number (to feed to parted). Partition
# number is not reported by most Linux tools nor by sysfs, so we
# have to extract via regexp. Right now we only worry about nvme
# devices (or any device that ends with a "p\d+"), and assume that
# anything else is "standard".
PARTNO=`echo "$NAME" | sed -ne "s/^${PKNAME}p\([0-9]*\)$/\1/p"`
if [ ! $? -eq 0 -o -z "$PARTNO" ]; then
PARTNO=`echo "$NAME" | sed -ne "s/^${PKNAME}\([0-9]*\)$/\1/p"`
fi
if [ ! $? -eq 0 -o -z "$PARTNO" ]; then
continue
fi
PARTS="$PARTNO $PARTS"
echo $PARTNO >> /tmp/sfdisk.parts-to-delete
done
if [ -e /tmp/sfdisk.parts-to-delete ]; then
PARTS=`cat /tmp/sfdisk.parts-to-delete | xargs`
rm -f /tmp/sfdisk.tmp
cat /tmp/sfdisk.new | while read line ; do
delete=0
for part in $PARTS ; do
echo "$line" | grep -q "^/dev/${ROOTPARENT}$part :"
if [ $? -eq 0 ]; then
delete=1
break
fi
done
if [ $delete -eq 0 ]; then
echo "$line" >> /tmp/sfdisk.tmp
fi
done
diff -u /tmp/sfdisk.new /tmp/sfdisk.tmp
mv /tmp/sfdisk.tmp /tmp/sfdisk.new
fi
fi
#
# Now we need to figure out the max sector we can end on. If there is a
# partition further up the disk, we can't stomp it.
#
DISKSIZE=`sfdisk -l /dev/$ROOTPARENT | sed -ne 's/^Disk.*, \([0-9]*\) sectors$/\1/p'`
ROOTSTART=`sfdisk -l -o device,start,end /dev/$ROOTPARENT | sed -ne "s|/dev/${ROOT} *\([0-9]*\) *\([0-9]*\)$|\1|p"`
ROOTEND=`sfdisk -l -o device,start,end /dev/$ROOTPARENT | sed -ne "s|/dev/${ROOT} *\([0-9]*\) *\([0-9]*\)$|\2|p"`
ROOTSIZE=`expr $ROOTEND - $ROOTSTART + 1`
# First, we find the max size of the new root partition in sectors. If
# we find a partition with a start greater than ROOTEND, that value -
# 2048 is the new end. Otherwise, it is DISKSIZE - 2048.
nextstart=$DISKSIZE
cat /tmp/sfdisk.new | grep "^/dev" | while read line ; do
nstart=`echo $line | sed -ne "s|/dev/[^ ]* *: *start= *\([0-9]*\),.*$|\1|p"`
if [ -z "$nstart" ] ; then
continue
fi
if [ $nstart -gt $ROOTSTART -a $nstart -lt $nextstart ]; then
nextstart=$nstart
echo $nextstart > /tmp/sfdisk.nextstart
fi
done
if [ -e /tmp/sfdisk.nextstart -a -s /tmp/sfdisk.nextstart ]; then
nextstart=`cat /tmp/sfdisk.nextstart`
fi
align=0
if [ ! `expr $nextstart \% 2048` -eq 0 ]; then
align=2048
fi
maxsize=`expr $nextstart - $align - $ROOTSTART`
# Sanitize the size. We only support GB.
RESIZEROOT=`echo "$RESIZEROOT" | sed -ne 's/^\([0-9]*\)[^0-9]*$/\1/p'`
if [ -z "$RESIZEROOT" ]; then
echo "ERROR: could not determine size of root disk $ROOTPARENT; aborting!"
exit 1
fi
if [ $RESIZEROOT -eq 0 ]; then
newsize=$maxsize
else
usersectors=`expr $RESIZEROOT \* 1024 \* 1024 \* 1024 / 512`
if [ $usersectors -gt $maxsize ]; then
newsize=$maxsize
else
newsize=$usersectors
fi
fi
if [ -z "$newsize" ]; then
echo "ERROR: failed to calculate new root partition size; aborting!"
exit 1
fi
if [ $newsize -eq $ROOTSIZE ]; then
echo "Nothing to do: newsize ($newsize) same as current root size ($ROOTSIZE)."
exit 0
fi
if [ $newsize -lt $ROOTSIZE ]; then
echo "ERROR: newsize ($newsize) less than current root size ($ROOTSIZE); aborting!"
exit 1
fi
if [ $newsize -lt 2048 ]; then
echo "WARNING: cannot expand root partition; skipping!"
exit 0
fi
# Finally, edit the sfdisk.new file to change the root device's size.
cat /tmp/sfdisk.new | while read line ; do
echo "$line" | grep -q "^/dev/${ROOT} :"
if [ $? -eq 0 ]; then
echo "$line" | sed -e "s|^\(/dev/${ROOT} :.*\)\(size= *[0-9]*,\)\(.*\)$|\1size=${newsize}\3|" >> /tmp/sfdisk.tmp
else
echo "$line" >> /tmp/sfdisk.tmp
fi
done
mv /tmp/sfdisk.tmp /tmp/sfdisk.new
diff -u /tmp/sfdisk.orig /tmp/sfdisk.new
if [ $IMPOTENT -eq 1 ]; then
exit 0
fi
sfdisk --force /dev/$ROOTPARENT < /tmp/sfdisk.new
partprobe /dev/$ROOTPARENT
resize2fs /dev/$ROOT
if [ ! $? -eq 0 ]; then
echo "ERROR: failed to resize /dev/$ROOT filesystem; aborting!"
exit 1
fi
echo "Resized /dev/$ROOT."
logtend "grow-rootfs"
exit 0
...@@ -127,6 +127,11 @@ USE_NEUTRON_LBAAS=1 ...@@ -127,6 +127,11 @@ USE_NEUTRON_LBAAS=1
ENABLE_OPENSTACK_SLOTHD=0 ENABLE_OPENSTACK_SLOTHD=0
# The input OpenStack release, if any, from profile params. # The input OpenStack release, if any, from profile params.
OSRELEASE="" OSRELEASE=""
# If "", no resizing. If set to number, that is GB. Even if you
# specify MB, the MB will be stripped and assumed to be GB. If set to
# 0, the max amount of space after removing swap and extra partitions
# will be used.
RESIZEROOT=""
# #
# We have an 'adminapi' user that gets a random password. Then, we have # We have an 'adminapi' user that gets a random password. Then, we have
......
...@@ -115,7 +115,7 @@ iface ${EXTERNAL_NETWORK_BRIDGE} inet static ...@@ -115,7 +115,7 @@ iface ${EXTERNAL_NETWORK_BRIDGE} inet static
dns-search $DNSDOMAIN dns-search $DNSDOMAIN
dns-nameservers $DNSSERVER dns-nameservers $DNSSERVER
up echo "${EXTERNAL_NETWORK_BRIDGE}" > /var/run/cnet up echo "${EXTERNAL_NETWORK_BRIDGE}" > /var/run/cnet
up echo "${EXTERNAL_NETWORK_BRIDGE}" > /var/emulab/boot/controlif up echo "${EXTERNAL_NETWORK_INTERFACE}" > /var/emulab/boot/controlif
EOF EOF
else else
mv /etc/udev/rules.d/99-emulab-networkd.rules \ mv /etc/udev/rules.d/99-emulab-networkd.rules \
...@@ -149,7 +149,7 @@ EOF ...@@ -149,7 +149,7 @@ EOF
# that were previously done in /etc/network/interfaces via "up" hook. # that were previously done in /etc/network/interfaces via "up" hook.
# #
echo "${EXTERNAL_NETWORK_BRIDGE}" > /var/run/cnet echo "${EXTERNAL_NETWORK_BRIDGE}" > /var/run/cnet
echo "${EXTERNAL_NETWORK_BRIDGE}" > /var/emulab/boot/controlif echo "${EXTERNAL_NETWORK_INTERFACE}" > /var/emulab/boot/controlif
EOF EOF
chmod 755 $OURDIR/testbed-pre-static-control-network.sh chmod 755 $OURDIR/testbed-pre-static-control-network.sh
systemctl daemon-reload systemctl daemon-reload
...@@ -182,7 +182,7 @@ fi ...@@ -182,7 +182,7 @@ fi
# Also restart slothd so it listens on the new control iface. # Also restart slothd so it listens on the new control iface.
echo "${EXTERNAL_NETWORK_BRIDGE}" > /var/run/cnet echo "${EXTERNAL_NETWORK_BRIDGE}" > /var/run/cnet
echo "${EXTERNAL_NETWORK_BRIDGE}" > /var/emulab/boot/controlif echo "${EXTERNAL_NETWORK_INTERFACE}" > /var/emulab/boot/controlif
/usr/local/etc/emulab/rc/rc.slothd stop /usr/local/etc/emulab/rc/rc.slothd stop
pkill slothd pkill slothd
sleep 1 sleep 1
......
...@@ -60,6 +60,8 @@ fi ...@@ -60,6 +60,8 @@ fi
if [ $OSVERSION -eq $OSROCKY ]; then if [ $OSVERSION -eq $OSROCKY ]; then
crudini --set /etc/neutron/neutron.conf oslo_concurrency \ crudini --set /etc/neutron/neutron.conf oslo_concurrency \
lock_path /var/lib/neutron/lock lock_path /var/lib/neutron/lock
crudini --set /etc/neutron/neutron.conf DEFAULT \
lock_path /var/lib/neutron/lock
mkdir -p /var/lib/neutron/lock/ mkdir -p /var/lib/neutron/lock/
chown neutron:neutron /var/lib/neutron/lock chown neutron:neutron /var/lib/neutron/lock
fi fi
......
...@@ -126,7 +126,7 @@ iface ${EXTERNAL_NETWORK_BRIDGE} inet static ...@@ -126,7 +126,7 @@ iface ${EXTERNAL_NETWORK_BRIDGE} inet static
dns-search $DNSDOMAIN dns-search $DNSDOMAIN
dns-nameservers $DNSSERVER dns-nameservers $DNSSERVER
up echo "${EXTERNAL_NETWORK_BRIDGE}" > /var/run/cnet up echo "${EXTERNAL_NETWORK_BRIDGE}" > /var/run/cnet
up echo "${EXTERNAL_NETWORK_BRIDGE}" > /var/emulab/boot/controlif up echo "${EXTERNAL_NETWORK_INTERFACE}" > /var/emulab/boot/controlif
$readdflows $readdflows
auto ${EXTERNAL_NETWORK_INTERFACE} auto ${EXTERNAL_NETWORK_INTERFACE}
...@@ -165,7 +165,7 @@ EOF ...@@ -165,7 +165,7 @@ EOF
# that were previously done in /etc/network/interfaces via "up" hook. # that were previously done in /etc/network/interfaces via "up" hook.
# #
echo "${EXTERNAL_NETWORK_BRIDGE}" > /var/run/cnet echo "${EXTERNAL_NETWORK_BRIDGE}" > /var/run/cnet
echo "${EXTERNAL_NETWORK_BRIDGE}" > /var/emulab/boot/controlif echo "${EXTERNAL_NETWORK_INTERFACE}" > /var/emulab/boot/controlif
EOF EOF
chmod 755 $OURDIR/testbed-pre-static-control-network.sh chmod 755 $OURDIR/testbed-pre-static-control-network.sh
systemctl daemon-reload systemctl daemon-reload
...@@ -223,7 +223,7 @@ service_restart openvswitch-switch ...@@ -223,7 +223,7 @@ service_restart openvswitch-switch
# Also restart slothd so it listens on the new control iface. # Also restart slothd so it listens on the new control iface.
echo "${EXTERNAL_NETWORK_BRIDGE}" > /var/run/cnet echo "${EXTERNAL_NETWORK_BRIDGE}" > /var/run/cnet
echo "${EXTERNAL_NETWORK_BRIDGE}" > /var/emulab/boot/controlif echo "${EXTERNAL_NETWORK_INTERFACE}" > /var/emulab/boot/controlif
/usr/local/etc/emulab/rc/rc.slothd stop /usr/local/etc/emulab/rc/rc.slothd stop
pkill slothd pkill slothd
sleep 1 sleep 1
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment