0

When I try to start erlang release prepared by relx it crashes with reason:

{"init terminating in do_boot",{badarg,[{erl_prim_loader,check_file_result,3,[]},{init,get_boot,1,[]},{init,get_boot,2,[]},{init,do_boot,3,[]}]}}

Directory listing:

    ├── bin
    ├── lib
    │   ├── asn1-2.0.2
    │   │   ├── ebin
    │   │   ├── priv
    │   │   └── src
    │   ├── bear-0.8.1
    │   │   ├── ebin
    │   │   └── src
    │   ├── cache-1.0.0
    │   │   ├── ebin
    │   │   ├── priv
    │   │   └── src
    │   ├── cberl-1
    │   │   ├── c_src
    │   │   ├── ebin
    │   │   ├── include
    │   │   ├── priv
    │   │   └── src
    │   ├── compiler-4.9.2
    │   │   ├── ebin
    │   │   └── src
    │   ├── cowboy-0.8.6
    │   │   ├── ebin
    │   │   └── src
....................
    │   ├── crypto-3.0
    │   │   ├── ebin
    │   │   ├── priv
    │   │   │   └── lib
    │   │   └── src
    └── releases
        └── 0.5.2

All libraries on it's own places.

I tried to start application with the command erl -env ERL_LIBS ../libs -erlconto and it successfully started.

It seems, that problem in boot file, but i don't know how to approach this problem.

Any tips or way to solve, please.

Tnx!

JasonMArcher
  • 14,195
  • 22
  • 56
  • 52
nikit
  • 153
  • 8

2 Answers2

2

I added

{extended_start_script, true}.

to relx.conf an application now work!

Tnx.

nikit
  • 153
  • 8
0

This usually happens when OTP application's .app file is missing a required dependency. relx uses the contents of .app to resolve dependencies to go into the release.

Make sure all of your release applications include, at least, kernel and stdlib in the applications tuple in .app.

Here is an example .app file listing kernel, stdlib, and elk as dependencies:

{application, prop, [
  {description, "Prop Template Generator"},
  {vsn, "0.0.1"},
  {registered, []},
  {applications, [kernel, stdlib, elk]},
  {modules, [prop, prop_otp, prop_generator]},
  {env, []}
]}.
nu-ex
  • 691
  • 4
  • 9
  • Thanks for answer! All dependencies relx sucessfully copied to lib/ folder (as shown at directory listing). And if i start application manually (without bootfile, but with set ERL_LIBS), it started. – nikit Oct 13 '14 at 08:37