1.4.2: 'riak-admin reip' no longer works?

classic Classic list List threaded Threaded
11 messages Options
Reply | Threaded
Open this post in threaded view
|

1.4.2: 'riak-admin reip' no longer works?

Dave Brady
Hi everyone,

So, I went to copy /var/lib/riak/* from one five-node cluster to another, so that we could experiment on the data.

I did this fairly frequently in the past (< 1.4.0), and always used "riak-admin reip <old> <new>".

Now, when I try that command on our 1.4.2 ring, 'riak-admin' dies with "Node is not running!"

This confuses me, since "reip" requires the ring to be down, but the "riak-admin" script is indeed expecting the local node to be running when using this option.

I see on the wiki that it is mentioned that "cluster replace" will replace "reip" in the future.  I hope not, since "cluster replace" does not provide the same functionality.

Anyone run into this and find a fix?  (Or I am missing something obvious?)

Thanks!

--
Dave Brady


_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
Reply | Threaded
Open this post in threaded view
|

Re: 1.4.2: 'riak-admin reip' no longer works?

Dave Brady
Thanks to Joe Caswell at Basho: just have to comment out line 382 (node_up_check) in the riak-admin script.

--
Dave Brady

----- Original Message -----
From: "Dave Brady" <[hidden email]>
To: [hidden email]
Sent: Lundi 21 Octobre 2013 13:59:37
Subject: 1.4.2: 'riak-admin reip' no longer works?

Hi everyone,

So, I went to copy /var/lib/riak/* from one five-node cluster to another, so that we could experiment on the data.

I did this fairly frequently in the past (< 1.4.0), and always used "riak-admin reip <old> <new>".

Now, when I try that command on our 1.4.2 ring, 'riak-admin' dies with "Node is not running!"

This confuses me, since "reip" requires the ring to be down, but the "riak-admin" script is indeed expecting the local node to be running when using this option.

I see on the wiki that it is mentioned that "cluster replace" will replace "reip" in the future.  I hope not, since "cluster replace" does not provide the same functionality.

Anyone run into this and find a fix?  (Or I am missing something obvious?)

Thanks!

--
Dave Brady


_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com

_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
Reply | Threaded
Open this post in threaded view
|

Re: 1.4.2: 'riak-admin reip' no longer works?

Jared Morrow
This was a mistake on my part, if you s/up/down/ (node_down_check) on that line it will correctly ensure the node is down before running reip.  Sorry about that, clearly 'reip' is not heavily used with the new cluster commands and it slipped under the radar for all these months.

-Jared


On Mon, Oct 21, 2013 at 7:48 AM, Dave Brady <[hidden email]> wrote:
Thanks to Joe Caswell at Basho: just have to comment out line 382 (node_up_check) in the riak-admin script.

--
Dave Brady

----- Original Message -----
From: "Dave Brady" <[hidden email]>
To: [hidden email]
Sent: Lundi 21 Octobre 2013 13:59:37
Subject: 1.4.2: 'riak-admin reip' no longer works?

Hi everyone,

So, I went to copy /var/lib/riak/* from one five-node cluster to another, so that we could experiment on the data.

I did this fairly frequently in the past (< 1.4.0), and always used "riak-admin reip <old> <new>".

Now, when I try that command on our 1.4.2 ring, 'riak-admin' dies with "Node is not running!"

This confuses me, since "reip" requires the ring to be down, but the "riak-admin" script is indeed expecting the local node to be running when using this option.

I see on the wiki that it is mentioned that "cluster replace" will replace "reip" in the future.  I hope not, since "cluster replace" does not provide the same functionality.

Anyone run into this and find a fix?  (Or I am missing something obvious?)

Thanks!

--
Dave Brady


_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com

_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com


_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
Reply | Threaded
Open this post in threaded view
|

Re: 1.4.2: 'riak-admin reip' no longer works?

Dave Brady
No problem, Jared!  I'm happy it was a very simple fix.

What concerns me is that the 'cluster' commands do not have an analogous feature: 'replace' does not do the same thing as 'reip'.

Is it truly a foregone conclusion that 'reip' is going away?

--
Dave Brady


From: "Jared Morrow" <[hidden email]>
To: "Dave Brady" <[hidden email]>
Cc: "Riak Users Mailing List" <[hidden email]>
Sent: Lundi 21 Octobre 2013 16:17:52
Subject: Re: 1.4.2: 'riak-admin reip' no longer works?

This was a mistake on my part, if you s/up/down/ (node_down_check) on that line it will correctly ensure the node is down before running reip.  Sorry about that, clearly 'reip' is not heavily used with the new cluster commands and it slipped under the radar for all these months.

-Jared


On Mon, Oct 21, 2013 at 7:48 AM, Dave Brady <[hidden email]> wrote:
Thanks to Joe Caswell at Basho: just have to comment out line 382 (node_up_check) in the riak-admin script.

--
Dave Brady

----- Original Message -----
From: "Dave Brady" <[hidden email]>
To: [hidden email]
Sent: Lundi 21 Octobre 2013 13:59:37
Subject: 1.4.2: 'riak-admin reip' no longer works?

Hi everyone,

So, I went to copy /var/lib/riak/* from one five-node cluster to another, so that we could experiment on the data.

I did this fairly frequently in the past (< 1.4.0), and always used "riak-admin reip <old> <new>".

Now, when I try that command on our 1.4.2 ring, 'riak-admin' dies with "Node is not running!"

This confuses me, since "reip" requires the ring to be down, but the "riak-admin" script is indeed expecting the local node to be running when using this option.

I see on the wiki that it is mentioned that "cluster replace" will replace "reip" in the future.  I hope not, since "cluster replace" does not provide the same functionality.

Anyone run into this and find a fix?  (Or I am missing something obvious?)

Thanks!

--
Dave Brady


_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com

_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com



_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
Reply | Threaded
Open this post in threaded view
|

Re: 1.4.2: 'riak-admin reip' no longer works?

Dave Brady
...more to point: will riak_kv_console:reip still exist, and just not be surfaced in riak-admin, or will the function be removed?

--
Dave Brady


From: "Dave Brady" <[hidden email]>
To: "Jared Morrow" <[hidden email]>
Cc: "Riak Users Mailing List" <[hidden email]>
Sent: Lundi 21 Octobre 2013 16:23:46
Subject: Re: 1.4.2: 'riak-admin reip' no longer works?

No problem, Jared!  I'm happy it was a very simple fix.

What concerns me is that the 'cluster' commands do not have an analogous feature: 'replace' does not do the same thing as 'reip'.

Is it truly a foregone conclusion that 'reip' is going away?

--
Dave Brady


From: "Jared Morrow" <[hidden email]>
To: "Dave Brady" <[hidden email]>
Cc: "Riak Users Mailing List" <[hidden email]>
Sent: Lundi 21 Octobre 2013 16:17:52
Subject: Re: 1.4.2: 'riak-admin reip' no longer works?

This was a mistake on my part, if you s/up/down/ (node_down_check) on that line it will correctly ensure the node is down before running reip.  Sorry about that, clearly 'reip' is not heavily used with the new cluster commands and it slipped under the radar for all these months.

-Jared


On Mon, Oct 21, 2013 at 7:48 AM, Dave Brady <[hidden email]> wrote:
Thanks to Joe Caswell at Basho: just have to comment out line 382 (node_up_check) in the riak-admin script.

--
Dave Brady

----- Original Message -----
From: "Dave Brady" <[hidden email]>
To: [hidden email]
Sent: Lundi 21 Octobre 2013 13:59:37
Subject: 1.4.2: 'riak-admin reip' no longer works?

Hi everyone,

So, I went to copy /var/lib/riak/* from one five-node cluster to another, so that we could experiment on the data.

I did this fairly frequently in the past (< 1.4.0), and always used "riak-admin reip <old> <new>".

Now, when I try that command on our 1.4.2 ring, 'riak-admin' dies with "Node is not running!"

This confuses me, since "reip" requires the ring to be down, but the "riak-admin" script is indeed expecting the local node to be running when using this option.

I see on the wiki that it is mentioned that "cluster replace" will replace "reip" in the future.  I hope not, since "cluster replace" does not provide the same functionality.

Anyone run into this and find a fix?  (Or I am missing something obvious?)

Thanks!

--
Dave Brady


_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com

_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com



_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com


_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
Reply | Threaded
Open this post in threaded view
|

Re: 1.4.2: 'riak-admin reip' no longer works?

Jared Morrow
In reply to this post by Dave Brady
We actually discussed this recently, my understanding of reip was clearly not complete, and Joe Caswell put me on the right track.  'reip' will continue to stick around.

-Jared


On Mon, Oct 21, 2013 at 8:23 AM, Dave Brady <[hidden email]> wrote:
No problem, Jared!  I'm happy it was a very simple fix.

What concerns me is that the 'cluster' commands do not have an analogous feature: 'replace' does not do the same thing as 'reip'.

Is it truly a foregone conclusion that 'reip' is going away?

--
Dave Brady


From: "Jared Morrow" <[hidden email]>
To: "Dave Brady" <[hidden email]>
Cc: "Riak Users Mailing List" <[hidden email]>
Sent: Lundi 21 Octobre 2013 16:17:52
Subject: Re: 1.4.2: 'riak-admin reip' no longer works?


This was a mistake on my part, if you s/up/down/ (node_down_check) on that line it will correctly ensure the node is down before running reip.  Sorry about that, clearly 'reip' is not heavily used with the new cluster commands and it slipped under the radar for all these months.

-Jared


On Mon, Oct 21, 2013 at 7:48 AM, Dave Brady <[hidden email]> wrote:
Thanks to Joe Caswell at Basho: just have to comment out line 382 (node_up_check) in the riak-admin script.

--
Dave Brady

----- Original Message -----
From: "Dave Brady" <[hidden email]>
To: [hidden email]
Sent: Lundi 21 Octobre 2013 13:59:37
Subject: 1.4.2: 'riak-admin reip' no longer works?

Hi everyone,

So, I went to copy /var/lib/riak/* from one five-node cluster to another, so that we could experiment on the data.

I did this fairly frequently in the past (< 1.4.0), and always used "riak-admin reip <old> <new>".

Now, when I try that command on our 1.4.2 ring, 'riak-admin' dies with "Node is not running!"

This confuses me, since "reip" requires the ring to be down, but the "riak-admin" script is indeed expecting the local node to be running when using this option.

I see on the wiki that it is mentioned that "cluster replace" will replace "reip" in the future.  I hope not, since "cluster replace" does not provide the same functionality.

Anyone run into this and find a fix?  (Or I am missing something obvious?)

Thanks!

--
Dave Brady


_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com

_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com




_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
Reply | Threaded
Open this post in threaded view
|

Re: 1.4.2: 'riak-admin reip' no longer works?

Dave Brady
Thanks for clarifying it!

This functionality has been *great* to create quick-and-dirty test rings.

--
Dave Brady


From: "Jared Morrow" <[hidden email]>
To: "Dave Brady" <[hidden email]>
Cc: "Riak Users Mailing List" <[hidden email]>
Sent: Lundi 21 Octobre 2013 16:42:22
Subject: Re: 1.4.2: 'riak-admin reip' no longer works?

We actually discussed this recently, my understanding of reip was clearly not complete, and Joe Caswell put me on the right track.  'reip' will continue to stick around.

-Jared


On Mon, Oct 21, 2013 at 8:23 AM, Dave Brady <[hidden email]> wrote:
No problem, Jared!  I'm happy it was a very simple fix.

What concerns me is that the 'cluster' commands do not have an analogous feature: 'replace' does not do the same thing as 'reip'.

Is it truly a foregone conclusion that 'reip' is going away?

--
Dave Brady


From: "Jared Morrow" <[hidden email]>
To: "Dave Brady" <[hidden email]>
Cc: "Riak Users Mailing List" <[hidden email]>
Sent: Lundi 21 Octobre 2013 16:17:52
Subject: Re: 1.4.2: 'riak-admin reip' no longer works?


This was a mistake on my part, if you s/up/down/ (node_down_check) on that line it will correctly ensure the node is down before running reip.  Sorry about that, clearly 'reip' is not heavily used with the new cluster commands and it slipped under the radar for all these months.

-Jared


On Mon, Oct 21, 2013 at 7:48 AM, Dave Brady <[hidden email]> wrote:
Thanks to Joe Caswell at Basho: just have to comment out line 382 (node_up_check) in the riak-admin script.

--
Dave Brady

----- Original Message -----
From: "Dave Brady" <[hidden email]>
To: [hidden email]
Sent: Lundi 21 Octobre 2013 13:59:37
Subject: 1.4.2: 'riak-admin reip' no longer works?

Hi everyone,

So, I went to copy /var/lib/riak/* from one five-node cluster to another, so that we could experiment on the data.

I did this fairly frequently in the past (< 1.4.0), and always used "riak-admin reip <old> <new>".

Now, when I try that command on our 1.4.2 ring, 'riak-admin' dies with "Node is not running!"

This confuses me, since "reip" requires the ring to be down, but the "riak-admin" script is indeed expecting the local node to be running when using this option.

I see on the wiki that it is mentioned that "cluster replace" will replace "reip" in the future.  I hope not, since "cluster replace" does not provide the same functionality.

Anyone run into this and find a fix?  (Or I am missing something obvious?)

Thanks!

--
Dave Brady


_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com

_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com





_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
Reply | Threaded
Open this post in threaded view
|

Re: 1.4.2: 'riak-admin reip' no longer works?

Brady Wetherington
Huh. I thought we were supposed to use "force-replace" instead of "reip"?

I remember having a discussion a few months back about the documentation and we cleared it up a little.

Is "reip" the same as "force-replace", or is it more..."quick-and-dirty?" Is it deprecated?

-B.


On Mon, Oct 21, 2013 at 11:33 AM, Dave Brady <[hidden email]> wrote:
Thanks for clarifying it!

This functionality has been *great* to create quick-and-dirty test rings.

--
Dave Brady


From: "Jared Morrow" <[hidden email]>
To: "Dave Brady" <[hidden email]>
Cc: "Riak Users Mailing List" <[hidden email]>
Sent: Lundi 21 Octobre 2013 16:42:22

Subject: Re: 1.4.2: 'riak-admin reip' no longer works?

We actually discussed this recently, my understanding of reip was clearly not complete, and Joe Caswell put me on the right track.  'reip' will continue to stick around.

-Jared


On Mon, Oct 21, 2013 at 8:23 AM, Dave Brady <[hidden email]> wrote:
No problem, Jared!  I'm happy it was a very simple fix.

What concerns me is that the 'cluster' commands do not have an analogous feature: 'replace' does not do the same thing as 'reip'.

Is it truly a foregone conclusion that 'reip' is going away?

--
Dave Brady


From: "Jared Morrow" <[hidden email]>
To: "Dave Brady" <[hidden email]>
Cc: "Riak Users Mailing List" <[hidden email]>
Sent: Lundi 21 Octobre 2013 16:17:52
Subject: Re: 1.4.2: 'riak-admin reip' no longer works?


This was a mistake on my part, if you s/up/down/ (node_down_check) on that line it will correctly ensure the node is down before running reip.  Sorry about that, clearly 'reip' is not heavily used with the new cluster commands and it slipped under the radar for all these months.

-Jared


On Mon, Oct 21, 2013 at 7:48 AM, Dave Brady <[hidden email]> wrote:
Thanks to Joe Caswell at Basho: just have to comment out line 382 (node_up_check) in the riak-admin script.

--
Dave Brady

----- Original Message -----
From: "Dave Brady" <[hidden email]>
To: [hidden email]
Sent: Lundi 21 Octobre 2013 13:59:37
Subject: 1.4.2: 'riak-admin reip' no longer works?

Hi everyone,

So, I went to copy /var/lib/riak/* from one five-node cluster to another, so that we could experiment on the data.

I did this fairly frequently in the past (< 1.4.0), and always used "riak-admin reip <old> <new>".

Now, when I try that command on our 1.4.2 ring, 'riak-admin' dies with "Node is not running!"

This confuses me, since "reip" requires the ring to be down, but the "riak-admin" script is indeed expecting the local node to be running when using this option.

I see on the wiki that it is mentioned that "cluster replace" will replace "reip" in the future.  I hope not, since "cluster replace" does not provide the same functionality.

Anyone run into this and find a fix?  (Or I am missing something obvious?)

Thanks!

--
Dave Brady


_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com

_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com





_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com



_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
Reply | Threaded
Open this post in threaded view
|

Re: 1.4.2: 'riak-admin reip' no longer works?

Joe Caswell
Reip is the old, evil way to do it that is fraught with peril.  When it works it works spectacularly, and when it doesn't, it fails spectacularly.  The only use case left for reip is when you have simultaneously changed the node name for every node in the cluster, such as when loading an entire cluster's worth of backups to new machines.  Since a node will not be able to start unless it is a member of the ring it currently holds, and `riak-admin cluster [force-]replace` requires there to be at least one node in the cluster running,  reip is the only option to get the first node started.  After the first node, all the rest can be handled with cluster replace.

Joe Caswell

From: Brady Wetherington <[hidden email]>
Date: Monday, October 21, 2013 12:26 PM
To: Dave Brady <[hidden email]>
Cc: Riak Users Mailing List <[hidden email]>
Subject: Re: 1.4.2: 'riak-admin reip' no longer works?

Huh. I thought we were supposed to use "force-replace" instead of "reip"?

I remember having a discussion a few months back about the documentation and we cleared it up a little.

Is "reip" the same as "force-replace", or is it more..."quick-and-dirty?" Is it deprecated?

-B.


On Mon, Oct 21, 2013 at 11:33 AM, Dave Brady <[hidden email]> wrote:
Thanks for clarifying it!

This functionality has been *great* to create quick-and-dirty test rings.

--
Dave Brady


From: "Jared Morrow" <[hidden email]>
To: "Dave Brady" <[hidden email]>
Cc: "Riak Users Mailing List" <[hidden email]>
Sent: Lundi 21 Octobre 2013 16:42:22

Subject: Re: 1.4.2: 'riak-admin reip' no longer works?

We actually discussed this recently, my understanding of reip was clearly not complete, and Joe Caswell put me on the right track.  'reip' will continue to stick around.

-Jared


On Mon, Oct 21, 2013 at 8:23 AM, Dave Brady <[hidden email]> wrote:
No problem, Jared!  I'm happy it was a very simple fix.

What concerns me is that the 'cluster' commands do not have an analogous feature: 'replace' does not do the same thing as 'reip'.

Is it truly a foregone conclusion that 'reip' is going away?

--
Dave Brady


From: "Jared Morrow" <[hidden email]>
To: "Dave Brady" <[hidden email]>
Cc: "Riak Users Mailing List" <[hidden email]>
Sent: Lundi 21 Octobre 2013 16:17:52
Subject: Re: 1.4.2: 'riak-admin reip' no longer works?


This was a mistake on my part, if you s/up/down/ (node_down_check) on that line it will correctly ensure the node is down before running reip.  Sorry about that, clearly 'reip' is not heavily used with the new cluster commands and it slipped under the radar for all these months.

-Jared


On Mon, Oct 21, 2013 at 7:48 AM, Dave Brady <[hidden email]> wrote:
Thanks to Joe Caswell at Basho: just have to comment out line 382 (node_up_check) in the riak-admin script.

--
Dave Brady

----- Original Message -----
From: "Dave Brady" <[hidden email]>
To: [hidden email]
Sent: Lundi 21 Octobre 2013 13:59:37
Subject: 1.4.2: 'riak-admin reip' no longer works?

Hi everyone,

So, I went to copy /var/lib/riak/* from one five-node cluster to another, so that we could experiment on the data.

I did this fairly frequently in the past (< 1.4.0), and always used "riak-admin reip <old> <new>".

Now, when I try that command on our 1.4.2 ring, 'riak-admin' dies with "Node is not running!"

This confuses me, since "reip" requires the ring to be down, but the "riak-admin" script is indeed expecting the local node to be running when using this option.

I see on the wiki that it is mentioned that "cluster replace" will replace "reip" in the future.  I hope not, since "cluster replace" does not provide the same functionality.

Anyone run into this and find a fix?  (Or I am missing something obvious?)

Thanks!

--
Dave Brady


_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com

_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com





_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com


_______________________________________________ riak-users mailing list [hidden email] http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com

_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
Reply | Threaded
Open this post in threaded view
|

Re: 1.4.2: 'riak-admin reip' no longer works?

Shane McEwan-2
On 21/10/13 17:57, Joe Caswell wrote:
> The only use case left for reip is when you have simultaneously changed the
> node name for every node in the cluster, such as when loading an entire
> cluster's worth of backups to new machines.

When I need to do this I just create a new, empty cluster with the new
names. Then shut down the cluster and restore only the data directories
(leveldb, for example) from the backup, leaving the ring directory
alone. Then I start up the cluster and it finds the restored data. You
need to be careful about restoring the old node's data to the
corresponding new node otherwise you'll get hinted handoffs flying
between all your nodes but after a bit of trial and error you can figure
out which node is which.

Shane.

_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
Reply | Threaded
Open this post in threaded view
|

Re: 1.4.2: 'riak-admin reip' no longer works?

Rune Skou Larsen
Den 22-10-2013 09:53, Shane McEwan skrev:
> On 21/10/13 17:57, Joe Caswell wrote:
>> The only use case left for reip is when you have simultaneously changed the
>> node name for every node in the cluster, such as when loading an entire
>> cluster's worth of backups to new machines.
> When I need to do this I just create a new, empty cluster with the new
> names. Then shut down the cluster and restore only the data directories
> (leveldb, for example) from the backup, leaving the ring directory
> alone. Then I start up the cluster and it finds the restored data.
Thanks for the tip. Beware that this will not restore bucket props,
because they are stored in the ring dir and not the data dir.
> You need to be careful about restoring the old node's data to the
> corresponding new node otherwise you'll get hinted handoffs flying
> between all your nodes but after a bit of trial and error you can figure
> out which node is which.
When you create the new, empty cluster, Riak distributes the partitions
between the nodes using the claim function. I believe claim_v2
(riak_core_claim.erl) is still the default claim function and it will
produce different partition distributions in different runs when joining
nodes to form a cluster. Including the dreaded 12,12,12,12,16 on a
default config with 5 nodes.
I guess sometimes you'll be lucky, and the new shiny cluster will have
the same partition distribution as the backup, but in my experience,
this is not always the case, which means the new cluster will need to
handoff data between nodes, to match the data with the ring-files'
partition distribution.

The good(tm) way to restore a complete backup to a new environment is to
restore data and partition distribution together - i.e. both the data
dirs and the ring files.
For this purpose, reip was very useful in v 1.3.x, where the node it was
called on, did not have to be running. Unfortunately in 1.4.2, the
reip'ed node must be running (which sort of defies the purpose of reip):

"riak-1.3.2/rel/riak/bin> ./riak-admin reip bla bla2
Backed up existing ring file to
"./data/ring/riak_core_ring.default.20131004091923.BAK"
New ring file written to "./data/ring/riak_core_ring.default.20131022105325

riak-1.4.2/rel/riak/bin> ./riak-admin reip bla bla2
Node is not running!"

A common case where you need reip'ing non-running nodes, is when you
copy production data to a staging environment, and need to ensure that
your new staging cluster doesn't reference production nodes before
firing it up. Does anyone know a good solution to this in 1.4? The only
two ways I see are: 1) Edit the ring-files by hand 2) Restore to a new
cluster with potentially mismatched partition distribution between data
and ring-files, and wait for handoffs to complete.

- Rune, Trifork

_______________________________________________
riak-users mailing list
[hidden email]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com