Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't ping or access remote_console after updating Erlang and Elixir #734

Open
Pedneri1 opened this issue Oct 5, 2020 · 1 comment
Open

Comments

@Pedneri1
Copy link

Pedneri1 commented Oct 5, 2020

Steps to reproduce and Description of issue

Hello! I’m having trouble accessing the remote_console after updating Elixir and Erlang on my build server.
Everything starts up normally using the command my_app/bin/my_app foreground but when I try to run my_app/bin/my_app remote_console the application crashes and these errors appear:

1- On the console I ran foreground

19:44:23.509 [error] GenServer :net_kernel terminating
** (stop) bad return value: {:EXIT, {:undef, [{:erts_internal, :abort_connection, [:"[email protected]", {1, #Reference<0.321614115.3871473665.124992>}], []}]}}
Last message: {:EXIT, #PID<0.4889.0>, {:badarg, [{:erlang, :setnode, [:"[email protected]", #Port<0.68>, {31424444, 5, :"", :""}], []}]}}
{"Kernel pid terminated",application_controller,"{application_terminated,kernel,shutdown}"}
Kernel pid terminated (application_controller) ({application_terminated,kernel,shutdown})

2- On the other console that I ran remote_console or ping

** (exit) exited in: :gen_server.call(:net_kernel, {:connect, :hidden, :"[email protected]"}, :infinity)
    ** (EXIT) bad return value: {:EXIT, {:undef, [{:erts_internal, :abort_connection, [:"[email protected]", {1, #Reference<0.2859229408.4140957697.178983>}], []}, {:net_kernel, :pending_nodedown, 4, [file: 'net_kernel.erl', line: 980]}, {:net_kernel, :conn_own_exit, 3, [file: 'net_kernel.erl', line: 907]}, {:net_kernel, :do_handle_exit, 3, [file: 'net_kernel.erl', line: 875]}, {:net_kernel, :handle_exit, 3, [file: 'net_kernel.erl', line: 870]}, {:gen_server, :try_dispatch, 4, [file: 'gen_server.erl', line: 637]}, {:gen_server, :handle_msg, 6, [file: 'gen_server.erl', line: 711]}, {:proc_lib, :init_p_do_apply, 3, [file: 'proc_lib.erl', line: 249]}]}}
    (stdlib) gen_server.erl:223: :gen_server.call/3
    lib/distillery/releases/runtime/control.ex:1006: Distillery.Releases.Runtime.Control.hidden_connect/1
    lib/distillery/releases/runtime/control.ex:438: Distillery.Releases.Runtime.Control.ping/2
    lib/entry.ex:47: Distillery.Releases.Runtime.Control.main/1
    (stdlib) erl_eval.erl:680: :erl_eval.do_apply/6
    (elixir) lib/code.ex:240: Code.eval_string/3 

Note: The same happens when running using my_app/bin/my_app start

elixir --version on build Server:
Elixir 1.10.4
Erlang/OTP 23

elixir --version on execution Server:
Elixir 1.10.4
Erlang/OTP 23

Distillery is running on version 2.1 and Edeliver on 1.7

The OS is Ubuntu 18.4 on both build and execution servers

@manuel-rubio
Copy link

Looks like you're not including the system (ERTS or BEAM) into the build, so when you're updating the ERTS system (Erlang) it's disappearing without telling the previous system to upgrade to the new one. My advice, include always the system into a release to avoid this. Usually, into the rel/config.exs you should have:

environment :prod do
  set include_erts: true
  ...

If you are building using the dev environment that could be the reason because it's not working. Try building with this:

MIX_ENV=prod mix distillery.release

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants