Lost one of alpha after stoping dgraph

What I want to do

I’m testing dgraph cluster (3 zero, 6 alpha - see docker-compose.yml) on Paralles under mac (intel) before moving in real production.

What I did

I’m filling graph with data. All here working the same I expected. But every time I’m stoping dgraph (docker-compose stop) then after starting I get that one of alphas can’t be connected. I have no idea why it’s going every time. I tried to clean all data and start over - and getting the same.

Dgraph metadata

1-alpha5-1 | Dgraph version : v22.0.2
1-alpha5-1 | Dgraph codename : dgraph
1-alpha5-1 | Dgraph SHA-256 : a11258bf3352eff0521bc68983a5aedb9316414947719920d75f12143dd368bd
1-alpha5-1 | Commit SHA-1 : 55697a4
1-alpha5-1 | Commit timestamp : 2022-12-16 23:03:35 +0000
1-alpha5-1 | Branch : release/v22.0.2
1-alpha5-1 | Go version : go1.18.5
1-alpha5-1 | jemalloc enabled : true

docker-compose.yml (4.6 KB)

Listing of starting:
docker-compose_up.txt (294.9 KB)

Received err: Opening table: "p/012781.sst" 
error: failed to initialize table error: failed to read index. 
error: failed to verify checksum for table: p/012781.sst 
error: actual: 263532966, expected: 824631074 
error: checksum mismatch

Check that you are not using a path that was already being used by another instance that does not belong to this cluster. You may have tested before and forgotten to clear the path.

Remove the “latest” tag from your yml for security. Always set a version. If you use latest you can end up unintentionally upgrading and breaking your installation if it is a BRAKING version.

Can you add

 working_dir: /data/alpha1

into your yaml? just for precaution.

In the end of you yaml you created a unused volume change to

volumes: {}

Also add this

 --security "whitelist=,,;"

Also, always start from scratch. Never reuse the same path, or always clean it up if you are recreating from 0 your cluster. Only when you have a stable cluster that you reuse the files in those binded paths.

1 Like