Setting up MusicBrainz Database MIrror server alone without web and API service

I am trying to setup musicbrainz database mirror server in my local machine. I was referring for this and in the README, its suggested that

If you want to mirror the Postgres database only (neither the website nor the web API), change the base configuration with the following command (as a first step, otherwise it will blank it out):

admin/configure with alt-db-only-mirror

I didnt understand what is meant by this because in the admin directory there is no such file. May be I was wrong with understanding this.

Also I found a compose file docker-compose.alt.db-only-mirror.yml in the github repository. So is it possible to bring up the database alone using this compose file.

If this is a question, you can find some more detailed information about it here:


Thanks. @InvisibleMan78



I did setup musicbrainz database mirror alone in my local system and the running containers is attached below

and I tried to connect to the musicbrainz database using the below python code

import psycopg2
conn = psycopg2.connect(database="musicbrainz_db",user="musicbrainz", password="musicbrainz",port="5432", host="localhost")
print("Connection established")

and obtained the following error

    conn = _connect(dsn, connection_factory=connection_factory, **kwasync)
psycopg2.OperationalError: could not connect to server: Connection refused
	Is the server running on host "localhost" ( and accepting
	TCP/IP connections on port 5432?

How to connect to the database and is there any help available about accessing data from musicbrainz database setup in local machine

1 Like

Did you have published the ports as mentioned in the installation instructions:

In your case

admin/configure add publishing-db-port
sudo docker-compose up -d

should do the trick.


Hi again

For setting up Musicbrainz server the recommended configuration suggested is

Recommended hardware/VM

    CPU: 16 threads (or 2 without indexed search)
    RAM: 16 GB (or 4 without indexed search)
    Disk Space: 200 GB (or 70 without indexed search) + system disk usage

For setting up database alone with or without indexed search, do we require this much hardware configuration ?

Yes, that is without indexed search.