参见这个 http://avindev.iteye.com/blog/100113
-hosts Hosts
Specifies the IP addresses for the hosts on which Erlang boot servers are running, see erl_boot_server(3). This flag is mandatory if the -loader inet flag is present.
The IP addresses must be given in the standard form (four decimal numbers separated by periods, for example "150.236.20.74". Hosts names are not acceptable, but a broadcast address (preferably limited to the local network) is.
-id Id
Specifies the identity of the Erlang runtime system. If it is run as a distributed node, Id must be identical to the name supplied together with the
-sname or -name flag.
-loader Loader
Specifies the method used by erl_prim_loader to load Erlang modules into the system. See erl_prim_loader(3). Two Loader methods are supported, efile and inet. efile means use the local file system, this is the default. inet means use a boot server on another machine, and the -id, -hosts and -setcookie flags must be specified as well. If Loader is something else, the user supplied Loader port program is started.
preload的模块:
struct {
char* name;
int size;
unsigned char* code;
} pre_loaded[] = {
{"otp_ring0", 512, preloaded_otp_ring0},
{"init", 19096, preloaded_init},
{"prim_inet", 25948, preloaded_prim_inet},
{"prim_file", 12264, preloaded_prim_file},
{"zlib", 4248, preloaded_zlib},
{"prim_zip", 8228, preloaded_prim_zip},
{"erl_prim_loader", 21616, preloaded_erl_prim_loader},
{"erlang", 7776, preloaded_erlang},
{0, 0, 0}
};
所以必须预加载这些基础模块以便进一步load所需的beam.
-hosts Hosts
Specifies the IP addresses for the hosts on which Erlang boot servers are running, see erl_boot_server(3). This flag is mandatory if the -loader inet flag is present.
The IP addresses must be given in the standard form (four decimal numbers separated by periods, for example "150.236.20.74". Hosts names are not acceptable, but a broadcast address (preferably limited to the local network) is.
-id Id
Specifies the identity of the Erlang runtime system. If it is run as a distributed node, Id must be identical to the name supplied together with the
-sname or -name flag.
-loader Loader
Specifies the method used by erl_prim_loader to load Erlang modules into the system. See erl_prim_loader(3). Two Loader methods are supported, efile and inet. efile means use the local file system, this is the default. inet means use a boot server on another machine, and the -id, -hosts and -setcookie flags must be specified as well. If Loader is something else, the user supplied Loader port program is started.
preload的模块:
struct {
char* name;
int size;
unsigned char* code;
} pre_loaded[] = {
{"otp_ring0", 512, preloaded_otp_ring0},
{"init", 19096, preloaded_init},
{"prim_inet", 25948, preloaded_prim_inet},
{"prim_file", 12264, preloaded_prim_file},
{"zlib", 4248, preloaded_zlib},
{"prim_zip", 8228, preloaded_prim_zip},
{"erl_prim_loader", 21616, preloaded_erl_prim_loader},
{"erlang", 7776, preloaded_erlang},
{0, 0, 0}
};
所以必须预加载这些基础模块以便进一步load所需的beam.