Here's the clue from the error output: {error,emfile}

EMFILE is an error code that indicates you have too many open files. You just 
need to adjust your ulimit settings on the new machine to allow Riak to open 
more files.

Kelly


On Dec 6, 2012, at 11:12 PM, kser <kong_...@hotmail.com> wrote:

> I need to transfer the running riak from a debian machine to a new ubuntu
> machine.
> 
> I follow this guide here:
> http://docs.basho.com/riak/1.2.0/cookbooks/Backups/
> 
> copyed the bitcask, rings, config. Then i put all this to the new machine
> that got libssl0.9.8,riak1.0.2 , rabbitmq, erlang.
> 
> After that, i start the database by sudo /etc/init.d/riak start
> 
> Riak failed to start within 15 seconds,
> see the output of 'riak console' for more information.
> If you want to wait longer, set the environment variable
> WAIT_FOR_ERLANG to the number of seconds to wait.
> 
> riak console
> 
> Exec: /usr/lib/riak/erts-5.8.4/bin/erlexec -boot
> /usr/lib/riak/releases/1.0.3/riak             -embedded -config
> /etc/riak/app.config             -pa /usr/lib/riak/basho-patches            
> -args_file /etc/riak/vm.args -- console
> Root: /usr/lib/riak
> Erlang R14B03 (erts-5.8.4) [source] [smp:2:2] [rq:2] [async-threads:64]
> [kernel-poll:true]
> 
> 17:09:02.850 [info] Application lager started on node 'r...@nodename.com'
> 17:09:02.875 [info] Application sasl started on node 'r...@nodename.com'
> 17:09:02.879 [info] Application cluster_info started on node
> 'r...@nodename.com'
> 17:09:02.887 [info] Application erlang_js started on node
> 'r...@nodename.com'
> 17:09:02.902 [info] Application os_mon started on node 'r...@nodename.com'
> 17:09:02.912 [info] Application crypto started on node 'r...@nodename.com'
> ** /usr/lib/riak/lib/observer-0.9.9/ebin/etop_txt.beam hides
> /usr/lib/riak/lib/basho-patches/etop_txt.beam
> ** Found 1 name clashes in code paths
> 17:09:02.958 [info] Application webmachine started on node
> 'r...@nodename.com'
> 17:09:02.963 [info] Application riak_sysmon started on node
> 'r...@nodename.com'
> 17:09:03.071 [info] Application riak_core started on node
> 'r...@nodename.com'
> 17:09:03.096 [info] Waiting for application riak_pipe to start (0 seconds).
> 17:09:03.096 [info] Application riak_pipe started on node
> 'r...@nodename.com'
> 17:09:03.125 [info] Application inets started on node 'r...@nodename.com'
> 17:09:03.128 [info] Application mochiweb started on node 'r...@nodename.com'
> 17:09:03.135 [info] Application luke started on node 'r...@nodename.com'
> 17:09:03.199 [info] Wait complete for application riak_pipe (0 seconds)
> 17:09:03.210 [info] Spidermonkey VM (thread stack: 16MB, max heap: 8MB,
> pool: riak_kv_js_map) host starting (<0.187.0>)
> 17:09:03.220 [info] Spidermonkey VM (thread stack: 16MB, max heap: 8MB,
> pool: riak_kv_js_map) host starting (<0.188.0>)
> 17:09:03.226 [info] Spidermonkey VM (thread stack: 16MB, max heap: 8MB,
> pool: riak_kv_js_map) host starting (<0.197.0>)
> 17:09:03.232 [info] Spidermonkey VM (thread stack: 16MB, max heap: 8MB,
> pool: riak_kv_js_map) host starting (<0.236.0>)
> 17:09:03.238 [info] Spidermonkey VM (thread stack: 16MB, max heap: 8MB,
> pool: riak_kv_js_map) host starting (<0.259.0>)
> 17:09:03.243 [info] Spidermonkey VM (thread stack: 16MB, max heap: 8MB,
> pool: riak_kv_js_map) host starting (<0.298.0>)
> 17:09:03.249 [info] Spidermonkey VM (thread stack: 16MB, max heap: 8MB,
> pool: riak_kv_js_map) host starting (<0.321.0>)
> 17:09:03.255 [info] Spidermonkey VM (thread stack: 16MB, max heap: 8MB,
> pool: riak_kv_js_map) host starting (<0.322.0>)
> 17:09:03.260 [info] Spidermonkey VM (thread stack: 16MB, max heap: 8MB,
> pool: riak_kv_js_reduce) host starting (<0.324.0>)
> 17:09:03.265 [info] Spidermonkey VM (thread stack: 16MB, max heap: 8MB,
> pool: riak_kv_js_reduce) host starting (<0.325.0>)
> 17:09:03.271 [info] Spidermonkey VM (thread stack: 16MB, max heap: 8MB,
> pool: riak_kv_js_reduce) host starting (<0.326.0>)
> 17:09:03.276 [info] Spidermonkey VM (thread stack: 16MB, max heap: 8MB,
> pool: riak_kv_js_reduce) host starting (<0.327.0>)
> 17:09:03.281 [info] Spidermonkey VM (thread stack: 16MB, max heap: 8MB,
> pool: riak_kv_js_reduce) host starting (<0.328.0>)
> 17:09:03.287 [info] Spidermonkey VM (thread stack: 16MB, max heap: 8MB,
> pool: riak_kv_js_reduce) host starting (<0.329.0>)
> 17:09:03.292 [info] Spidermonkey VM (thread stack: 16MB, max heap: 8MB,
> pool: riak_kv_js_hook) host starting (<0.331.0>)
> 17:09:03.298 [info] Spidermonkey VM (thread stack: 16MB, max heap: 8MB,
> pool: riak_kv_js_hook) host starting (<0.332.0>)
> 17:09:03.316 [info] Application bitcask started on node 'r...@nodename.com'
> 17:09:03.469 [info] Waiting for application riak_kv to start (0 seconds).
> 17:09:03.473 [info] Application riak_kv started on node 'r...@nodename.com'
> 17:09:03.474 [info] Application skerl started on node 'r...@nodename.com'
> 17:09:03.476 [info] Application luwak started on node 'r...@nodename.com'
> 17:09:03.484 [info] Application merge_index started on node
> 'r...@nodename.com'
> 17:09:03.487 [info] Application riak_search started on node
> 'r...@nodename.com'
> 17:09:03.487 [info] Application basho_stats started on node
> 'r...@nodename.com'
> 17:09:03.503 [info] Application runtime_tools started on node
> 'r...@nodename.com'
> 17:09:03.503 [info] Application public_key started on node
> 'r...@nodename.com'
> 17:09:03.523 [info] Application ssl started on node 'r...@nodename.com'
> Eshell V5.8.4  (abort with ^G)
> (r...@nodename.com)1> 17:09:03.571 [info] Wait complete for application
> riak_kv (0 seconds)
> 17:09:30.259 [error] Failed to start riak_kv_bitcask_backend Reason:
> {{badmatch,{error,{error,emfile}}},[{bitcask,scan_key_files,3},{bitcask,init_keydir,2},{bitcask,open,2},{riak_kv_bitcask_backend,start,2},{riak_kv_vnode,init,1},{riak_core_vnode,init,1},{gen_fsm,init_it,6},{proc_lib,init_p_do_apply,3}]}
> 17:09:30.368 [notice] "backend module failed to start."
> 17:09:30.369 [error] gen_server riak_kv_vnode_master terminated with reason:
> no match of right hand value
> {error,{{case_clause,ok},[{riak_core_vnode,init,1},{gen_fsm,init_it,6},{proc_lib,init_p_do_apply,3}]}}
> in riak_core_vnode_master:get_vnode/2
> 17:09:30.375 [info] Spidermonkey VM (pool: riak_kv_js_hook) host stopping
> (<0.331.0>)
> 17:09:30.375 [info] Spidermonkey VM (pool: riak_kv_js_hook) host stopping
> (<0.332.0>)
> 17:09:30.376 [info] Spidermonkey VM (pool: riak_kv_js_reduce) host stopping
> (<0.326.0>)
> 17:09:30.376 [info] Spidermonkey VM (pool: riak_kv_js_reduce) host stopping
> (<0.324.0>)
> 17:09:30.377 [info] Spidermonkey VM (pool: riak_kv_js_reduce) host stopping
> (<0.327.0>)
> 17:09:30.377 [info] Spidermonkey VM (pool: riak_kv_js_reduce) host stopping
> (<0.325.0>)
> 17:09:30.377 [info] Spidermonkey VM (pool: riak_kv_js_reduce) host stopping
> (<0.329.0>)
> 17:09:30.377 [info] Spidermonkey VM (pool: riak_kv_js_map) host stopping
> (<0.187.0>)
> 17:09:30.378 [info] Spidermonkey VM (pool: riak_kv_js_reduce) host stopping
> (<0.328.0>)
> 17:09:30.378 [info] Spidermonkey VM (pool: riak_kv_js_map) host stopping
> (<0.188.0>)
> 17:09:30.379 [info] Spidermonkey VM (pool: riak_kv_js_map) host stopping
> (<0.236.0>)
> 17:09:30.379 [info] Spidermonkey VM (pool: riak_kv_js_map) host stopping
> (<0.197.0>)
> 17:09:30.379 [info] Spidermonkey VM (pool: riak_kv_js_map) host stopping
> (<0.259.0>)
> 17:09:30.379 [info] Spidermonkey VM (pool: riak_kv_js_map) host stopping
> (<0.321.0>)
> 17:09:30.380 [info] Spidermonkey VM (pool: riak_kv_js_map) host stopping
> (<0.298.0>)
> /usr/lib/riak/lib/os_mon-2.2.6/priv/bin/memsup: Erlang has closed.
>                                                                   Erlang
> has closed
> 
> 17:09:32.852 [error] CRASH REPORT Process riak_kv_vnode_master with 0
> neighbours crashed with reason: no match of right hand value
> {error,{{case_clause,ok},[{riak_core_vnode,init,1},{gen_fsm,init_it,6},{proc_lib,init_p_do_apply,3}]}}
> in riak_core_vnode_master:get_vnode/2
> 17:09:32.902 [error] CRASH REPORT Process <0.937.0> with 0 neighbours
> crashed with reason: no case clause matching ok in riak_core_vnode:init/1
> 17:09:32.943 [error] Supervisor riak_core_vnode_sup had child undefined
> started with {riak_core_vnode,start_link,undefined} at <0.937.0> exit with
> reason no case clause matching ok in riak_core_vnode:init/1 in context
> child_terminated
> 17:09:33.027 [error] Supervisor riak_kv_sup had child riak_kv_vnode_master
> started with riak_core_vnode_master:start_link(riak_kv_vnode,
> riak_kv_legacy_vnode) at <0.170.0> exit with reason no match of right hand
> value
> {error,{{case_clause,ok},[{riak_core_vnode,init,1},{gen_fsm,init_it,6},{proc_lib,init_p_do_apply,3}]}}
> in riak_core_vnode_master:get_vnode/2 in context child_terminated
> 
> 
> 
> 
> --
> View this message in context: 
> http://riak-users.197444.n3.nabble.com/Transfer-database-to-new-machines-fail-tp4026198.html
> Sent from the Riak Users mailing list archive at Nabble.com.
> 
> _______________________________________________
> riak-users mailing list
> riak-users@lists.basho.com
> http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com


_______________________________________________
riak-users mailing list
riak-users@lists.basho.com
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com

Reply via email to