Cloud SQL read replica set max_worker_process - google-cloud-sql

I could not find any informations on setting different max_worker_processes for Cloud SQL read replica ? Since it is being replicated would it cause any error to set it manually ?
Thanks a lot for your help.
Jonathan.

Related

How to set up a CloudSQL Postgres to CloudSQL Postgres stream replication (not using CE), in different accounts

IM having some trouble to identify the steps required to do a PITR backup , restore and replication resume using CloudSQL servers manually. The issue seems to me not trivial since they are on separate accounts. May i ask some directions on this? Maybe a strategy using logical replication may help, but to resynchronize LSN is the real deal here
Thanks

AWS RDS Postgres: WAL_LEVEL not set to 'logical' after changing rds.logical_replication = 1

I am in the process of setting up Debezium to work with AWS Aurora Postgres (postgres version 12.6).
For Debezium to work, the WAL (Write-ahead-logging) must be set to 'logical' and not 'replica'.
On AWS, this would require a DBA to set the rds.logical_replication parameter in the parameter group to be set to 1.
The above was done. The database instance was restarted.
To verify that the WAL level was changed to 'logical', I ran the following query:
show wal_level.
However, after running this query in postgres on the target database the result showed replica.
I further looked at the log events in the AWS management console and I saw these log events.
Would anyone have an idea why this might be? There is another environment where we were able to successfully set the rds.logical_replication to 1 and following a database restart, the WAL was set to logical. But for our main environment this is not the case. Looking at the parameter groups, between these two environments, they are the same.
Any help/ advice is appreciated. thanks.
Ok after contacting the AWS support I got the information that the parameter "rds.logical_replication=1" is only active on the instance that has the Writer role (open for read-write). When you set this parameter you will have to use the writer instance for logical replication. You can connect to the writer instance either via Cluster endpoint (recommended) or instance endpoint.
I was checking the read-only instance with SHOW wal_level; but in fact it was set on the read/write instance !!!

MongoDB Atlas - Replica Set Has No Primary

I'm fairly new to MongoDB (Atlas - free tier), where I have created a project using it for storing my data. I had it set up and working fine for a couple of weeks, when suddenly I received an email with: An alert is open for your Atlas project: Replica set has no primary. I have no idea what this means and I don't believe I have done anything in the last couple of days/weeks that could warrant this alert. However, after checking my project, it seems that I can no longer connect to my cluster and access my data.
After checking on MongoDB Cloud, it seems that my cluster has stopped working and only the secondary shard (don't know if this is the right terminology) is running, while the other two seem to be down. Can anyone explain what this means, why it is happening or how to fix it? Thanks.
To troubleshoot issues like this, read the server logs and act based on the information therein.
For free and shared tiers in Atlas the logs are apparently not available. Therefore:
For a free tier cluster (M0), delete this cluster and create a new one. If you don't have a backup you should be able to dump via a direct connection to any of the operational secondary nodes or using the secondary read preference.
For a shared tier cluster (M2/M5), use the official MongoDB support channels for assistance.

Any option for making AWS RDS Read replica writable for Postgresql?

Currently I am using postgresql9.5 for my read replica. Also if possible please elaborate how I can implement master - master configuration for servers to be read-writable and 2 way synchronization
A PostgreSQL read replica(same or different region) is a physical copy, and PostgreSQL doesn't allow for a read replica to be made writable although you can promote a PostgreSQL read replica into a standalone DB instance.
This is a good read about best practices regarding RDS PostgreSQL read replicas replication

Enable logical replication on Google Cloud Postgres

Is there anyway to enable logical replication wal_level = logical on Google Cloud Postgres instance? I want to do CDC (change data capture) to stream WAL Record to Apache Kafka. Thanks for your help!
Update:
This feature now is enabled on Google Cloud SQL. To enable wal_level to replication you just need to set the flag cloudsql.logical_decoding as on.
For more details:
https://cloud.google.com/sql/docs/postgres/replication/configure-logical-replication
Note: this issue was solved in August, 30th release.
No, this is not supported by Cloud SQL for PostgreSQL.
The Cloud SQL engineering team is working on this issue, here you can find a Feature Request. You can star it in order to get notified when it gets updated. Also you can write a comment there and ask a question. Please, bear in mind that we don't have an ETA for it.