Merge pull request #10457 from rabbitmq/md-check-epmd-before-starting

Check whether EPMD is running before starting it
This commit is contained in:
Michael Klishin 2024-02-01 18:55:24 -05:00 committed by GitHub
commit 1aa9e13b93
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 8 additions and 0 deletions

View File

@ -107,6 +107,14 @@ epmd_port() ->
end.
ensure_epmd() ->
case net_adm:names() of
{ok, _Names} ->
ok;
_ ->
start_epmd()
end.
start_epmd() ->
Exe = rabbit_runtime:get_erl_path(),
ID = rabbit_misc:random(1000000000),
Port = open_port(