Comment 3 for bug 1704072

Revision history for this message
John A Meinel (jameinel) wrote :

One of the ways that I was able to reproduce this, is by getting Juju into a state where it wants to change the replicaset to exclude whoever the current primary of Mongo is.

The specific steps I used was:
 $ juju bootstrap lxd
 $ juju switch controller
 $ juju ssh 0
 # connect to Mongo, inject bad data into the db.presence.pings table so that the presence data is
 # forced to say that machine 0 is dead
 # I did that with:
 $$ agent=$(cd /var/lib/juju/agents; echo machine-*)
 $$ pw=$(sudo grep statepassword /var/lib/juju/agents/${agent}/agent.conf | cut '-d ' -sf2)
 $$ /usr/lib/juju/mongo3.2/bin/mongo --ssl -u ${agent} -p $pw --authenticationDatabase admin --sslAllowInvalidHostnames --sslAllowInvalidCertificates localhost:37017/juju