[systembackup] rename functions
This commit is contained in:
parent
962d6c8e39
commit
6a247d72dc
10
systembackup
10
systembackup
@ -11,14 +11,14 @@ if [ "y" == "$MYSQL" ]; then
|
||||
fi
|
||||
}
|
||||
|
||||
mount() {
|
||||
mount_snapshot() {
|
||||
echo "mounting /var/lib/mysql-snapshot..."
|
||||
mkdir -p /var/lib/mysql-snapshot
|
||||
/bin/mount /dev/vg0/mysql-snapshot /var/lib/mysql-snapshot
|
||||
mount /dev/vg0/mysql-snapshot /var/lib/mysql-snapshot
|
||||
echo "mounted /var/lib/mysql-snapshot."
|
||||
}
|
||||
|
||||
lock() {
|
||||
create_snapshot() {
|
||||
echo "locking database..."
|
||||
mysql << EOF
|
||||
FLUSH TABLES;
|
||||
@ -60,8 +60,8 @@ set -e
|
||||
trap cleanup SIGHUP SIGINT SIGTERM
|
||||
|
||||
if [ "y" == "$MYSQL" ]; then
|
||||
lock
|
||||
mount
|
||||
create_snapshot
|
||||
mount_snapshot
|
||||
fi
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user