Today in the use of MySQL-Proxy0.8.3 test read and write separation, the function is normal, but there are some people some confusing prompt information, not sure that the calculation is not abnormal ...... Configuration File "usrlocalmysql-pro
Today in the use of MySQL-Proxy0.8.3 test read and write separation, the function is normal, but there are some people some confusing prompt information, not sure that the calculation is not abnormal ...... Configuration File "/usr/local/mysql-pro
Today, when MySQL-Proxy 0.8.3 is used to test read/write splitting, all functions are normal, but some confusing information is displayed,
Not sure. Not an exception ......
The configuration file "/usr/local/mysql-proxy/etc/mysql-proxy.cnf" is as follows:
[Mysql-proxy] basedir =/usr/local/mysql-proxydaemon = truekeepalive = trueproxy-address = 0.0.0.0: 3306max-open-files = folder = trueevent-threads = packages = 10.222.5.packages: links = links: 3306plugin-dir =/usr/local/mysql-proxy/lib/mysql-proxy/pluginsplugins = admin, proxyadmin-lua-script =/usr/local/mysql-proxy/lib/mysql-proxy/lua/admin. luaproxy-lua-script =/usr/local/mysql-proxy/lib/mysql-proxy/lua/rw-splitting.luaadmin-address = 10.209.6.102: 3307admin-username = rootadmin-password = 123456pid-file =/usr/local/mysql-proxy/run/mysql-proxy.pidlog-file =/usr/local/mysql-proxy/log/mysql-proxy.loglog-level = warning
:
#! /Bin/sh # mysql-proxy This script starts and stops the mysql-proxy daemon # chkconfig:-78 30 # processname: mysql-proxy # description: mysql-proxy is a proxy daemon to mysql # config:/usr/local/mysql-proxy/etc/mysql-proxy.cnf # pidfile: /usr/local/mysql-proxy/run/mysql-proxy.pid # PATH =/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin: /usr/binDAEMON = "/usr/local/mysql-proxy/bin/mysql-proxy" CONFIGFILE = "/Usr/local/mysql-proxy/etc/mysql-proxy.cnf" PIDFILE = "/usr/local/mysql-proxy/run/mysql-proxy.pid" LOCKFILE = "/var/lock/subsys /mysql-proxy "PROG = 'basename $ DAEMON 'RETVAL = 0 start () {echo-n $ "Starting $ {PROG }...... "[-x $ DAEMON] | exit 5 [-f $ CONFIGFILE] | exit 6 $ {DAEMON} -- defaults-file =$ {CONFIGFILE} | echo-n" $ {PROG} already running "RETVAL = $? Echo [[$ RETVAL-eq 0] & touch $ LOCKFILEreturn $ RETVAL} stop () {echo-n $ "Stopping $ {PROG }...... "if [['ps aux | grep bin/mysql-proxy | grep-v grep | wc-l'-gt 0]; thenkill-TERM 'ps-A-oppid, pid, cmd | grep bin/mysql-proxy | grep-v grep | awk '{print $2} ''fiRETVAL =$? Echo [[$ RETVAL-eq 0] & rm-f $ LOCKFILE $ PIDFILEreturn $ RETVAL} restart () {stopsleep 1 start} case "$1" instart) start ;; stop) stop; restart) restart; condrestart) [[-e $ LOCKFILE] & restart; *) echo "Usage: $0 {start | stop | restart | condrestart} "RETVAL = 1; esacexit $ RETVAL
WIFSIGNALED (status)
Returns true if the child process exited because of a signal which was not caught.
That is to say, if the sub-process exits because the sub-process fails to capture the signal normally, true is returned.
For more details, refer to here (Daemon and Keepalive for server development ):
Currently, we are not sure whether this type of prompt information is abnormal. I hope you can give more suggestions ......