-
-
Notifications
You must be signed in to change notification settings - Fork 855
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue with setting master log position #10
Comments
It looks like this may have been a result of some of the changes added to the role for replication. I'll try to take a look, but this error looks like it might be a little bit difficult to reproduce (unless it's just printing a var directly instead of in quotes—as you said, it could just be that a string is being placed somewhere rather than an integer). |
This is annoying to reproduce in a test environment, since it requires setting up a master and slave, getting them out of sync intentionally, then trying to set up the slave again (as happened in the above issue). But a possible fix might be making sure replication is stopped on the slave prior to running the - name: Stop replication on the slave.
mysql_replication: mode=stopslave
ignore_errors: True
when: >
slave|failed
and (mysql_replication_role == 'slave')
and (mysql_replication_master != '') |
My Ansible got this error. |
I had commented:
The seems not be used. |
I've same problem. I don't found how script handle master log_pos and log_file variables. |
This issue has been marked 'stale' due to lack of recent activity. If there is no further activity, the issue will be closed in another 30 days. Thank you for your contribution! Please read this blog post to see the reasons why I mark issues as stale. |
This issue has been closed due to inactivity. If you feel this is in error, please reopen the issue or file a new issue with the relevant details. |
Hi,
I am trying to configure a Slave node in a Master/Slave setup, running Ansible 1.8.x on Ubuntu, and receive the following error:
failed: [mdldrdb2] => {"failed": true, "parsed": false} Change master Traceback (most recent call last):
File "/root/.ansible/tmp/ansible-tmp-1418041186.92-240395126581341/mysql_replication", line 1949, in
main()
File "/root/.ansible/tmp/ansible-tmp-1418041186.92-240395126581341/mysql_replication", line 367, in main
changemaster(cursor, chm, chm_params)
File "/root/.ansible/tmp/ansible-tmp-1418041186.92-240395126581341/mysql_replication", line 165, in changemaster
cursor.execute(query, chm_params)
File "/usr/lib64/python2.6/site-packages/MySQLdb/cursors.py", line 173, in execute
self.errorhandler(self, exc, value)
File "/usr/lib64/python2.6/site-packages/MySQLdb/connections.py", line 36, in defaulterrorhandler
raise errorclass, errorvalue
_mysql_exceptions.ProgrammingError: (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''106'' at line 1") OpenSSH_6.6.1, OpenSSL 1.0.1f 6 Jan 2014
However, setting the following property to a static, numerical value, works. I.e.:
master_log_pos: "{{ master.Position }}"
Changed to
master_log_pos: 106
This seems to be an issue with the formatting of the data? Please advise
The text was updated successfully, but these errors were encountered: