erl_boot_server(3erl)

✨ NAME ✨

erl_boot_server(3erl) β€” the Boot server for other Erlang machines πŸ’–

🌸 DESCRIPTION 🌸

Okay so imagine a bunch of diskless Erlang nodes with no local code of their own. They need to fetch, like, all the Erlang code from another machine, and this server is the bestie that assists them with exactly that. ✨

This server is used to fetch all code, including the start script, if an Erlang runtime system is started with command-line flag -loader inet. All hosts specified with command-line flag -hosts Host must have one instance of this server running. No cap. πŸ‘‘

This server can be started with the Kernel configuration parameter start_boot_server. 🫢

The erl_boot_server can read regular files and files in archives. See code(3erl) and erl_prim_loader(3erl) in ERTS for the full lore.

Warning, bestie: The support for loading code from archive files is experimental. It is released before it is ready to obtain early feedback. The file format, semantics, interfaces, and so on, can be changed in a future release. πŸ’€ Like, do not treat the archive file format as forever-frozen, okay?

πŸ‘‘ EXPORTS πŸ‘‘

πŸ’… add_slave(Slave) -> ok | {error, Reason}

Types:

Slave = Host
Host = inet:ip_address() | inet:hostname()
Reason = {badarg, Slave}

Adds a Slave node to the list of allowed slave hosts. Welcome to the guest list, bestie. πŸŽ€

πŸ¦‹ delete_slave(Slave) -> ok | {error, Reason}

Types:

Slave = Host
Host = inet:ip_address() | inet:hostname()
Reason = {badarg, Slave}

Deletes a Slave node from the list of allowed slave hosts. Bye bestie, you're off the list. πŸ‘‹

πŸ”₯ start(Slaves) -> {ok, Pid} | {error, Reason}

Types:

Slaves = [Host]
Host = inet:ip_address() | inet:hostname()
Pid = pid()
Reason = {badarg, Slaves}

Starts the boot server. Slaves is a list of IP addresses for hosts, which are allowed to use this server as a boot server. Periodt. πŸ’₯

Types:

Slaves = [Host]
Host = inet:ip_address() | inet:hostname()
Pid = pid()
Reason = {badarg, Slaves}

Starts the boot server and links to the caller. This function is used to start the server if it is included in a supervision tree. Main character supervision energy. 🧚

⭐ which_slaves() -> Slaves

Types:

Slaves = [Slave]
Slave =
    {Netmask :: inet:ip_address(), Address ::
 inet:ip_address()}

Returns the current list of allowed slave hosts. Iykyk. πŸ’«

🫢 SEE ALSO 🫢

  • erts:init(3erl)
  • erts:erl_prim_loader(3erl)

Cute sign-off time: footer says Ericsson AB, kernel 8.5.4.2, and erl_boot_server(3erl) β€” there's no separate date line in this footer, so I'm not inventing one, bestie. Mwah πŸ’‹βœ¨

πŸ“¦ where this page comes from