summaryrefslogtreecommitdiffstats
path: root/os-plugins/plugins/vmgrid/XX_vmgrid.sh
diff options
context:
space:
mode:
Diffstat (limited to 'os-plugins/plugins/vmgrid/XX_vmgrid.sh')
-rw-r--r--os-plugins/plugins/vmgrid/XX_vmgrid.sh24
1 files changed, 2 insertions, 22 deletions
diff --git a/os-plugins/plugins/vmgrid/XX_vmgrid.sh b/os-plugins/plugins/vmgrid/XX_vmgrid.sh
index d9e35dfb..1d0c76be 100644
--- a/os-plugins/plugins/vmgrid/XX_vmgrid.sh
+++ b/os-plugins/plugins/vmgrid/XX_vmgrid.sh
@@ -96,29 +96,9 @@ if [ -f $CONFFILE ]; then
chmod 1777 ${RWSHARE}
echo "vmgrid_rwmnt=${RWSHARE#/mnt}" >> ${PLUGINCONFDIR}/vmgrid.conf
- # virtual virtualization plugin
- testmkd ${VIRTUALIZATIONPLUGIN}
- totalmemtest=$(expr $(echo ${vmgrid_memratio} \
- | awk -F ',' '{print $1" + "$2" + "$3" + "$4" + "$5" + "$6}'))
- totalmem=$(expr $(grep -i "memtotal" /proc/meminfo \
- | awk '{print $2}') / 1024)
- if [ ${totalmemtest} -le 100 2>/dev/null ]; then
- # get hostmem
- freememper=$(expr 100 - $(echo ${vmgrid_memratio} \
- | awk -F ',' '{print $1" - "$2" - "$3" - "$4}'))
- freemem=$(expr ${totalmem} \* ${freememper} / 100)
- echo "virt_freemem=${freemem}" \
- >> ${VIRTUALIZATIONPLUGIN}/virtualization.conf
- else
- # more than 100% memory assigned stupid!
- # vmgrid will get this as well and exit!
- # so we have theoretically 100% free
- echo "virt_freemem=${totalmem}" \
- >> ${VIRTUALIZATIONPLUGIN}/virtualization.conf
- fi
-
# finished ...
[ $DEBUGLEVEL -gt 0 ] && echo "done with 'vmgrid' os-plugin ..."
fi
-[ $DEBUGLEVEL -gt 0 ] && echo " * configuration of 'vmgrid' os-plugin failed"
+else
+ [ $DEBUGLEVEL -gt 0 ] && echo " * configuration of 'vmgrid' os-plugin failed"
fi