mirror of https://github.com/apache/cloudstack.git
alternate way of wrting
This commit is contained in:
parent
7a5b167f90
commit
aceb81ce21
|
|
@ -204,14 +204,11 @@ patch() {
|
|||
|
||||
# set cache back pressure based on amount of physical memory 100 is default
|
||||
physmem=$(free|awk '/^Mem:/{print $2}')
|
||||
case $physmem in
|
||||
[1-4095999])
|
||||
if [ $((physmem)) -lt 409600 ]; then
|
||||
sed -i "/^vm.vfs_cache_pressure/ c\vm.vfs_cache_pressure = 200" /etc/sysctl.conf
|
||||
;;
|
||||
*)
|
||||
else
|
||||
sed -i "/^vm.vfs_cache_pressure/ c\vm.vfs_cache_pressure = 100" /etc/sysctl.conf
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
||||
return 0
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue