-
Notifications
You must be signed in to change notification settings - Fork 1
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
Errors when configuring DB replica access #611
Comments
I might be missing some other required configuration. Any tips would be appreciated @physikerwelt |
Does the wiki work if you remove the $wgDBservers variable (and it falls back to the $wgDBserver (without an s pointing to a single ip) |
Yes, everything works without errors if I remove the $wgDBservers configuration. |
The next step would be to verify that the mysql slave in in healthy state. There are several guides online how to verify this. It is possible that the master works but the replica (I think slave violates PC) has problems. Once that is figured out, I would switch to the servers (plural) variant with only a master node, and then add the slave in a next step. If all of the above does not help, I can have a look. |
SHOW SLAVE STATUS always shows the replica in a good state. When defining only one master with $wgDBservers, everything works, replication happens and SHOW SLAVE STATUS is also healthy. Things break when I add both nodes to $wgDBservers. I am going to try next to just define replicas directly in the docker-compose.yml file. This does not seem to be a problem with Kubernetes or the db connection but rather a mediawiki configuration problem. |
Maybe you can share the details with me in PM and I can look around if I discover a typo, or something similar. |
This is the link to the configuration that worked before |
Can you take a look at this branch to see if you spot the problem? https://github.com/MaRDI4NFDI/portal-compose/tree/test_replica |
I have properly set up two mariadb pods in the k8s cluster and tested that replication works when changes are introduced in the main replica.
Starting docker compose also initializes all the tables in the my_wiki database. So the connection to the database is also working.
However, when accessing the local instance of the portal shows then these errors when navigating to any page:
Apart from updating the host and credentials in docker-compose.yml I've only added this to LocalSettings.php (with the right host, dbname, user and password):
The text was updated successfully, but these errors were encountered: