[Openstack-operators] Openstack and mysql galera with haproxy
slawek at kaplonski.pl
Thu Sep 18 19:34:53 UTC 2014
Thanks all of You guys for help. I will try to apply that percona's scripts
and configure it in active/pasive mode.
About "mysql has gone away" I thought so it is not big problem but it looks
"ugly" in logs
Simon - I think that it is not related strictly to neutron and similar
problems can happend also in nova.
I have one more question to You guys. I know that there is mysql cluster
solution based on galera which is made by percona. Is it really better that
"pure" mysql-wsrep and galera installed or maybe it doesn't matter?
slawek at kaplonski.pl
Dnia czwartek, 18 września 2014 17:52:44 piszesz:
> We're using haproxy in front of a 3 node galera cluster, and we see the lost
> connection stuff pretty often, but that's normal behaviour, MySQL will tear
> down idle connections, SQLA handles reconnecting fine.
> As for deadlocks, if you are distributing writes across your nodes, I'd
> expect that, we solved it by using haproxy in a primary/backup mode, all
> traffic flows to one node by default, and fails over to one of the other
> nodes in the event of a failure, this means that writes are concentrated in
> a single node & the deadlock & roll back doesn't bite you.
> Also - I think you need to be running 3 galera nodes to be safe, as if a
> partition occurs, you can't cleanly reconnect a node as you can't achieve
> quorum. (I am not a DBA...)
> We're not running Neutron, so I can't comment on that, sorry.
> On 18 September 2014 at 17:35:18, Sławek Kapłoński (slawek at kaplonski.pl)
> Is anyone here using openstack with mysql galera and haproxy? Have You got
> any problems with that?
> I was today installed such ha infra for database (two mysql servers in
> galera cluster and haproxy on controller and neutron node, this haproxy is
> connecting to one of galera servers with round robin algorithm). Generally
> all is working fine but I have few problems:
> 1. I have a lot of messages like:
> WARNING neutron.openstack.common.db.sqlalchemy.session [-] Got mysql server
> has gone away: (2006, 'MySQL server has gone away')
> 2. I have (most on neutron) many errors like:
> OperationalError: (OperationalError) (2013, 'Lost connection to MySQL server
> during query') 'UPDATE ml2_port_bindings SET vif_type=%s, driver=%s,
> segment=%s WHERE ml2_port_bindings.port_id =
> 3. Also errors:
> StaleDataError: UPDATE statement on table 'ports' expected to update 1
> row(s); 0 were matched.
> 4. and errors:
> DBDeadlock: (OperationalError) (1213, 'Deadlock found when trying to get
> lock; try restarting transaction') 'UPDATE ipavailabilityranges SET
> first_ip=%s WHERE ipavailabilityranges.allocation_pool_id =
> Sql queries in examples are "accidental" and same problem is with other
> queries also (like deleting ports).
> Strange think is that those problems are not happend when I have one mysql
> server and all was connecting to that one server. Do You have maybe same
> problems? Do You know what can be a reason and solution for it?
> Best regards
> Sławek Kapłoński
> slawek at kaplonski.pl_______________________________________________
> OpenStack-operators mailing list
> OpenStack-operators at lists.openstack.org
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 819 bytes
Desc: This is a digitally signed message part.
More information about the OpenStack-operators