You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@qpid.apache.org by Robert Żmigrodzki <rz...@rdprojekt.pl> on 2010/09/03 15:23:06 UTC

recovering a persistent cluster after a clean shutdown

  I have a problem with recovering a persistent cluster after a clean 
shutdown. Here is my scenario:

Fedora 13

yum install qpidd-cluster
yum install qpidc-devel
yum install amqp python-qpid
yum install rhm

qpidd -p5672 --cluster-name=MY_CLUSTER -d --data-dir /root/qpid/q2 --store-dir /root/qpid/s2 --auth=no

Everything looks OK so far. I can create queues, send and receive messages.

Then I shut down the running instance.

qpid-cluster -s 10.0.2.15:18148

The server shuts down cleanly, without any visible warnings. But then I want to restart the server.

qpidd -p5672 --cluster-name=MY_CLUSTER -d --data-dir /root/qpid/q2 --store-dir /root/qpid/s2 --auth=no

And what I get is an error message:
*Deamon startup failed: Cannot recover, no clean store*

Shouldn't the last working server in a cluster (in this case the only one) have a clean storage after a clean restart? Or perhaps
I do something wrong? I've googled around but didn't find anything that would solve my problem. Any help is welcomed.


--
Robert








Re: recovering a persistent cluster after a clean shutdown

Posted by Alan Conway <ac...@redhat.com>.
On 09/06/2010 05:12 AM, Robert Żmigrodzki wrote:
> W dniu 2010-09-03 18:38, Carl Trieloff pisze:
>> You should use qpid-cluster -k to stop the entire cluster, even though there's
>> only one member. That will cause the stores to be marked as clean.
>>
>> 1.3 will work the way he expects: if the cluster is reduced to a single member
>> its store will be marked clean.
>
> Thanks, I was quite sure, that i've check 'qpid-cluster -k' as well. It works as
> you said :)
> So there's one more thing that I'm missing - what is the recovery procedure in
> case of an uncontrolled shutdown of the last node in a cluster?
>

You would do:
# qpid-cluster-store -c <brokers-data-directory>

That will forcibly mark the store as clean so you can re-start from it.

---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:users-subscribe@qpid.apache.org


Re: recovering a persistent cluster after a clean shutdown

Posted by Robert Żmigrodzki <rz...@rdprojekt.pl>.
  W dniu 2010-09-03 18:38, Carl Trieloff pisze:
> You should use qpid-cluster -k to stop the entire cluster, even though 
> there's only one member. That will cause the stores to be marked as 
> clean.
>
> 1.3 will work the way he expects: if the cluster is reduced to a 
> single member its store will be marked clean.

Thanks, I was quite sure, that i've check 'qpid-cluster -k' as well. It 
works as you said :)
So there's one more thing that I'm missing - what is the recovery 
procedure in case of an uncontrolled shutdown of the last node in a cluster?

-- 
Robert

---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:users-subscribe@qpid.apache.org


Re: recovering a persistent cluster after a clean shutdown

Posted by Carl Trieloff <cc...@redhat.com>.
On 09/03/2010 09:23 AM, Robert Żmigrodzki wrote:
>  I have a problem with recovering a persistent cluster after a clean 
> shutdown. Here is my scenario:
>
> Fedora 13
>
> yum install qpidd-cluster
> yum install qpidc-devel
> yum install amqp python-qpid
> yum install rhm
>
> qpidd -p5672 --cluster-name=MY_CLUSTER -d --data-dir /root/qpid/q2 
> --store-dir /root/qpid/s2 --auth=no
>
> Everything looks OK so far. I can create queues, send and receive 
> messages.
>
> Then I shut down the running instance.
>
> qpid-cluster -s 10.0.2.15:18148
>
> The server shuts down cleanly, without any visible warnings. But then 
> I want to restart the server.
>
> qpidd -p5672 --cluster-name=MY_CLUSTER -d --data-dir /root/qpid/q2 
> --store-dir /root/qpid/s2 --auth=no
>
> And what I get is an error message:
> *Deamon startup failed: Cannot recover, no clean store*
>
> Shouldn't the last working server in a cluster (in this case the only 
> one) have a clean storage after a clean restart? Or perhaps
> I do something wrong? I've googled around but didn't find anything 
> that would solve my problem. Any help is welcomed.
>
>
> -- 
> Robert
>
>
>
>
>
>
>
>


 From Alan

You should use qpid-cluster -k to stop the entire cluster, even though 
there's only one member. That will cause the stores to be marked as clean.

1.3 will work the way he expects: if the cluster is reduced to a single 
member its store will be marked clean.

---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:users-subscribe@qpid.apache.org