MySQL dual-host hot backup is often used in Linux Server lvs load balancing and dual-host hot backup applications. The installation and configuration process is as follows: 1. Install MMySQL # cpmysql
MySQL dual-host hot backup is often used in Linux Server lvs load balancing and dual-host hot backup applications. The installation and configuration process is as follows: 1. Install MMySQL # cp mysql
MySQL dual-host hot backup is often used in Linux Server lvs load balancing and dual-host hot backup applications. The installation and configuration process is as follows:
1. Install MySQL
# Cp mysql-standard-4.1.9-pc-linux-gnu-i686.tar.gz/usr/local/
# Tar zxvf mysql-standard-4.1.9-pc-linux-gnu-i686.tar.gz
# Music mysql-standard-4.1.9-pc-linux-gnu-i686 mysql
# Cd mysql
# More INSTALL-BINARY
Check the installation documentation. Note that the installation is mainly in red.
# Groupadd mysql (create a mysql Group)
# Useradd-g mysql (create a mysql user and add the user to this group)
# Scripts/mysql_install_db -- user = mysql (execute the database initialization and installation script as a mysql user)
# Chown-R root. (The root permission is the current directory)
# Chown-R mysql data (the mysql permission belongs to the data directory)
# Chgrp-R mysql. (The user and group owner who changed the mysql file/directory are the current directory)
# Bin/mysqld_safe -- user = mysql & (start the mysql database process in the background as a mysql user)
Then we can start the mysql database ,,
The figure above indicates that the installation is correct.
To make the database more secure, set the Database Password.
If the mysql database process can be automatically started when the server is started next time, we need to write the/etc/rc. d/rc. local file
Echo "/usr/local/mysql/bin/mysqld_safe -- user = mysql &" >;>;/etc/rc. d/rc. local