mirror of
https://github.com/myvesta/vesta
synced 2025-08-20 21:34:12 -07:00
intelegent fix for aio on openvz
This commit is contained in:
parent
a93db641c7
commit
1fff552598
1 changed files with 11 additions and 6 deletions
|
@ -522,15 +522,20 @@ else
|
||||||
wget $CHOST/$VERSION/mysql.cnf -O /etc/my.cnf
|
wget $CHOST/$VERSION/mysql.cnf -O /etc/my.cnf
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Disable aio on OpenVZ
|
|
||||||
if [ -e "/proc/user_beancounters" ]; then
|
|
||||||
sed -i "s/#innodb_use_native_aio/innodb_use_native_aio/g" /etc/my.cnf
|
|
||||||
fi
|
|
||||||
chkconfig mysqld on
|
chkconfig mysqld on
|
||||||
service mysqld start
|
service mysqld start
|
||||||
if [ "$?" -ne 0 ]; then
|
if [ "$?" -ne 0 ]; then
|
||||||
echo "Error: mysqld start failed"
|
|
||||||
exit
|
# Fix for aio on OpenVZ
|
||||||
|
if [ -e "/proc/user_beancounters" ]; then
|
||||||
|
sed -i "s/#innodb_use_native_aio/innodb_use_native_aio/g" /etc/my.cnf
|
||||||
|
fi
|
||||||
|
|
||||||
|
service mysqld start
|
||||||
|
if [ "$?" -ne 0 ]; then
|
||||||
|
echo "Error: mysqld start failed"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
mysqladmin -u root password $mpass
|
mysqladmin -u root password $mpass
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue