Install mysql-proxy in yum in centos
Install mysql-proxy on centos
Mysql-proxy is useless. mysql-proxy depends on libevent, lua, glib2, and other software.
So before installation
Yum install lua-develyum install glib2-devel
Libevent I use source code to install,
Downloaded
Libevent-1.4.13-stable.tar.gz
Tar zvfx libevent-1.4.13-stable.tar.gz./configure in makemake install
Now you can install mysql-proxy.
Mysql-proxy
Download source code
Or first
Tar zvfx./configuremakemake checkmake installldconfig
Now you can use mysql-proxy.
For example, our database is at 192.168.1.245 and the local address is 192.168.1.201.
We can do this.
Mysql-proxy-P 192.168.1.201: 3308 -- proxy-backend-addresses = 192.168.1.245: 3306
Connect the client to 192.168.1.201: 3308 to access the database of 245. the user name and password are 245.
Some of them can only be accessed through the Intranet and are not used to command line operations.