From rebar2 to rebar3

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

From rebar2 to rebar3

Grigory Fateyev-2
Hello!

We have a big project with a lot of dependencies and legacy code. I have a task to move it to rebar3. I could compile and make a release, but couldn't start it. It returns me:

{error_logger,{{2018,5,25},{11,30,16}},crash_report,[[{initial_call,{supervisor,kernel,['Argument__1']}},{pid,<0.1970.0>},{registered_name,[]},{error_info,{exit,{on_load_function_failed,riak_ensemble_clock},[{gen_server,init_it,6,[{file,"gen_server.erl"},{line,328}]},{proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,239}]}]}},{ancestors,[kernel_sup,<0.1946.0>]},{messages,[]},{links,[<0.1947.0>]},{dictionary,[]},{trap_exit,true},{status,running},{heap_size,376},{stack_size,27},{reductions,124}],[]]}
{error_logger,{{2018,5,25},{11,30,16}},supervisor_report,[{supervisor,{local,kernel_sup}},{errorContext,start_error},{reason,{on_load_function_failed,riak_ensemble_clock}},{offender,[{pid,undefined},{name,kernel_safe_sup},{mfargs,{supervisor,start_link,[{local,kernel_safe_sup},kernel,safe]}},{restart_type,permanent},{shutdown,infinity},{child_type,supervisor}]}]}
{error_logger,{{2018,5,25},{11,30,17}},crash_report,[[{initial_call,{application_master,init,['Argument__1','Argument__2','Argument__3','Argument__4']}},{pid,<0.1945.0>},{registered_name,[]},{error_info,{exit,{{shutdown,{failed_to_start_child,kernel_safe_sup,{on_load_function_failed,riak_ensemble_clock}}},{kernel,start,[normal,[]]}},[{application_master,init,4,[{file,"application_master.erl"},{line,133}]},{proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,239}]}]}},{ancestors,[<0.1944.0>]},{messages,[{'EXIT',<0.1946.0>,normal}]},{links,[<0.1944.0>,<0.1943.0>]},{dictionary,[]},{trap_exit,true},{status,running},{heap_size,376},{stack_size,27},{reductions,163}],[]]}

I have two theories why it so, either not all deps in the release or don't start needed apps. How to understand the issue? I've read 'crash.dump', but it has a few info to get the reason.

Thank you!

_______________________________________________
erlang-questions mailing list
[hidden email]
http://erlang.org/mailman/listinfo/erlang-questions
Reply | Threaded
Open this post in threaded view
|

Re: From rebar2 to rebar3

Taavi Talvik-2
This log indicates, that

failure is in ‘on_load_function_fail’, which tries to load ‘riak_ensemble_clock'
- this is module trying to load NIF i.e. natively implemented function i.e. C-compiled module
- quite likely something bad had happened and C module is not compiled correctly and is not present

Google indicates, that people have struggled with similar problems before
and had to help rebar configuration

https://github.com/basho/riak_ensemble/issues/122

Maybe this will help you further..

best regards,
taavi


> On 25 May 2018, at 15:22, Grigory Fateyev <[hidden email]> wrote:
>
> Hello!
>
> We have a big project with a lot of dependencies and legacy code. I have a task to move it to rebar3. I could compile and make a release, but couldn't start it. It returns me:
>
> {error_logger,{{2018,5,25},{11,30,16}},crash_report,[[{initial_call,{supervisor,kernel,['Argument__1']}},{pid,<0.1970.0>},{registered_name,[]},{error_info,{exit,{on_load_function_failed,riak_ensemble_clock},[{gen_server,init_it,6,[{file,"gen_server.erl"},{line,328}]},{proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,239}]}]}},{ancestors,[kernel_sup,<0.1946.0>]},{messages,[]},{links,[<0.1947.0>]},{dictionary,[]},{trap_exit,true},{status,running},{heap_size,376},{stack_size,27},{reductions,124}],[]]}
> {error_logger,{{2018,5,25},{11,30,16}},supervisor_report,[{supervisor,{local,kernel_sup}},{errorContext,start_error},{reason,{on_load_function_failed,riak_ensemble_clock}},{offender,[{pid,undefined},{name,kernel_safe_sup},{mfargs,{supervisor,start_link,[{local,kernel_safe_sup},kernel,safe]}},{restart_type,permanent},{shutdown,infinity},{child_type,supervisor}]}]}
> {error_logger,{{2018,5,25},{11,30,17}},crash_report,[[{initial_call,{application_master,init,['Argument__1','Argument__2','Argument__3','Argument__4']}},{pid,<0.1945.0>},{registered_name,[]},{error_info,{exit,{{shutdown,{failed_to_start_child,kernel_safe_sup,{on_load_function_failed,riak_ensemble_clock}}},{kernel,start,[normal,[]]}},[{application_master,init,4,[{file,"application_master.erl"},{line,133}]},{proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,239}]}]}},{ancestors,[<0.1944.0>]},{messages,[{'EXIT',<0.1946.0>,normal}]},{links,[<0.1944.0>,<0.1943.0>]},{dictionary,[]},{trap_exit,true},{status,running},{heap_size,376},{stack_size,27},{reductions,163}],[]]}
>
> I have two theories why it so, either not all deps in the release or don't start needed apps. How to understand the issue? I've read 'crash.dump', but it has a few info to get the reason.
>
> Thank you!
> _______________________________________________
> erlang-questions mailing list
> [hidden email]
> http://erlang.org/mailman/listinfo/erlang-questions

_______________________________________________
erlang-questions mailing list
[hidden email]
http://erlang.org/mailman/listinfo/erlang-questions
Reply | Threaded
Open this post in threaded view
|

Re: From rebar2 to rebar3

Grigory Fateyev-2
Taavi, thank you!

Your advice is very close to the reason. At least I got another error related to eleveldb.

2018-05-25 15:42 GMT+03:00 <[hidden email]>:
This log indicates, that

failure is in ‘on_load_function_fail’, which tries to load ‘riak_ensemble_clock'
- this is module trying to load NIF i.e. natively implemented function i.e. C-compiled module
- quite likely something bad had happened and C module is not compiled correctly and is not present

Google indicates, that people have struggled with similar problems before
and had to help rebar configuration

https://github.com/basho/riak_ensemble/issues/122

Maybe this will help you further..

best regards,
taavi


> On 25 May 2018, at 15:22, Grigory Fateyev <[hidden email]> wrote:
>
> Hello!
>
> We have a big project with a lot of dependencies and legacy code. I have a task to move it to rebar3. I could compile and make a release, but couldn't start it. It returns me:
>
> {error_logger,{{2018,5,25},{11,30,16}},crash_report,[[{initial_call,{supervisor,kernel,['Argument__1']}},{pid,<0.1970.0>},{registered_name,[]},{error_info,{exit,{on_load_function_failed,riak_ensemble_clock},[{gen_server,init_it,6,[{file,"gen_server.erl"},{line,328}]},{proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,239}]}]}},{ancestors,[kernel_sup,<0.1946.0>]},{messages,[]},{links,[<0.1947.0>]},{dictionary,[]},{trap_exit,true},{status,running},{heap_size,376},{stack_size,27},{reductions,124}],[]]}
> {error_logger,{{2018,5,25},{11,30,16}},supervisor_report,[{supervisor,{local,kernel_sup}},{errorContext,start_error},{reason,{on_load_function_failed,riak_ensemble_clock}},{offender,[{pid,undefined},{name,kernel_safe_sup},{mfargs,{supervisor,start_link,[{local,kernel_safe_sup},kernel,safe]}},{restart_type,permanent},{shutdown,infinity},{child_type,supervisor}]}]}
> {error_logger,{{2018,5,25},{11,30,17}},crash_report,[[{initial_call,{application_master,init,['Argument__1','Argument__2','Argument__3','Argument__4']}},{pid,<0.1945.0>},{registered_name,[]},{error_info,{exit,{{shutdown,{failed_to_start_child,kernel_safe_sup,{on_load_function_failed,riak_ensemble_clock}}},{kernel,start,[normal,[]]}},[{application_master,init,4,[{file,"application_master.erl"},{line,133}]},{proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,239}]}]}},{ancestors,[<0.1944.0>]},{messages,[{'EXIT',<0.1946.0>,normal}]},{links,[<0.1944.0>,<0.1943.0>]},{dictionary,[]},{trap_exit,true},{status,running},{heap_size,376},{stack_size,27},{reductions,163}],[]]}
>
> I have two theories why it so, either not all deps in the release or don't start needed apps. How to understand the issue? I've read 'crash.dump', but it has a few info to get the reason.
>
> Thank you!
> _______________________________________________
> erlang-questions mailing list
> [hidden email]
> http://erlang.org/mailman/listinfo/erlang-questions



_______________________________________________
erlang-questions mailing list
[hidden email]
http://erlang.org/mailman/listinfo/erlang-questions
Reply | Threaded
Open this post in threaded view
|

Re: From rebar2 to rebar3

Heinz N. Gies
Hi Gregory,
You can use the riak_* components from the riak_core_ng/Kyorai fork [1] they all build with both modern erlang and rebar3 also exist as hex packages (if you are into that kind of thing).

Cheers,
Heinz 

[1] http://github.com/Kyorai/

On 25. May 2018, at 15:26, Grigory Fateyev <[hidden email]> wrote:

Taavi, thank you!

Your advice is very close to the reason. At least I got another error related to eleveldb.

2018-05-25 15:42 GMT+03:00 <[hidden email]>:
This log indicates, that

failure is in ‘on_load_function_fail’, which tries to load ‘riak_ensemble_clock'
- this is module trying to load NIF i.e. natively implemented function i.e. C-compiled module
- quite likely something bad had happened and C module is not compiled correctly and is not present

Google indicates, that people have struggled with similar problems before
and had to help rebar configuration

https://github.com/basho/riak_ensemble/issues/122

Maybe this will help you further..

best regards,
taavi


> On 25 May 2018, at 15:22, Grigory Fateyev <[hidden email]> wrote:
>
> Hello!
>
> We have a big project with a lot of dependencies and legacy code. I have a task to move it to rebar3. I could compile and make a release, but couldn't start it. It returns me:
>
> {error_logger,{{2018,5,25},{11,30,16}},crash_report,[[{initial_call,{supervisor,kernel,['Argument__1']}},{pid,<0.1970.0>},{registered_name,[]},{error_info,{exit,{on_load_function_failed,riak_ensemble_clock},[{gen_server,init_it,6,[{file,"gen_server.erl"},{line,328}]},{proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,239}]}]}},{ancestors,[kernel_sup,<0.1946.0>]},{messages,[]},{links,[<0.1947.0>]},{dictionary,[]},{trap_exit,true},{status,running},{heap_size,376},{stack_size,27},{reductions,124}],[]]}
> {error_logger,{{2018,5,25},{11,30,16}},supervisor_report,[{supervisor,{local,kernel_sup}},{errorContext,start_error},{reason,{on_load_function_failed,riak_ensemble_clock}},{offender,[{pid,undefined},{name,kernel_safe_sup},{mfargs,{supervisor,start_link,[{local,kernel_safe_sup},kernel,safe]}},{restart_type,permanent},{shutdown,infinity},{child_type,supervisor}]}]}
> {error_logger,{{2018,5,25},{11,30,17}},crash_report,[[{initial_call,{application_master,init,['Argument__1','Argument__2','Argument__3','Argument__4']}},{pid,<0.1945.0>},{registered_name,[]},{error_info,{exit,{{shutdown,{failed_to_start_child,kernel_safe_sup,{on_load_function_failed,riak_ensemble_clock}}},{kernel,start,[normal,[]]}},[{application_master,init,4,[{file,"application_master.erl"},{line,133}]},{proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,239}]}]}},{ancestors,[<0.1944.0>]},{messages,[{'EXIT',<0.1946.0>,normal}]},{links,[<0.1944.0>,<0.1943.0>]},{dictionary,[]},{trap_exit,true},{status,running},{heap_size,376},{stack_size,27},{reductions,163}],[]]}
>
> I have two theories why it so, either not all deps in the release or don't start needed apps. How to understand the issue? I've read 'crash.dump', but it has a few info to get the reason.
>
> Thank you!
> _______________________________________________
> erlang-questions mailing list
> [hidden email]
> http://erlang.org/mailman/listinfo/erlang-questions


_______________________________________________
erlang-questions mailing list
[hidden email]
http://erlang.org/mailman/listinfo/erlang-questions


_______________________________________________
erlang-questions mailing list
[hidden email]
http://erlang.org/mailman/listinfo/erlang-questions

signature.asc (849 bytes) Download Attachment