MySQL Sandbox is a very simple and quick tool suite for deploying MySQL technology. It allows you to achieve your ultimate goal more quickly and without interference on the same machine. For example, as a software tester, you just need to test The good quality of the software system does not require too much entanglement in the installation of mysql, and does not require too much experience in the MySQL database; sometimes we are just interested in some features of the new version and end the installation and deployment as quickly as possible, but Focus on experiencing some of its features; you can use sandbox to deploy the database application architecture (ReplicationCluster) we need in the shortest time to coordinate with our existing application system for performance testing.
Recommended: "mysql video tutorial"
1. Install cpan
yum install cpan -y
2. Install the packages that the software depends on
yum install perl-Test-Simple -y
3. Install MySQL Sandbox
cpan MySQL::Sandbox
4. Set environment variables (otherwise an error will be thrown)
[root@localhost ~]# echo 'export SANDBOX_AS_ROOT=1' >> /root/.bash_profile [root@localhost ~]# source /root/.bash_profile
5. Download the mysql binary package (I downloaded mysql5.6 here, I suggest you develop it The habit of downloading software packages from the official website, I have already downloaded them here, as follows)
Download link: https://dev.mysql.com/downloads/mysql/
6. In the sandbox environment Run our mysql instance
Start the installation work:
[root@localhost]# make_sandbox mysql-5.6.19-linux-glibc2.5-x86_64.tar.gz
Install multiple instances below:
You can execute make_multiple_sandbox --help to view its usage
The default is 3 nodes, which means three instances
[root@localhost]# make_multiple_sandbox mysql-5.6.19-linux-glibc2.5-x86_64.tar.gz installing node 1 installing node 2 installing node 3
After execution, a multi_msb_mysql-5_6_19 folder will be generated.
The above is the detailed content of How to use MySQL Sandbox to quickly deploy mysql. For more information, please follow other related articles on the PHP Chinese website!