Can't create cluster after deleting cluster.conf

Nov 20, 2020
10
0
6
50
Hi,

I created a cluster on upgraded mailgate server (from 6.x to latest 7.x) and tried to join a slave, but that did not work due to deny.hosts prohibiting all ssh connections. After fixing hosts.deny and testing that one server can ssh to another with user root and ssk keys - I stopped pmgsync.service on both servers, deleted /etc/pmg/cluster.conf and started pmgsync.service again on both servers. Web interface showed no clusters or cluster members on both nodes.

then I tried to create cluster again on primary node:

root@mailgate:/etc/pmg# pmgcm create
stop all services accessing the database
save new cluster configuration
update quarantine database
update statistic database
update greylist database
update localstat database
DBD::pg::db do failed: ERROR: duplicate key value violates unique constraint "localstat_pkey" DETAIL: Key ("time", cid)=(1643803200, 1) already exists. at /usr/share/perl5/PMG/DBTools.pm line 937.

In web interface it shows that cluster is somehow created, but then when I try to add a slave node - it fails.

I'm not a postgresdb expert - is there any way to safely fix the duplicate in database? Would that fix the issue?

Cheers, Jan
 
pmgsync.service
that probably should have been pmgmirror and pmgtunnel service (those handle the cluster operations, pmgsync only makes sure that modifications to configs get put live)
In web interface it shows that cluster is somehow created, but then when I try to add a slave node - it fails.

could you share the logs of both nodes when trying to add the node?
 
that probably should have been pmgmirror and pmgtunnel service (those handle the cluster operations, pmgsync only makes sure that modifications to configs get put live)


could you share the logs of both nodes when trying to add the node?
uh, sorry, I had to fix my problem in a hurry, so I created a completely new 7.x PMG VM, copied configs from old one and created a cluster there. Old one is no longer existing :(
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!