Istio breaks MySQL connection

11/13/2018

I have an application that works just fine when deployed on regular K8s. I installed Istio on K8s along with my application. I configured a gateway and virtual service. Most thing appear to work except for internal connections to MySQL.

There are a few services that use MySQL and they can no longer connect to the database with Istio.

Any idea what broke? I am guessing it's something to do with the automatically injected sidecar proxy messing with the traffic. I am new to Istio and the docs are a bit scarce in places. Do I need to configure anything special for MySQL? Interestingly calls to MongoDB and Redis appear to be working. Confused :-(

-- SteveWW
istio
kubernetes

1 Answer

11/15/2018

There are multiple bugs in istio 1.0.3 preventing this. One is the / in the name, which the developers don't seem to think is a big deal, but breaks all stateful sets as they use a slash in the name. Once this is resolved, you can get a statefulset mysql up, but the connection is fubar, it connects but immediately gives a MySQL has gone away. The newer 1.1 versions appear just as bad. I think 1.0.2 has the last "working" version of Istio, but there were still major issues that made me try newer versions.

You can find the istio.yaml change here: https://github.com/istio/istio/issues/9982

-- Michael Bushey
Source: StackOverflow