cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From r...@apache.org
Subject [1/3] git commit: updated refs/heads/master to b913c88
Date Wed, 19 Aug 2015 15:47:54 GMT
Repository: cloudstack
Updated Branches:
  refs/heads/master e384f2d14 -> b913c881a


fixing white space and formatting


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/14013d5d
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/14013d5d
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/14013d5d

Branch: refs/heads/master
Commit: 14013d5d1b1e802ca06ef29028706cbb54d7af1a
Parents: 72e5502
Author: Remi Bergsma <github@remi.nl>
Authored: Wed Aug 19 16:20:20 2015 +0200
Committer: Remi Bergsma <github@remi.nl>
Committed: Wed Aug 19 16:24:44 2015 +0200

----------------------------------------------------------------------
 scripts/vm/hypervisor/kvm/setup-cgroups.sh | 38 +++++++++++--------------
 1 file changed, 17 insertions(+), 21 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/14013d5d/scripts/vm/hypervisor/kvm/setup-cgroups.sh
----------------------------------------------------------------------
diff --git a/scripts/vm/hypervisor/kvm/setup-cgroups.sh b/scripts/vm/hypervisor/kvm/setup-cgroups.sh
index 4d6e755..d3342c0 100755
--- a/scripts/vm/hypervisor/kvm/setup-cgroups.sh
+++ b/scripts/vm/hypervisor/kvm/setup-cgroups.sh
@@ -6,9 +6,9 @@
 # to you under the Apache License, Version 2.0 (the
 # "License"); you may not use this file except in compliance
 # with the License.  You may obtain a copy of the License at
-# 
+#
 #   http://www.apache.org/licenses/LICENSE-2.0
-# 
+#
 # Unless required by applicable law or agreed to in writing,
 # software distributed under the License is distributed on an
 # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
@@ -21,20 +21,17 @@
 # Script to fix cgroups co-mounted issue
 # Applies to RHEL7 versions only
 # Detect if cpu,cpuacct cgroups are co-mounted
-# If co-mounted, unmount and mount them seperately 
+# If co-mounted, unmount and mount them seperately
 
 #set -x
 
-#Check distribution version for RHEL 
-if [ -f '/etc/redhat-release' ];
-then
-    #Check RHEL version for 7 
-   if grep 'Red Hat Enterprise Linux Server release 7' /etc/redhat-release > /dev/null
-   then
-        # Check if cgroups if co-mounted 
-        if [ -d '/sys/fs/cgroup/cpu,cpuacct' ];
-        then
-   	    # cgroups co-mounted. Requires remount
+# Check distribution version for RHEL
+if [ -f '/etc/redhat-release' ]; then
+    # Check RHEL version for 7
+    if grep 'Red Hat Enterprise Linux Server release 7' /etc/redhat-release > /dev/null;
then
+        # Check if cgroups if co-mounted
+        if [ -d '/sys/fs/cgroup/cpu,cpuacct' ]; then
+            # cgroups co-mounted. Requires remount
             umount /sys/fs/cgroup/cpu,cpuacct
             rm /sys/fs/cgroup/cpu
             rm /sys/fs/cgroup/cpuacct
@@ -43,14 +40,13 @@ then
             mkdir -p /sys/fs/cgroup/cpuacct
             mount -t cgroup -o cpu cpu "/sys/fs/cgroup/cpu"
             mount -t cgroup -o cpuacct cpuacct "/sys/fs/cgroup/cpuacct"
-            # Verify that cgroups are not co-mounted 
-            if [ -d '/sys/fs/cgroup/cpu,cpuacct' ];
-            then
-   	        echo "cgroups still co-mounted"
-		exit 1;
-	    fi
-	fi    
-   fi
+            # Verify that cgroups are not co-mounted
+            if [ -d '/sys/fs/cgroup/cpu,cpuacct' ]; then
+               echo "cgroups still co-mounted"
+               exit 1;
+            fi
+        fi
+    fi
 fi
 
 exit 0


Mime
View raw message