Commit 0321734d authored by David Johnson's avatar David Johnson

Expose glance/swift LV backing store size params; fix glance lv bugs.

parent c85b9344
......@@ -116,6 +116,12 @@ pc.defineParameter("computeNodeCountSite2", "Number of compute nodes at Site 2",
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.")
pc.defineParameter("swiftLVSize", "Swift Logical Volume Size",
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.")
pc.defineParameter("glanceLVSize", "Glance Logical Volume Size",
portal.ParameterType.INTEGER,4,advanced=True,
longDescription="The necessary space in GB to reserve for a Glance backing store for disk images, 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.")
pc.defineParameter("tempBlockstoreMountPoint", "Temporary Filesystem Mount Point",
portal.ParameterType.STRING,"",advanced=True,
longDescription="Mounts an ephemeral, temporary filesystem at this mount point, on the nodes which you specify below. If you specify no nodes, and specify a mount point here, all nodes will get a temp filesystem. Be careful where you mount it -- something might already be there (i.e., /storage is already taken).")
......@@ -1107,6 +1113,12 @@ class Parameters(RSpec.Resource):
param = ET.SubElement(el,paramXML)
param.text = "OSRELEASE='%s'" % (str(params.release))
param = ET.SubElement(el,paramXML)
param.text = "SWIFT_LV_SIZE=%d" % (int(params.swiftLVSize))
param = ET.SubElement(el,paramXML)
param.text = "GLANCE_LV_SIZE=%d" % (int(params.glanceLVSize))
return el
pass
......
......@@ -930,7 +930,7 @@ if [ -z "${GLANCE_DBPASS}" ]; then
#
# Possibly create a larger image storage space.
#
if [ -n "$GLANCE_EXTRA_SPACE" -a ! $GLANCE_EXTRA_SPACE = 0 ]; then
if [ -n "$GLANCE_LV_SIZE" -a ! $GLANCE_LV_SIZE = 0 ]; then
service_stop glance-registry
service_stop glance-api
......@@ -941,7 +941,7 @@ if [ -z "${GLANCE_DBPASS}" ]; then
chmod 770 ${STORAGEDIR}/glance
if [ $LVM = 1 ]; then
lvcreate -l ${GLANCE_EXTRA_SPACE}G -n glance $VGNAME
lvcreate -L ${GLANCE_LV_SIZE}G -n glance $VGNAME
if [ -f /sbin/mkfs.ext4 ]; then
ftype=ext4
else
......@@ -950,7 +950,7 @@ if [ -z "${GLANCE_DBPASS}" ]; then
mkfs.${ftype} /dev/$VGNAME/glance
echo "/dev/$VGNAME/glance ${STORAGEDIR}/glance none defaults 0 0" \
>> /etc/fstab
mount /dev/$VGNAME/nova ${STORAGEDIR}/glance
mount /dev/$VGNAME/glance ${STORAGEDIR}/glance
fi
rsync -avz /var/lib/glance/ ${STORAGEDIR}/glance/
rm -rf /var/lib/glance/*
......
......@@ -99,7 +99,8 @@ SUPPORT_DYNAMIC_NODES=0
KEYSTONEAPIVERSION=""
TOKENTIMEOUT=14400
SESSIONTIMEOUT=14400
GLANCE_EXTRA_SPACE=32
GLANCE_LV_SIZE=32
SWIFT_LV_SIZE=4
CEILOMETER_USE_WSGI=0
QUOTASOFF=1
# Off by default; seems to cause intermittent keystone unavailability.
......
......@@ -53,10 +53,10 @@ if [ $LVM -eq 0 ] ; then
losetup $LDEV ${STORAGEDIR}/swiftv1-2
LDEVS="${LDEVS} ${LDEV}"
else
lvcreate -n swiftv1 -L 4G $VGNAME
lvcreate -n swiftv1 -L ${SWIFT_LV_SIZE}G $VGNAME
LDEV=/dev/${VGNAME}/swiftv1
LDEVS="${LDEV}"
lvcreate -n swiftv1-2 -L 4G $VGNAME
lvcreate -n swiftv1-2 -L ${SWIFT_LV_SIZE}G $VGNAME
LDEV=/dev/${VGNAME}/swiftv1-2
LDEVS="${LDEVS} ${LDEV}"
fi
......
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