[rabbitmq-users] issues with the backed up mnesia folder after version upgrade from 3.3.1 to 3.4.0

185 views
Skip to first unread message

jayashree gn

unread,
Nov 19, 2014, 2:01:18 PM11/19/14
to rabbitm...@googlegroups.com
Hi All, 
Looking for some help on the data missing after restoring the mnesia folder after update to 3.4.0 to get poodle fix.  

Steps that i followed to upgrade to version 3.4.0 ( we use chef for our deployments and i use the opscode community cookbook) 
On an existing cluster with version 3.3.1 
> i updated the version in the chef attribute to 3.4.0 
> stopped rabbitmq service on all the instances ( RMQ is use is a cluster with 3 nodes) 
> moved the mnesia folder to a backup location 
> ran chef-client - which upgraded the version to 3.4.0 no problem 
> replaced the backed up mnesia folder with the existing one. 


So the upgrade was successful - rabbitmqctl status showed version 3.4.0 and same on the management page as well . 

issue
BUT, i lost the vhosts, queues and messages even after i replaced the backed up mnesia folder. 
How can i restore those? Will i loose the data with the upgrade to new version??


Thank you!!

Michael Klishin

unread,
Nov 19, 2014, 2:29:51 PM11/19/14
to jayashree gn, rabbitm...@googlegroups.com
You shouldn't need to move the database directory during upgrades. RabbitMQ will upgrade
it for you.

Has your host name changed at the same time by any chance?
--
MK

Staff Software Engineer, Pivotal/RabbitMQ

jayashree gn

unread,
Nov 19, 2014, 3:24:57 PM11/19/14
to Michael Klishin, rabbitm...@googlegroups.com
Thanks for the quick response MK. 
That is awesome if the upgrade doesnt need to move database.

But i had to because, when i first upgraded the version, the service failed to start. And thats when i tried the move the mnesia folder.
After i did this, the service started no problem.

I am building the cluster again right now so i can get you some logs for the issue I am running into, 
will get that to you in couple of minutes.

Simon MacMullen

unread,
Nov 20, 2014, 3:52:35 AM11/20/14
to jayashree gn, Michael Klishin, rabbitm...@googlegroups.com
On 19/11/2014 20:24, jayashree gn wrote:
> That is awesome if the upgrade doesnt need to move database.
>
> But i had to because, when i first upgraded the version, the service
> failed to start. And thats when i tried the move the mnesia folder.

When doing any upgrade, the broker first makes a copy of the mnesia
directory within that directory. If the upgrade failed *before* you
moved the Mnesia database, you might need to move it back manually.

Also, if the broker failed to start, it probably told you why. You
should read that :-)

Finally, see http://www.rabbitmq.com/clustering.html#upgrading if you
haven't already for information on cluster upgrades.

Cheers, Simon

jayashree gn

unread,
Nov 20, 2014, 2:58:56 PM11/20/14
to Simon MacMullen, Michael Klishin, rabbitm...@googlegroups.com
Thanks Simon! I figured that i wasnt reading the logs completly when MK replied that i did not have to move the database around. Figured i was missing something. 
There was this more thing admits the whole bunch of logs that i missed, which is to delete the lock file /var/lib/rabbitmq/mnesia/rabbit@rabbitnode/nodes_running_at_shutdown
before i did that, here are the steps that got me to upgrade the version from 3.3.1 to 3.4.0. I am doing this to get the poddle fix. 
> stopped the service on each node, ( i have a 3 node cluster)
> deleted the lock file
> ran chef to get the 3.4.0 version one node at a time. I have seen running into service start issues, if i start the service on all nodes simultaneously.

if there is a smarter way to do this, i'd appreciate your feedback.  

Thanks for your responses MK and Simon.. you guys have helped a lot. 





--
You received this message because you are subscribed to the Google Groups "rabbitmq-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rabbitmq-users+unsubscribe@googlegroups.com.
To post to this group, send an email to rabbitmq-users@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages