Urgent: BigCouch data/shards unaccessible

42 views
Skip to first unread message

David Melamed

unread,
Dec 11, 2014, 4:31:01 PM12/11/14
to bigcou...@googlegroups.com
Hi guys,

I am running a cluster of 3 instances of bigcouch on AWS (v1.0.4).

I hope you will be able to help me understand the issue I have currently with bigcouch which started out of the blue, the log is full of errors like:

[Thu, 11 Dec 2014 20:57:57 GMT] [error] [emulator] [--------] Error in process <0.10526.0> on node 'bigcouch@XXXXX' with exit value: {{{badmatch,{error,eacces}},[{couch_file,init,1},{gen_server,init_it,6},{proc_lib,init_p_do_apply,3}]},[{mem3_rep,rexi_call,2},{mem3_rep,calculate_start_seq,3},{mem3_rep,go,3},{mem3_rep,go,2}]}

In addition, there were a lot of errors like:

[Thu, 11 Dec 2014 19:18:19 GMT] [error] [<0.9978.0>] [88d9fad5] Uncaught error in HTTP request: {error,
                                                                 {case_clause,
                                                                  {function_clause,
                                                                   [{fabric_doc_update,
                                                                     handle_message,
                                                                     [{{badmatch,
                                                                        {error,
                                                                         eacces}},
                                                                       [{couch_file,
                                                                         init,
                                                                         1},
                                                                        {gen_server,
                                                                         init_it,
                                                                         6},
                                                                        {proc_lib,
                                                                         init_p_do_apply,
                                                                         3}]},
                                                                      {shard,
                                                                       <<"shards/e0000000-ffffffff/main.1378650736">>,
                                                                       'bigcouch@XXXXXX',
                                                                       <<"main">>,
                                                                       [3758096384,
                                                                        4294967295],
                                                                       #Ref<0.0.0.65468>},
                                                                      {3,1,2,
                                                                       [{{shard,
                                                                          <<"shards/e0000000-ffffffff/main.1378650736">>,
                                                                          'bigcouch@XXXXX',
                                                                          <<"main">>,
                                                                          [3758096384,
                                                                           4294967295],
                                                                          #Ref<0.0.0.65466>},
                                                                         [{doc,
                                                                           <<"300b81ab89a25f9ec1a31cbbf87accc4">>,
                                                                           {1,
                                                                         [....]
                                                                          [[{doc,
                                                                             <<"300b81ab89a25f9ec1a31cbbf87accc4">>,
                                                                             {1,
                                                                              [<<180,47,
                                                                                 98,45,
                                                                                 112,164,
                                                                                 82,97,
                                                                                 204,179,
                                                                                 67,89,
                                                                                 132,52,
                                                                                 181,22>>]},
                                                                             {[{<<"Type">>,
                                                                               {<<"Shared">>,
                                                                                <<"null">>},
                                                                               {<<"ThirdPartyID">>,
                                                                                null}]},
                                                                             [],
                                                                             false,
                                                                             []}]],
                                                                          [],
                                                                          [],
                                                                          [],
                                                                          [],
                                                                          [],
                                                                          [],
                                                                          [],
                                                                          [],
                                                                          [],
                                                                          []}}}}]},
                                                                    {rexi_utils,
                                                                     process_mailbox,
                                                                     6},
                                                                    {rexi_utils,
                                                                     recv,6},
                                                                    {fabric_doc_update,
                                                                     go,3},
                                                                    {fabric,
                                                                     update_docs,
                                                                     3},
                                                                    {fabric,
                                                                     update_doc,
                                                                     3},
                                                                    {chttpd_db,
                                                                     '-update_doc/6-fun-0-',
                                                                     3}]}}}
[Thu, 11 Dec 2014 19:18:19 GMT] [info] [<0.9978.0>] [88d9fad5] Stacktrace: [{chttpd_db,update_doc,6},
                                            {chttpd,handle_request,1},
                                            {mochiweb_http,headers,5},
                                            {proc_lib,init_p_do_apply,3}]


Since a few min ago, the data is unaccessible (though I have access to the UI - futon, I cannot enter in any doc or design doc or view - I get an error doc is "null"). 
Is the data lost? Can I save it?

Thanks a lot for your help.

 

David Melamed

unread,
Dec 11, 2014, 6:08:27 PM12/11/14
to bigcou...@googlegroups.com
For those interested, the issue was found with the help of Cloudant's CTO.
When restarting the database using the script in init.d instead of the service, the ownership of the shard files were changed to 'root' (instead of the user 'bigcouch'). Changing back the ownership fixed the issue.
Reply all
Reply to author
Forward
0 new messages