Score:0

Lightest option for MySQL proxy

in flag

I'm looking for the most lightweight program that is capable of serving as a MySQL proxy to a remote server, unifying all connections to the proxy into a single connection to the remote MySQL server (so only the proxy will be on my machine).

I installed mysql-router but then, per this article from the docs, it seems it requires the normal MySQL server package, which I want to avoid completely (unless it's just needed for essential binaries).

What's the best & most lightweight proxy that meets my requirements, and install procedure?

For Ubuntu 20.04.

EDIT: Nevermind, mysql-router doesn't require MySQL server to be installed in the same machine, I understood the document wrong. However, after setting a proper sample setup it seems not to allow me to do what I want, and that led me to realize I might need to clarify what's what I want:

  1. Multiple applications connect to the router/proxy against the same MySQL credentials (same DB and user)
  2. Router/proxy establishes a single connection using the same MySQL credentials than the client applications; that is, doesn't simply forward each connection coming from each application to the server.
  3. Queries from all clients will end in the single MySQL connection from the proxy to the remote server, and get response back to each requesting client, accordingly

For context, my motivation is that max_user_connections at the remote server is not enough for all my clients, and I don't have the required privileges...

pLumo avatar
in flag
Not really understand why you need a mysql proxy, can't you just open an SSH tunnel and then connect to this?
Adrián avatar
in flag
@pLumo Hadn't thought about that, but that would add some slowness by nature and I don't have access to the remote machine other than for MySQL, so AFAIK can't do a SSH tunnel.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.