We have a program that connects to our cluster-object to read and/or write in a database.
When connecting while our primary server is active, it works without issues. When I do a failover and try to connect, I get Error while updating Database XY, the database is write protected.
Both servers have identical users and permissions, which I transferred with this stored procedure provided by Microsoft
The Availability Group is configured like this:
The databases have the same users mapped with the same permissions, therefore it is unlikely to be the issue.
I do not know what is causing this.
Thanks in advance.
Okay, I found out what was wrong:
Our program should have been pointing at the group listener and not the cluster object, because the cluster object points only at the first replica server in it's cluster. That's why after the failover all the databases were write protected.