Details
-
Bug
-
Resolution: Fixed
-
Major
-
4.0.0
-
Security Level: Public
-
None
-
Untriaged
-
Unknown
Description
During vBcuket takeover, after the old master (producer) has sent all its mutations to the new master, it sends the first vBucket state change message to the new master. This message should set the state of the vBcuket on new master to "pending".
But looking at the ns_server.debug.log, it appears that the state is set to "replica" instead. This message logs the contents of the DCP packet sent by the
producer memcached.
Discussed with Manu and he will investigate further.
Please update fix and affect version as required.
Here are the relevant messages from the debug.log.
[ns_server:debug,2015-09-13T17:43:17.400-07:00,n_2@127.0.0.1:dcp_consumer_conn-default-n_0@10.0.0.29<0.1138.0>:dcp_commands:add_stream:66]Add stream for partition 767, opaque = 0x2FF, type = takeover
[ns_server:debug,2015-09-13T17:43:17.401-07:00,n_2@127.0.0.1:dcp_consumer_conn-default-n_0@10.0.0.29<0.1138.0>:dcp_proxy:handle_packet:115]Proxy packet: REQUEST: 0x53 (dcp_stream_req) vbucket = 767 opaque = 0x8000000
80 53 00 00$
...
[ns_server:debug,2015-09-13T17:43:17.401-07:00,n_2@127.0.0.1:<0.1139.0>:dcp_proxy:handle_packet:115]Proxy packet: RESPONSE: 0x53 (dcp_stream_req) vbucket = 0 opaque = 0x8000000 status = 0x0 (success)$
81 53 00 00$
00 00 00 00$
...
[ns_server:debug,2015-09-13T17:43:17.402-07:00,n_2@127.0.0.1:<0.1139.0>:dcp_producer_conn:handle_packet:33]?DCP_SET_VBUCKET_STATE: proxy Packet:<<128,91,0,0,1,0,2,255,0,0,0,1,8,0,0,0,0,0,0,0,0,0,0,0,2>>
[rebalance:debug,2015-09-13T17:43:17.402-07:00,n_2@127.0.0.1:dcp_consumer_conn-default-n_0@10.0.0.29<0.1138.0>:dcp_consumer_conn:handle_cast:284]Partition 767 is about to change status to replica <============== should be pending
[ns_server:debug,2015-09-13T17:43:17.402-07:00,n_2@127.0.0.1:dcp_consumer_conn-default-n_0@10.0.0.29<0.1138.0>:dcp_proxy:handle_packet:115]Proxy packet: RESPONSE: 0x5B (dcp_set_vbucket_state) vbucket = 0 opaque = 0x8000000 status = 0x0 (success)$
81 5B 00 00$
00 00 00 00$
00 00 00 00$
08 00 00 00$
00 00 00 00$
00 00 00 00$
$
[rebalance:debug,2015-09-13T17:43:17.402-07:00,n_2@127.0.0.1:dcp_consumer_conn-default-n_0@10.0.0.29<0.1138.0>:dcp_consumer_conn:handle_packet:133]Partition 767 changed status to replica <============== should be pending
[ns_server:debug,2015-09-13T17:43:17.403-07:00,n_2@127.0.0.1:<0.1139.0>:dcp_proxy:handle_packet:115]Proxy packet: REQUEST: 0x5B (dcp_set_vbucket_state) vbucket = 767 opaque = 0x8000000$
80 5B 00 00$
01 00 02 FF$
00 00 00 01$
08 00 00 00$
00 00 00 00$
00 00 00 00$
01 $
[ns_server:debug,2015-09-13T17:43:17.403-07:00,n_2@127.0.0.1:<0.1139.0>:dcp_producer_conn:handle_packet:33]?DCP_SET_VBUCKET_STATE: proxy Packet:<<128,91,0,0,1,0,2,255,0,0,0,1,8,0,0,0,0,$
0,0,0,0,0,0,0,1>> $
$
[rebalance:debug,2015-09-13T17:43:17.403-07:00,n_2@127.0.0.1:dcp_consumer_conn-default-n_0@10.0.0.29<0.1138.0>:dcp_consumer_conn:handle_cast:284]Partition 767 is about to change status to active$
[ns_server:debug,2015-09-13T17:43:17.403-07:00,n_2@127.0.0.1:dcp_consumer_conn-default-n_0@10.0.0.29<0.1138.0>:dcp_proxy:handle_packet:115]Proxy packet: RESPONSE: 0x5B (dcp_set_vbucket_state) vbucket = 0 opaque = 0x8000000 status = 0x0 (success)$
81 5B 00 00$
00 00 00 00$
00 00 00 00$
08 00 00 00$
00 00 00 00$
00 00 00 00$
$
[rebalance:debug,2015-09-13T17:43:17.403-07:00,n_2@127.0.0.1:dcp_consumer_conn-default-n_0@10.0.0.29<0.1138.0>:dcp_consumer_conn:handle_packet:133]Partition 767 changed status to active$