Map-reduce jobs fail during rolling upgrade to 1.1 #144

jtuple opened this Issue Feb 24, 2012 · 2 comments


None yet

1 participant

jtuple commented Feb 24, 2012

Map reduce jobs fail against a mixed 1.1/1.0 cluster or 1.1/0.14 cluster. Mixed clusters are common during rolling upgrades, where nodes are upgraded one at a time until the entire cluster is at the new version (1.1 in this case).

In addition to the jobs failing, the Riak 1.1 nodes will print several instances of the following error and then eventually shutdown:

2012-02-22 00:56:16.429 [error] <0.1615.0>
gen_server riak_pipe_vnode_master terminated with reason: no function clause matching

2012-02-22 00:56:16.431 [error] <0.1615.0> CRASH REPORT
Process riak_pipe_vnode_master with 0 neighbours crashed with reason:
no function clause matching riak_core_vnode_master:handle_call(

The error arises from Riak 1.1 no longer implementing riak_core_vnode_master:handle_call({return_vnode, ...). Yet, pre-1.1 nodes will still send messages to Riak 1.1 nodes in a mixed cluster that must be handled by this now-missing clause.

jtuple commented Feb 24, 2012

There is also a related error. In addition to the above error, it is also possible to see the following errors during a map-reduce query to a mixed 1.1 and pre-1.1 cluster.

2012-02-24 14:58:04.501 [error] <0.26014.0> gen_fsm <0.26014.0> in
state wait_for_input terminated with reason: processing_error

2012-02-24 14:58:04.502 [error] <0.26014.0> CRASH REPORT Process
<0.26014.0> with 0 neighbours crashed with reason:

2012-02-24 14:58:04.503 [error] <0.321.0> Supervisor
riak_pipe_vnode_worker_sup had child undefined started with
{riak_pipe_vnode_worker,start_link,undefined} at <0.26014.0> exit with
reason processing_error in context child_terminated

While, processing_error is a bit non-descriptive, the map-reduce job will return more detailed information as the query response:

    "{badmatch, {'EXIT',noproc}}",
    "input": <snip>,
    "type": "error",

This is another issue with the vnode proxy refactoring in Riak 1.1 This time, it is the 1.1 nodes sending requests to the older 1.1 or 0.14 nodes.

Both issues need to be fixed to allow map-reduce to work during a rolling upgrade.

@jtuple jtuple added a commit that referenced this issue Feb 24, 2012
@jtuple jtuple Fix map_reduce during rolling upgrade to 1.1.
Resolve issue #144.

Change riak_core_vnode_master to still handle return_vnode messages
given that pre-1.1 nodes may still send those messages to a 1.1 node.

Add legacy routing logic to riak_core_vnode_master:command_return_vnode
in order to properly send messages to pre-1.0 nodes that do not have
vnode proxy processes.
jtuple commented Feb 25, 2012

Fixed by pull-request #145. Will be available in Riak 1.1.1.

@jtuple jtuple closed this Feb 25, 2012
@jtuple jtuple was assigned Feb 25, 2012
@jtuple jtuple was unassigned by ooshlablu Apr 25, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment