哪位大侠使用过mysql proxy啊?我不知道怎么样使mysql proxy连接两个mysql server,我使用mysql proxy的选项--proxy-backend-addresses连接两个数据库,但是mysql proxy只能操作一个数据库,另一个数据库总是不会被操作,哪位大侠能帮忙看看阿,谢谢。

解决方案 »

  1.   

    只有两个你就手动配置。用MYSQL PROXY 反而繁琐。
      

  2.   

    --proxy-backend-addresses=host:port — the hostname (or IP address) and port of the MySQL server to connect to. You can specify multiple backend servers by supplying multiple options. Clients are connected to each backend server in round-robin fashion. For example, if you specify two servers A and B, the first client connection will go to server A; the second client connection to server B and the third client connection to server A.你多建几个连接就知道怎么回事了,它用简单的round-robin(轮询)算法实现多台机时的负载均衡的。