Installation issue on Google Cloud platform

Hi All,

I am trying to setup metabase for our organisation which uses GCP for cloud infra. I was trying to point MB to the read-replica during installation but the installation fails with the following message:

01-15 10:59:20 ERROR metabase.core :: Metabase Initialization FAILED
liquibase.exception.DatabaseException: (conn=175320) The MySQL server is running with the --read-only option so it cannot execute this statement [Failed SQL: CREATE TABLE <DB_NAME>.DATABASECHANGELOG (ID VARCHAR(255) NOT NULL, AUTHOR VARCHAR(255) NOT NULL, FILENAME VARCHAR(255) NOT NULL, DATEEXECUTED datetime NOT NULL, ORDEREXECUTED INT NOT NULL, EXECTYPE VARCHAR(10) NOT NULL, MD5SUM VARCHAR(35) NULL, `DESCRIPTION` VARCHAR(255) NULL, COMMENTS VARCHAR(255) NULL, TAG VARCHAR(255) NULL, LIQUIBASE VARCHAR(20) NULL, CONTEXTS VARCHAR(255) NULL, LABELS VARCHAR(255) NULL, DEPLOYMENT_ID VARCHAR(10) NULL)]
	at liquibase.executor.jvm.JdbcExecutor$ExecuteStatementCallback.doInStatement(JdbcExecutor.java:356)

Has anyone faced a similar issue? Does Metabase require write access to the DB during installation? I wanted to set it up on the replica DB to avoid any adverse impact on the production system.

Hi @rohitk,

Is MySQL configured as your application database? If so, Metabase needs write access to that database as it’s where it stores all its configuration information. The load on this database will be fairly low.

Once Metabase is setup, then you can add your desired database you wish to analyze using the read replica. The application database is different than databases you want to connect to. You can see more info on the latter here: https://www.metabase.com/docs/v0.34.1/administration-guide/01-managing-databases.html

Hope that helps!

Damon

1 Like

Hi @dacort,

Thanks for the response. I am passing my MySQL database (the read-replica) itself as the application Database. Is it recommended to create a new Database to be used as an application Database?

Thanks,
Rohit

Apologies for the delay in responding. Yes it’s recommended to create a new database. Metabase will need full read/write access to the application database for storing configuration and session data.