1erl(1)                           User Commands                          erl(1)
2
3
4

NAME

6       erl - The Erlang emulator.
7

DESCRIPTION

9       The erl program starts an Erlang runtime system. The exact details (for
10       example, whether erl is a script or a program and which other  programs
11       it calls) are system-dependent.
12
13       Windows users probably want to use the werl program instead, which runs
14       in its own window with scrollbars and  supports  command-line  editing.
15       The  erl  program on Windows provides no line editing in its shell, and
16       on Windows 95 there is no way to scroll back to text that has  scrolled
17       off  the screen. The erl program must be used, however, in pipelines or
18       if you want to redirect standard input or output.
19
20   Note:
21       As from ERTS 5.9 (Erlang/OTP R15B) the runtime system does  by  default
22       not  bind  schedulers  to logical processors. For more information, see
23       system flag +sbt.
24
25

EXPORTS

27       erl <arguments>
28
29              Starts an Erlang runtime system.
30
31              The arguments can be divided into  emulator  flags,  flags,  and
32              plain arguments:
33
34                * Any  argument starting with character + is interpreted as an
35                  emulator flag.
36
37                  As indicated by the name, emulator flags control the  behav‐
38                  ior of the emulator.
39
40                * Any  argument  starting  with character - (hyphen) is inter‐
41                  preted as a flag, which is to be passed to the  Erlang  part
42                  of  the runtime system, more specifically to the init system
43                  process, see init(3).
44
45                  The init process itself interprets some of these flags,  the
46                  init  flags.  It  also  stores any remaining flags, the user
47                  flags. The latter can be retrieved by calling init:get_argu‐
48                  ment/1.
49
50                  A  small  number  of "-" flags exist, which now actually are
51                  emulator flags, see the description below.
52
53                * Plain arguments are not interpreted in  any  way.  They  are
54                  also  stored  by  the  init  process and can be retrieved by
55                  calling init:get_plain_arguments/0. Plain arguments can  oc‐
56                  cur  before  the  first  flag, or after a -- flag. Also, the
57                  -extra flag causes everything that follows to  become  plain
58                  arguments.
59
60              Examples:
61
62              % erl +W w -sname arnie +R 9 -s my_init -extra +bertie
63              (arnie@host)1> init:get_argument(sname).
64              {ok,[["arnie"]]}
65              (arnie@host)2> init:get_plain_arguments().
66              ["+bertie"]
67
68              Here  +W  w  and  +R 9 are emulator flags. -s my_init is an init
69              flag, interpreted by init. -sname arnie is a user  flag,  stored
70              by init. It is read by Kernel and causes the Erlang runtime sys‐
71              tem to become  distributed.  Finally,  everything  after  -extra
72              (that is, +bertie) is considered as plain arguments.
73
74              % erl -myflag 1
75              1> init:get_argument(myflag).
76              {ok,[["1"]]}
77              2> init:get_plain_arguments().
78              []
79
80              Here the user flag -myflag 1 is passed to and stored by the init
81              process. It is a user-defined  flag,  presumably  used  by  some
82              user-defined application.
83

FLAGS

85       In the following list, init flags are marked "(init flag)". Unless oth‐
86       erwise specified, all other flags are user flags, for which the  values
87       can  be  retrieved by calling init:get_argument/1. Notice that the list
88       of user flags is not exhaustive, there can be more application-specific
89       flags that instead are described in the corresponding application docu‐
90       mentation.
91
92         -- (init flag):
93           Everything following -- up to the next flag  (-flag  or  +flag)  is
94           considered   plain   arguments   and   can   be   retrieved   using
95           init:get_plain_arguments/0.
96
97         -Application Par Val:
98           Sets the application configuration parameter Par to the  value  Val
99           for the application Application; see app(4) and application(3).
100
101         -args_file FileName:
102           Command-line  arguments  are read from the file FileName. The argu‐
103           ments read from the file replace flag '-args_file FileName' on  the
104           resulting command line.
105
106           The  file  FileName is to be a plain text file and can contain com‐
107           ments and command-line arguments. A comment begins with a # charac‐
108           ter  and  continues until the next end of line character. Backslash
109           (\\) is used as quoting character. All command-line  arguments  ac‐
110           cepted  by erl are allowed, also flag -args_file FileName. Be care‐
111           ful not to cause circular  dependencies  between  files  containing
112           flag -args_file, though.
113
114           The  flag  -extra  is treated in special way. Its scope ends at the
115           end of the file. Arguments following an -extra flag  are  moved  on
116           the  command  line into the -extra section, that is, the end of the
117           command line following after an -extra flag.
118
119         -async_shell_start:
120           The initial Erlang shell does not read user input until the  system
121           boot  procedure has been completed (Erlang/OTP 5.4 and later). This
122           flag disables the start synchronization feature and lets the  shell
123           start in parallel with the rest of the system.
124
125         -boot File:
126           Specifies  the  name  of the boot file, File.boot, which is used to
127           start the system; see init(3). Unless  File  contains  an  absolute
128           path,  the  system  searches  for  File.boot  in  the  current  and
129           $ROOT/bin directories.
130
131           Defaults to $ROOT/bin/start.boot.
132
133         -boot_var Var Dir:
134           If the boot script contains a path variable Var other  than  $ROOT,
135           this  variable  is  expanded to Dir. Used when applications are in‐
136           stalled   in   another   directory   than   $ROOT/lib;   see   sys‐
137           tools:make_script/1,2 in SASL.
138
139         -code_path_cache:
140           Enables the code path cache of the code server; see code(3).
141
142         -compile Mod1 Mod2 ...:
143           Compiles  the  specified modules and then terminates (with non-zero
144           exit code if the compilation of some file did not succeed). Implies
145           -noinput.
146
147           Not recommended; use erlc instead.
148
149         -config Config [Config ...]:
150           Specifies  the name of one or more configuration files, Config.con‐
151           fig, which is used to configure applications; see app(4) and appli‐
152           cation(3).  See the documentation for the configuration file format
153           for a description of the configuration  format  and  the  order  in
154           which configuration parameters are read.
155
156         -configfd FD [FD ...]:
157           Specifies the name of one or more file descriptors (called configu‐
158           ration file descriptors from here on) with configuration  data  for
159           applications;  see app(4) and application(3). See the documentation
160           for the configuration file format for a description of the configu‐
161           ration  format  and the order in which configuration parameters are
162           read.
163
164           A configuration file descriptor will be read until its end and will
165           then be closed.
166
167           The content of a configuration file descriptor is stored so that it
168           can be reused when init:restart/0 or init:restart/1 is called.
169
170           The parameter -configfd 0 implies -noinput.
171
172     Note:
173         It is not recommended to use file descriptors  1  (standard  output),
174         and 2 (standard error) together with -configfd as these file descrip‐
175         tors are typically used to print information to the console the  pro‐
176         gram is running in.
177
178
179           Examples (Unix shell):
180
181         $ erl \ -noshell \ -configfd 3 \ -eval \ 'io:format("~p~n",[application:get_env(kernel, logger_level)]),erlang:halt()' 3< \ <(echo '[{kernel, [{logger_level, warning}]}].')
182         {ok,warning}
183
184
185         $ echo '[{kernel, [{logger_level, warning}]}].' > test1.config
186         $ echo '[{kernel, [{logger_level, error}]}].' > test2.config
187         $ erl \ -noshell \ -configfd 3 \ -configfd 4 \ -eval \ 'io:format("~p~n",[application:get_env(kernel, logger_level)]),erlang:halt()' \ 3< test1.config 4< test2.config
188         {ok,error}
189
190
191         -connect_all false:
192           This  flag is deprecated and has been replaced by the kernel appli‐
193           cation parameter connect_all.
194
195         -cookie Cookie:
196           Obsolete flag without any effect and common misspelling  for  -set‐
197           cookie. Use -setcookie instead.
198
199         -detached:
200           Starts  the Erlang runtime system detached from the system console.
201           Useful for  running  daemons  and  backgrounds  processes.  Implies
202           -noinput.
203
204         -disable-feature feature:
205           Disables  the  feature  feature  in the runtime system. The special
206           feature all can be used to disable all non permanent features.
207
208         -dist_listen true|false:
209           Specifies whether this node should be listening for  incoming  dis‐
210           tribution connections or not. By default a node will listen for in‐
211           coming connections. Setting this option to false implies -hidden.
212
213         -emu_args:
214           Useful for debugging. Prints the arguments sent to the emulator.
215
216         -emu_flavor emu|jit|smp:
217           Start an emulator of a different flavor. Normally only  one  flavor
218           is  available,  more can be added by building specific flavors. The
219           currently available flavors are: emu and jit. The smp flavor is  an
220           alias  for  the  current  default flavor. You can combine this flag
221           with --emu_type. You can get the current flavor at  run-time  using
222           erlang:system_info(emu_flavor). (The emulator with this flavor must
223           be built. You can build  a  specific  flavor  by  doing  make  FLA‐
224           VOR=$FLAVOR in the Erlang/OTP source repository.)
225
226         -emu_type Type:
227           Start  an  emulator  of a different type. For example, to start the
228           lock-counter emulator, use -emu_type lcnt. You can get the  current
229           type  at run-time using erlang:system_info(build_type). (The emula‐
230           tor of this type must already be built. Use  the  configure  option
231           --enable-lock-counter to build the lock-counter emulator.)
232
233         -enable-feature feature:
234           Enables the feature feature in the runtime system. The special fea‐
235           ture all can be used to enable all features.
236
237         -env Variable Value:
238           Sets the host OS environment variable Variable to the  value  Value
239           for the Erlang runtime system. Example:
240
241         % erl -env DISPLAY gin:0
242
243           In  this example, an Erlang runtime system is started with environ‐
244           ment variable DISPLAY set to gin:0.
245
246         -epmd_module Module (init flag):
247           Configures the module responsible to communicate to epmd.  Defaults
248           to erl_epmd.
249
250         -erl_epmd_port Port (init flag):
251           Configures  the  port used by erl_epmd to listen for connection and
252           connect to other nodes. See erl_epmd for more details. Defaults  to
253           0.
254
255         -eval Expr (init flag):
256           Makes init evaluate the expression Expr; see init(3).
257
258         -extra (init flag):
259           Everything  following  -extra is considered plain arguments and can
260           be retrieved using init:get_plain_arguments/0.
261
262         -heart:
263           Starts heartbeat monitoring  of  the  Erlang  runtime  system;  see
264           heart(3).
265
266         -hidden:
267           Starts  the Erlang runtime system as a hidden node, if it is run as
268           a distributed node. Hidden nodes always  establish  hidden  connec‐
269           tions to all other nodes except for nodes in the same global group.
270           Hidden connections are not published on any of the connected nodes,
271           that  is,  none  of the connected nodes are part of the result from
272           nodes/0  on  the  other  node.  See  also  hidden  global   groups;
273           global_group(3).
274
275         -hosts Hosts:
276           Specifies  the  IP  addresses  for  the  hosts on which Erlang boot
277           servers are running, see erl_boot_server(3). This flag is mandatory
278           if flag -loader inet is present.
279
280           The IP addresses must be specified in the standard form (four deci‐
281           mal numbers separated by  periods,  for  example,  "150.236.20.74".
282           Hosts names are not acceptable, but a broadcast address (preferably
283           limited to the local network) is.
284
285         -id Id:
286           Specifies the identity of the Erlang runtime system. If it  is  run
287           as  a  distributed  node, Id must be identical to the name supplied
288           together with flag -sname or -name.
289
290         -init_debug:
291           Makes init write some debug information while interpreting the boot
292           script.
293
294         -instr (emulator flag):
295           Selects  an instrumented Erlang runtime system (virtual machine) to
296           run, instead of the ordinary one. When running an instrumented run‐
297           time  system, some resource usage data can be obtained and analyzed
298           using the instrument module. Functionally, it behaves exactly  like
299           an ordinary Erlang runtime system.
300
301         -loader Loader:
302           Specifies the method used by erl_prim_loader to load Erlang modules
303           into the system; see erl_prim_loader(3).  Two  Loader  methods  are
304           supported:
305
306           * efile,  which  means  use  the local file system, this is the de‐
307             fault.
308
309           * inet, which means use a boot server on another machine. The flags
310             -id, -hosts and -setcookie must also be specified.
311
312           If  Loader is something else, the user-supplied Loader port program
313           is started.
314
315         -make:
316           Makes the Erlang runtime system invoke make:all()  in  the  current
317           working  directory  and then terminate; see make(3). Implies -noin‐
318           put.
319
320         -man Module:
321           Displays the manual page for the Erlang module  Module.  Only  sup‐
322           ported on Unix.
323
324         -mode interactive | embedded:
325           Modules  are auto loaded when they are first referenced if the run‐
326           time system runs in interactive mode, which is the default. In  em‐
327           bedded  mode modules are not auto loaded. The latter is recommended
328           when the boot script preloads all modules, as  conventionally  hap‐
329           pens in OTP releases. See code(3).
330
331         -name Name:
332           Makes  the Erlang runtime system into a distributed node. This flag
333           invokes all network servers necessary for a node to become distrib‐
334           uted; see net_kernel(3). It also ensures that epmd runs on the cur‐
335           rent host before Erlang is started (see epmd(1) and the -start_epmd
336           option) and that a magic cookie has been set (see -setcookie).
337
338           The  node name will be Name@Host, where Host is the fully qualified
339           host name of the current host. For short names, use flag -sname in‐
340           stead.
341
342           If  Name  is set to undefined the node will be started in a special
343           mode optimized to be the temporary client of another node. The node
344           will  then  request a dynamic node name from the first node it con‐
345           nects to. Read more in  Dynamic Node Name.
346
347     Warning:
348         Starting a  distributed  node  without  also  specifying  -proto_dist
349         inet_tls  will  expose the node to attacks that may give the attacker
350         complete access to the node and in extension the cluster. When  using
351         un-secure distributed nodes, make sure that the network is configured
352         to keep potential attackers out.
353
354
355         -no_epmd:
356           Specifies that the distributed node does not need epmd at all.
357
358           This option ensures that the Erlang runtime system does  not  start
359           epmd  and  does not start the erl_epmd process for distribution ei‐
360           ther.
361
362           This option only works if Erlang is started as a  distributed  node
363           with  the  -proto_dist option using an alternative protocol for Er‐
364           lang distribution which does not rely on epmd for node registration
365           and discovery. For more information, see How to implement an Alter‐
366           native Carrier for the Erlang Distribution.
367
368         -noinput:
369           Ensures that the Erlang runtime system never tries to read any  in‐
370           put. Implies -noshell.
371
372         -noshell:
373           Starts  an  Erlang runtime system with no shell. This flag makes it
374           possible to have the Erlang runtime system as a component in a  se‐
375           ries of Unix pipes.
376
377         -nostick:
378           Disables  the  sticky directory facility of the Erlang code server;
379           see code(3).
380
381         -oldshell:
382           Invokes the old Erlang shell from Erlang/OTP 3.3. The old shell can
383           still be used.
384
385         -pa Dir1 Dir2 ...:
386           Adds  the  specified directories to the beginning of the code path,
387           similar to code:add_pathsa/1. Note that the order of the given  di‐
388           rectories will be reversed in the resulting path.
389
390           As  an  alternative  to  -pa,  if  several  directories  are  to be
391           prepended to the code path and the directories have a common parent
392           directory,  that  parent  directory can be specified in environment
393           variable ERL_LIBS; see code(3).
394
395         -pz Dir1 Dir2 ...:
396           Adds the specified directories to the end of the code path, similar
397           to code:add_pathsz/1; see code(3).
398
399         -path Dir1 Dir2 ...:
400           Replaces the path specified in the boot script; see script(4).
401
402         -proto_dist Proto:
403
404
405           Specifies a protocol for Erlang distribution:
406
407           inet_tcp:
408             TCP over IPv4 (the default)
409
410           inet_tls:
411             Distribution  over TLS/SSL, See the  Using SSL for Erlang Distri‐
412             bution User's Guide for details on how to setup a secure distrib‐
413             uted node.
414
415           inet6_tcp:
416             TCP over IPv6
417
418           For example, to start up IPv6 distributed nodes:
419
420         % erl -name test@ipv6node.example.com -proto_dist inet6_tcp
421
422         -remsh Node:
423           Starts Erlang with a remote shell connected to Node.
424
425           If  no  -name  or  -sname  is  given the node will be started using
426           -sname undefined. If Node does not contain a hostname, one is auto‐
427           matically taken from -name or -sname
428
429     Note:
430         Before  OTP-23  the user needed to supply a valid -sname or -name for
431         -remsh to work. This is still the case if the target node is not run‐
432         ning OTP-23 or later.
433
434
435     Note:
436         The connecting node needs to have a proper shell with terminal emula‐
437         tion. This means that UNIX users must use  an  Erlang  compiled  with
438         terminal capabilities and Windows users must use werl(1).
439
440
441         -rsh Program:
442           Specifies  an alternative to ssh for starting a slave node on a re‐
443           mote host; see slave(3).
444
445         -run Mod [Func [Arg1, Arg2, ...]] (init flag):
446           Makes init call the specified function. Func defaults to start.  If
447           no  arguments  are provided, the function is assumed to be of arity
448           0. Otherwise it is assumed to  be  of  arity  1,  taking  the  list
449           [Arg1,Arg2,...]  as  argument. All arguments are passed as strings.
450           See init(3).
451
452         -s Mod [Func [Arg1, Arg2, ...]] (init flag):
453           Makes init call the specified function. Func defaults to start.  If
454           no  arguments  are provided, the function is assumed to be of arity
455           0. Otherwise it is assumed to  be  of  arity  1,  taking  the  list
456           [Arg1,Arg2,...] as argument. All arguments are passed as atoms. See
457           init(3).
458
459         -setcookie Cookie:
460           Sets  the  magic  cookie  of  the   node   to   Cookie;   see   er‐
461           lang:set_cookie/1. See see section Distributed Erlang in the Erlang
462           Reference Manual for more details.
463
464         -setcookie Node Cookie:
465           Sets the magic cookie for Node to Cookie; see erlang:set_cookie/2.
466
467         -shutdown_time Time:
468           Specifies how long time (in milliseconds) the init process  is  al‐
469           lowed  to spend shutting down the system. If Time milliseconds have
470           elapsed, all processes still existing are killed. Defaults  to  in‐
471           finity.
472
473         -sname Name:
474           Makes the Erlang runtime system into a distributed node, similar to
475           -name, but the host name portion of the node name Name@Host will be
476           the short name, not fully qualified.
477
478           This is sometimes the only way to run distributed Erlang if the Do‐
479           main Name System (DNS) is not running. No communication  can  exist
480           between  nodes running with flag -sname and those running with flag
481           -name, as node names must be unique in distributed Erlang systems.
482
483           If Name is set to undefined the node will be started in  a  special
484           mode optimized to be the temporary client of another node. The node
485           will then request a dynamic node name from the first node  it  con‐
486           nects to. Read more in  Dynamic Node Name.
487
488     Warning:
489         Starting  a  distributed  node  without  also  specifying -proto_dist
490         inet_tls will expose the node to attacks that may give  the  attacker
491         complete  access to the node and in extension the cluster. When using
492         un-secure distributed nodes, make sure that the network is configured
493         to keep potential attackers out.
494
495
496         -start_epmd true | false:
497           Specifies  whether  Erlang should start epmd on startup. By default
498           this is true, but if you prefer to start epmd manually, set this to
499           false.
500
501           This  only applies if Erlang is started as a distributed node, i.e.
502           if -name or -sname is specified. Otherwise,  epmd  is  not  started
503           even if -start_epmd true is given.
504
505           Note that a distributed node will fail to start if epmd is not run‐
506           ning.
507
508         -version (emulator flag):
509           Makes the emulator print its version number. The same as erl +V.
510

EMULATOR FLAGS

512       erl invokes the code for the Erlang emulator (virtual  machine),  which
513       supports the following flags:
514
515         +a size:
516           Suggested stack size, in kilowords, for threads in the async thread
517           pool. Valid range is 16-8192 kilowords. The default suggested stack
518           size is 16 kilowords, that is, 64 kilobyte on 32-bit architectures.
519           This small default size has been chosen because the number of async
520           threads can be large. The default size is enough for drivers deliv‐
521           ered with Erlang/OTP, but might not be large enough for  other  dy‐
522           namically linked-in drivers that use the driver_async() functional‐
523           ity. Notice that the value passed is only a suggestion, and it  can
524           even be ignored on some platforms.
525
526         +A size:
527           Sets  the  number  of  threads in async thread pool. Valid range is
528           1-1024. The async thread pool is used by linked-in drivers to  han‐
529           dle  work  that  may  take a very long time. Since OTP 21 there are
530           very few linked-in drivers in the default  Erlang/OTP  distribution
531           that uses the async thread pool. Most of them have been migrated to
532           dirty IO schedulers. Defaults to 1.
533
534         +B [c | d | i]:
535           Option c makes Ctrl-C interrupt the current shell instead of invok‐
536           ing  the  emulator  break  handler. Option d (same as specifying +B
537           without an extra option) disables the break handler. Option i makes
538           the emulator ignore any break signal.
539
540           If  option c is used with oldshell on Unix, Ctrl-C will restart the
541           shell process rather than interrupt it.
542
543           Notice that on Windows, this flag is only applicable for werl,  not
544           erl  (oldshell).  Notice  also  that  Ctrl-Break is used instead of
545           Ctrl-C on Windows.
546
547         +c true | false:
548           Enables or disables time correction:
549
550           true:
551             Enables time correction. This is the default if  time  correction
552             is supported on the specific platform.
553
554           false:
555             Disables time correction.
556
557           For  backward compatibility, the boolean value can be omitted. This
558           is interpreted as +c false.
559
560         +C no_time_warp | single_time_warp | multi_time_warp:
561           Sets time warp mode:
562
563           no_time_warp:
564              No time warp mode (the default)
565
566           single_time_warp:
567              Single time warp mode
568
569           multi_time_warp:
570              Multi-time warp mode
571
572         +d:
573           If the emulator detects an internal error (or runs out of  memory),
574           it,  by  default,  generates both a crash dump and a core dump. The
575           core dump is, however, not very useful as the  content  of  process
576           heaps is destroyed by the crash dump generation.
577
578           Option +d instructs the emulator to produce only a core dump and no
579           crash dump if an internal error is detected.
580
581           Calling erlang:halt/1 with a string argument still produces a crash
582           dump. On Unix systems, sending an emulator process a SIGUSR1 signal
583           also forces a crash dump.
584
585         +dcg DecentralizedCounterGroupsLimit:
586           Limits the number of decentralized counter groups  used  by  decen‐
587           tralized  counters  optimized  for  update operations in the Erlang
588           runtime system. By default, the limit is 256.
589
590           When the number of schedulers is less than or equal to  the  limit,
591           each  scheduler has its own group. When the number of schedulers is
592           larger than the  groups  limit,  schedulers  share  groups.  Shared
593           groups  degrade  the  performance  for updating counters while many
594           reader groups degrade the performance for reading counters. So, the
595           limit  is  a tradeoff between performance for update operations and
596           performance for read operations. Each group consumes  64  bytes  in
597           each counter.
598
599           Notice  that  a  runtime  system using decentralized counter groups
600           benefits from binding schedulers  to  logical  processors,  as  the
601           groups are distributed better between schedulers with this option.
602
603           This  option only affects decentralized counters used for the coun‐
604           ters that are keeping track of the memory consumption and the  num‐
605           ber  of terms in ETS tables of type ordered_set with the write_con‐
606           currency option activated.
607
608         +e Number:
609           Sets the maximum number of ETS tables. This limit is partially  ob‐
610           solete.
611
612         +ec:
613           Forces  option compressed on all ETS tables. Only intended for test
614           and evaluation.
615
616         +fnl:
617           The virtual machine works with filenames as if they are encoded us‐
618           ing  the  ISO Latin-1 encoding, disallowing Unicode characters with
619           code points > 255.
620
621           For more information about Unicode filenames, see  section  Unicode
622           Filenames  in  the STDLIB User's Guide. Notice that this value also
623           applies to command-line parameters and environment  variables  (see
624           section  Unicode in Environment and Parameters in the STDLIB User's
625           Guide).
626
627         +fnu[{w|i|e}]:
628           The virtual machine works with filenames as if they are encoded us‐
629           ing UTF-8 (or some other system-specific Unicode encoding). This is
630           the default on operating systems  that  enforce  Unicode  encoding,
631           that is, Windows MacOS X and Android.
632
633           The  +fnu  switch  can  be  followed  by  w, i, or e to control how
634           wrongly encoded filenames are to be reported:
635
636           * w means that a warning is sent to  the  error_logger  whenever  a
637             wrongly encoded filename is "skipped" in directory listings. This
638             is the default.
639
640           * i means that those wrongly encoded  filenames  are  silently  ig‐
641             nored.
642
643           * e means that the API function returns an error whenever a wrongly
644             encoded filename (or directory name) is encountered.
645
646           Notice that file:read_link/1 always returns an error  if  the  link
647           points to an invalid filename.
648
649           For  more  information about Unicode filenames, see section Unicode
650           Filenames in the STDLIB User's Guide. Notice that this  value  also
651           applies  to  command-line parameters and environment variables (see
652           section  Unicode in Environment and Parameters in the STDLIB User's
653           Guide).
654
655         +fna[{w|i|e}]:
656           Selection between +fnl and +fnu is done based on the current locale
657           settings in the OS. This means that if you have set  your  terminal
658           for  UTF-8 encoding, the filesystem is expected to use the same en‐
659           coding for filenames. This is the default on all operating systems,
660           except Android, MacOS X and Windows.
661
662           The  +fna  switch can be followed by w, i, or e. This has effect if
663           the locale settings cause the behavior of +fnu to be selected;  see
664           the description of +fnu above. If the locale settings cause the be‐
665           havior of +fnl to be selected, then w, i, or e have no effect.
666
667           For more information about Unicode filenames, see  section  Unicode
668           Filenames  in  the STDLIB User's Guide. Notice that this value also
669           applies to command-line parameters and environment  variables  (see
670           section  Unicode in Environment and Parameters in the STDLIB User's
671           Guide).
672
673         +hms Size:
674           Sets the default heap size of processes to the size Size.
675
676         +hmbs Size:
677           Sets the default binary virtual heap size of processes to the  size
678           Size.
679
680         +hmax Size:
681           Sets  the  default  maximum heap size of processes to the size Size
682           words. Defaults to 0, which means that  no  maximum  heap  size  is
683           used.  For  more  information, see process_flag(max_heap_size, Max‐
684           HeapSize).
685
686         +hmaxel true|false:
687           Sets whether to send an error logger message or not  for  processes
688           reaching the maximum heap size. Defaults to true. For more informa‐
689           tion, see process_flag(max_heap_size, MaxHeapSize).
690
691         +hmaxk true|false:
692           Sets whether to kill processes reaching the maximum  heap  size  or
693           not.    Default    to    true.    For    more    information,   see
694           process_flag(max_heap_size, MaxHeapSize).
695
696         +hpds Size:
697           Sets the initial process dictionary size of processes to  the  size
698           Size.
699
700         +hmqd off_heap|on_heap:
701           Sets  the default value of the message_queue_data process flag. De‐
702           faults to on_heap. If +hmqd is not passed, on_heap will be the  de‐
703           fault.  For  more information, see process_flag(message_queue_data,
704           MQD).
705
706         +IOp PollSets:
707           Sets the number of IO pollsets to use when polling  for  I/O.  This
708           option is only used on platforms that support concurrent updates of
709           a pollset, otherwise the same number of pollsets  are  used  as  IO
710           poll threads. The default is 1.
711
712         +IOt PollThreads:
713           Sets the number of IO poll threads to use when polling for I/O. The
714           maximum number of poll threads allowed is 1024. The default is 1.
715
716           A good way to check if more IO poll threads are needed  is  to  use
717           microstate  accounting  and see what the load of the IO poll thread
718           is. If it is high it could be a good idea to add more threads.
719
720         +IOPp PollSetsPercentage:
721           Similar to +IOp but uses  percentages  to  set  the  number  of  IO
722           pollsets to create, based on the number of poll threads configured.
723           If both +IOPp and +IOp are used, +IOPp is ignored.
724
725         +IOPt PollThreadsPercentage:
726           Similar to +IOt but uses percentages to set the number of  IO  poll
727           threads to create, based on the number of schedulers configured. If
728           both +IOPt and +IOt are used, +IOPt is ignored.
729
730         +IOs true|false:
731           Enable or disable scheduler thread poll  optimization.  Default  is
732           true.
733
734           If  enabled, file descriptors that are frequently read may be moved
735           to a special pollset used by scheduler threads. The objective is to
736           reduce  the number of system calls and thereby CPU load, but it can
737           in some cases increase scheduling latency for individual  file  de‐
738           scriptor input events.
739
740         +JPperf true|false|dump|map|fp|no_fp:
741           Enables or disables support for the perf profiler when running with
742           the JIT on Linux. Defaults to false.
743
744           This option can be combined multiple times to  enable  several  op‐
745           tions:
746
747           dump:
748             Gives  perf  detailed line information, so that the perf annotate
749             feature works.
750
751           map:
752             Gives perf a map over all module code, letting it  translate  ma‐
753             chine  code  addresses to Erlang source code locations. This also
754             enables frame pointers for Erlang code so that perf can walk  the
755             call  stacks  of Erlang processes, which costs one extra word per
756             stack frame.
757
758           fp:
759             Enables frame pointers independently of the map option.
760
761           no_fp:
762             Disables the frame pointers added by the map option.
763
764           true:
765             Enables map and dump.
766
767           false:
768             Disables all other options.
769
770           For more details about how to run perf see the perf support section
771           in the BeamAsm internal documentation.
772
773         +L:
774           Prevents  loading  information about source filenames and line num‐
775           bers. This saves some memory, but exceptions do not contain  infor‐
776           mation about the filenames and line numbers.
777
778         +MFlag Value:
779           Memory allocator-specific flags. For more information, see erts_al‐
780           loc(3).
781
782         +pad true|false:
783           Since: OTP 25.3
784
785           The boolean value used with the +pad parameter determines  the  de‐
786           fault  value  of  the async_dist process flag of newly spawned pro‐
787           cesses. By default, if no +pad command line option is  passed,  the
788           async_dist flag will be set to false.
789
790           The  value  used in runtime can be inspected by calling erlang:sys‐
791           tem_info(async_dist).
792
793         +pc Range:
794           Sets the range of characters that the system considers printable in
795           heuristic  detection  of strings. This typically affects the shell,
796           debugger, and io:format functions (when ~tp is used in  the  format
797           string).
798
799           Two values are supported for Range:
800
801           latin1:
802             The default. Only characters in the ISO Latin-1 range can be con‐
803             sidered printable. This means that a character with a code  point
804             >  255  is  never  considered printable and that lists containing
805             such characters are displayed as lists of  integers  rather  than
806             text strings by tools.
807
808           unicode:
809             All  printable Unicode characters are considered when determining
810             if a list of integers is to be displayed in string  syntax.  This
811             can  give  unexpected results if, for example, your font does not
812             cover all Unicode characters.
813
814           See also io:printable_range/0 in STDLIB.
815
816         +P Number:
817           Sets the maximum number of simultaneously  existing  processes  for
818           this  system if a Number is passed as value. Valid range for Number
819           is [1024-134217727]
820
821           NOTE: The actual maximum chosen may be much larger than the  Number
822           passed. Currently the runtime system often, but not always, chooses
823           a value that is a power of 2. This might, however,  be  changed  in
824           the  future.  The actual value chosen can be checked by calling er‐
825           lang:system_info(process_limit).
826
827           The default value is 262144
828
829         +Q Number:
830           Sets the maximum number of simultaneously existing ports  for  this
831           system  if  a  Number is passed as value. Valid range for Number is
832           [1024-134217727]
833
834           NOTE: The actual maximum chosen may be much larger than the  actual
835           Number  passed. Currently the runtime system often, but not always,
836           chooses a value that is a power  of  2.  This  might,  however,  be
837           changed  in  the  future. The actual value chosen can be checked by
838           calling erlang:system_info(port_limit).
839
840           The default value used is normally 65536. However, if  the  runtime
841           system is able to determine maximum amount of file descriptors that
842           it is allowed to open and this value is larger than 65536, the cho‐
843           sen  value will increased to a value larger or equal to the maximum
844           amount of file descriptors that can be opened.
845
846           On Windows the default value is set to 8196 because the  normal  OS
847           limitations are set higher than most machines can handle.
848
849         +R ReleaseNumber:
850           Sets the compatibility mode.
851
852           The  distribution  mechanism is not backward compatible by default.
853           This flag sets the emulator in compatibility mode with  an  earlier
854           Erlang/OTP release ReleaseNumber. The release number must be in the
855           range <current release>-2..<current release>. This limits the  emu‐
856           lator,  making  it possible for it to communicate with Erlang nodes
857           (as well as C- and Java nodes) running that earlier release.
858
859     Note:
860         Ensure that all nodes (Erlang-, C-, and Java nodes) of a  distributed
861         Erlang  system is of the same Erlang/OTP release, or from two differ‐
862         ent Erlang/OTP releases X and Y, where all Y nodes have compatibility
863         mode X.
864
865
866         +r:
867           Forces ETS memory block to be moved on realloc.
868
869         +rg ReaderGroupsLimit:
870           Limits  the  number of reader groups used by read/write locks opti‐
871           mized for read operations in the Erlang runtime system. By  default
872           the reader groups limit is 64.
873
874           When  the  number of schedulers is less than or equal to the reader
875           groups limit, each scheduler has its own  reader  group.  When  the
876           number of schedulers is larger than the reader groups limit, sched‐
877           ulers share reader groups. Shared reader groups degrade  read  lock
878           and  read unlock performance while many reader groups degrade write
879           lock performance. So, the limit is a tradeoff  between  performance
880           for  read  operations  and  performance  for write operations. Each
881           reader group consumes 64 byte in each read/write lock.
882
883           Notice that a runtime system using shared  reader  groups  benefits
884           from binding schedulers to logical processors, as the reader groups
885           are distributed better between schedulers.
886
887         +S Schedulers:SchedulerOnline:
888           Sets the number  of  scheduler  threads  to  create  and  scheduler
889           threads  to set online. The maximum for both values is 1024. If the
890           Erlang runtime system is able to determine the  number  of  logical
891           processors  configured and logical processors available, Schedulers
892           defaults to logical processors configured, and SchedulersOnline de‐
893           faults  to logical processors available; otherwise the default val‐
894           ues are 1. If the emulator detects that it  is  subject  to  a  CPU
895           quota,  the  default value for SchedulersOnline will be limited ac‐
896           cordingly.
897
898           Schedulers can be omitted  if  :SchedulerOnline  is  not  and  con‐
899           versely.  The number of schedulers online can be changed at runtime
900           through erlang:system_flag(schedulers_online, SchedulersOnline).
901
902           If Schedulers or SchedulersOnline is specified as a  negative  num‐
903           ber,  the  value  is  subtracted from the default number of logical
904           processors configured  or  logical  processors  available,  respec‐
905           tively.
906
907           Specifying  value  0  for Schedulers or SchedulersOnline resets the
908           number of scheduler threads or scheduler  threads  online,  respec‐
909           tively, to its default value.
910
911         +SP SchedulersPercentage:SchedulersOnlinePercentage:
912           Similar  to  +S but uses percentages to set the number of scheduler
913           threads to create, based  on  logical  processors  configured,  and
914           scheduler threads to set online, based on logical processors avail‐
915           able. Specified values must be > 0. For example, +SP 50:25 sets the
916           number  of  scheduler threads to 50% of the logical processors con‐
917           figured, and the number of scheduler threads online to 25%  of  the
918           logical  processors  available. SchedulersPercentage can be omitted
919           if :SchedulersOnlinePercentage is not and conversely. The number of
920           schedulers  online  can  be  changed at runtime through erlang:sys‐
921           tem_flag(schedulers_online, SchedulersOnline).
922
923           This option interacts with +S settings. For example,  on  a  system
924           with  8 logical cores configured and 8 logical cores available, the
925           combination of the options +S 4:4 +SP 50:25 (in either  order)  re‐
926           sults  in 2 scheduler threads (50% of 4) and 1 scheduler thread on‐
927           line (25% of 4).
928
929         +SDcpu DirtyCPUSchedulers:DirtyCPUSchedulersOnline:
930           Sets the number of dirty CPU scheduler threads to create and  dirty
931           CPU scheduler threads to set online. The maximum for both values is
932           1024, and each value is further limited by the settings for  normal
933           schedulers:
934
935           * The  number  of dirty CPU scheduler threads created cannot exceed
936             the number of normal scheduler threads created.
937
938           * The number of dirty CPU scheduler threads  online  cannot  exceed
939             the number of normal scheduler threads online.
940
941           For  details,  see  the +S and +SP. By default, the number of dirty
942           CPU scheduler threads created equals the number of normal scheduler
943           threads  created, and the number of dirty CPU scheduler threads on‐
944           line equals the number of normal scheduler threads online.  DirtyC‐
945           PUSchedulers can be omitted if :DirtyCPUSchedulersOnline is not and
946           conversely. The number  of  dirty  CPU  schedulers  online  can  be
947           changed   at  runtime  through  erlang:system_flag(dirty_cpu_sched‐
948           ulers_online, DirtyCPUSchedulersOnline).
949
950           The amount of dirty CPU schedulers is limited by the amount of nor‐
951           mal  schedulers in order to limit the effect on processes executing
952           on ordinary schedulers. If the amount of dirty CPU  schedulers  was
953           allowed  to  be  unlimited,  dirty CPU bound jobs would potentially
954           starve normal jobs.
955
956           Typical users of the dirty CPU schedulers are large garbage collec‐
957           tions, json protocol encode/decoders written as nifs and matrix ma‐
958           nipulation libraries.
959
960           You can use msacc(3) in order to see the current load of the  dirty
961           CPU schedulers threads and adjust the number used accordingly.
962
963         +SDPcpu DirtyCPUSchedulersPercentage:DirtyCPUSchedulersOnlinePercent‐
964         age:
965           Similar to +SDcpu but uses percentages to set the number  of  dirty
966           CPU  scheduler threads to create and the number of dirty CPU sched‐
967           uler threads to set online. Specified values must be > 0. For exam‐
968           ple,  +SDPcpu  50:25 sets the number of dirty CPU scheduler threads
969           to 50% of the logical processors configured and the number of dirty
970           CPU  scheduler  threads  online  to  25%  of the logical processors
971           available. DirtyCPUSchedulersPercentage can be omitted if  :DirtyC‐
972           PUSchedulersOnlinePercentage  is  not and conversely. The number of
973           dirty CPU schedulers online can be changed at runtime  through  er‐
974           lang:system_flag(dirty_cpu_schedulers_online, DirtyCPUSchedulersOn‐
975           line).
976
977           This option interacts with +SDcpu settings. For example, on a  sys‐
978           tem  with 8 logical cores configured and 8 logical cores available,
979           the combination of the options +SDcpu 4:4 +SDPcpu 50:25 (in  either
980           order)  results  in  2 dirty CPU scheduler threads (50% of 4) and 1
981           dirty CPU scheduler thread online (25% of 4).
982
983         +SDio DirtyIOSchedulers:
984           Sets the number of dirty I/O scheduler  threads  to  create.  Valid
985           range  is  1-1024.  By  default,  the number of dirty I/O scheduler
986           threads created is 10.
987
988           The amount of dirty IO schedulers is not limited by the  amount  of
989           normal  schedulers  like  the  amount of dirty CPU schedulers. This
990           since only I/O bound work is  expected  to  execute  on  dirty  I/O
991           schedulers. If the user should schedule CPU bound jobs on dirty I/O
992           schedulers, these jobs might starve ordinary jobs executing on  or‐
993           dinary schedulers.
994
995           Typical users of the dirty IO schedulers are reading and writing to
996           files.
997
998           You can use msacc(3) in order to see the current load of the  dirty
999           IO schedulers threads and adjust the number used accordingly.
1000
1001         +sFlag Value:
1002           Scheduling specific flags.
1003
1004           +sbt BindType:
1005             Sets scheduler bind type.
1006
1007             Schedulers  can  also be bound using flag +stbt. The only differ‐
1008             ence between these two flags is how the following errors are han‐
1009             dled:
1010
1011             * Binding  of  schedulers  is not supported on the specific plat‐
1012               form.
1013
1014             * No available CPU topology. That is, the runtime system was  not
1015               able  to detect the CPU topology automatically, and no user-de‐
1016               fined CPU topology was set.
1017
1018             If any of these errors occur when +sbt has been passed, the  run‐
1019             time system prints an error message, and refuses to start. If any
1020             of these errors occur when +stbt has  been  passed,  the  runtime
1021             system  silently  ignores  the  error, and start up using unbound
1022             schedulers.
1023
1024             Valid BindTypes:
1025
1026             u:
1027               unbound - Schedulers are not bound to logical processors,  that
1028               is,  the  operating  system decides where the scheduler threads
1029               execute, and when to migrate them. This is the default.
1030
1031             ns:
1032               no_spread - Schedulers with  close  scheduler  identifiers  are
1033               bound as close as possible in hardware.
1034
1035             ts:
1036               thread_spread  - Thread refers to hardware threads (such as In‐
1037               tel's hyper-threads). Schedulers  with  low  scheduler  identi‐
1038               fiers,  are  bound  to  the first hardware thread of each core,
1039               then schedulers with higher scheduler identifiers are bound  to
1040               the second hardware thread of each core,and so on.
1041
1042             ps:
1043               processor_spread  -  Schedulers  are spread like thread_spread,
1044               but also over physical processor chips.
1045
1046             s:
1047               spread - Schedulers are spread as much as possible.
1048
1049             nnts:
1050               no_node_thread_spread - Like  thread_spread,  but  if  multiple
1051               Non-Uniform  Memory  Access  (NUMA) nodes exist, schedulers are
1052               spread over one NUMA node at a time, that is, all logical  pro‐
1053               cessors of one NUMA node are bound to schedulers in sequence.
1054
1055             nnps:
1056               no_node_processor_spread - Like processor_spread, but if multi‐
1057               ple NUMA nodes exist, schedulers are spread over one NUMA  node
1058               at a time, that is, all logical processors of one NUMA node are
1059               bound to schedulers in sequence.
1060
1061             tnnps:
1062               thread_no_node_processor_spread    -    A    combination     of
1063               thread_spread,  and  no_node_processor_spread.  Schedulers  are
1064               spread over hardware threads across NUMA nodes, but  schedulers
1065               are  only spread over processors internally in one NUMA node at
1066               a time.
1067
1068             db:
1069               default_bind - Binds schedulers the default  way.  Defaults  to
1070               thread_no_node_processor_spread  (which  can  change in the fu‐
1071               ture).
1072
1073             Binding of schedulers is only supported on newer Linux,  Solaris,
1074             FreeBSD, and Windows systems.
1075
1076             If  no  CPU topology is available when flag +sbt is processed and
1077             BindType is any other type than u, the runtime  system  fails  to
1078             start.  CPU  topology can be defined using flag +sct. Notice that
1079             flag +sct can have to be passed before flag +sbt on  the  command
1080             line (if no CPU topology has been automatically detected).
1081
1082             The runtime system does by default not bind schedulers to logical
1083             processors.
1084
1085       Note:
1086           If the Erlang runtime system is the only operating  system  process
1087           that binds threads to logical processors, this improves the perfor‐
1088           mance of the runtime system. However,  if  other  operating  system
1089           processes  (for  example  another  Erlang runtime system) also bind
1090           threads to logical processors, there can be a  performance  penalty
1091           instead.  This  performance penalty can sometimes be severe. If so,
1092           you are advised not to bind the schedulers.
1093
1094
1095             How schedulers are bound matters. For example, in situations when
1096             there  are  fewer  running  processes than schedulers online, the
1097             runtime system tries to migrate processes to schedulers with  low
1098             scheduler  identifiers.  The  more the schedulers are spread over
1099             the hardware, the more resources are  available  to  the  runtime
1100             system in such situations.
1101
1102       Note:
1103           If a scheduler fails to bind, this is often silently ignored, as it
1104           is not always possible to verify valid  logical  processor  identi‐
1105           fiers. If an error is reported, it is reported to the error_logger.
1106           If you want to verify that the schedulers have bound as  requested,
1107           call erlang:system_info(scheduler_bindings).
1108
1109
1110           +sbwt none|very_short|short|medium|long|very_long:
1111             Sets  scheduler  busy  wait  threshold.  Defaults  to medium. The
1112             threshold determines how long schedulers are to  busy  wait  when
1113             running out of work before going to sleep.
1114
1115       Note:
1116           This  flag  can be removed or changed at any time without prior no‐
1117           tice.
1118
1119
1120           +sbwtdcpu none|very_short|short|medium|long|very_long:
1121             As +sbwt but affects dirty CPU schedulers. Defaults to short.
1122
1123       Note:
1124           This flag can be removed or changed at any time without  prior  no‐
1125           tice.
1126
1127
1128           +sbwtdio none|very_short|short|medium|long|very_long:
1129             As +sbwt but affects dirty IO schedulers. Defaults to short.
1130
1131       Note:
1132           This  flag  can be removed or changed at any time without prior no‐
1133           tice.
1134
1135
1136           +scl true|false:
1137             Enables or disables scheduler  compaction  of  load.  By  default
1138             scheduler  compaction of load is enabled. When enabled, load bal‐
1139             ancing strives for a load  distribution,  which  causes  as  many
1140             scheduler  threads  as  possible to be fully loaded (that is, not
1141             run out of work). This is accomplished by migrating load (for ex‐
1142             ample,  runnable processes) into a smaller set of schedulers when
1143             schedulers frequently run out of work. When  disabled,  the  fre‐
1144             quency  with  which  schedulers run out of work is not taken into
1145             account by the load balancing logic.
1146
1147             +scl false is similar to +sub true, but +sub true  also  balances
1148             scheduler utilization between schedulers.
1149
1150           +sct CpuTopology:
1151
1152
1153             * <Id> = integer(); when 0 =< <Id> =< 65535
1154
1155             * <IdRange> = <Id>-<Id>
1156
1157             * <IdOrIdRange> = <Id> | <IdRange>
1158
1159             * <IdList> = <IdOrIdRange>,<IdOrIdRange> | <IdOrIdRange>
1160
1161             * <LogicalIds> = L<IdList>
1162
1163             * <ThreadIds> = T<IdList> | t<IdList>
1164
1165             * <CoreIds> = C<IdList> | c<IdList>
1166
1167             * <ProcessorIds> = P<IdList> | p<IdList>
1168
1169             * <NodeIds> = N<IdList> | n<IdList>
1170
1171             * <IdDefs>       =       <LogicalIds><ThreadIds><CoreIds><Proces‐
1172               sorIds><NodeIds>         |         <LogicalIds><ThreadIds><Cor‐
1173               eIds><NodeIds><ProcessorIds>
1174
1175             * CpuTopology = <IdDefs>:<IdDefs> | <IdDefs>
1176
1177             Sets  a  user-defined CPU topology. The user-defined CPU topology
1178             overrides any automatically detected CPU topology. The CPU topol‐
1179             ogy is used when binding schedulers to logical processors.
1180
1181             Uppercase  letters signify real identifiers and lowercase letters
1182             signify fake identifiers only used for description of the  topol‐
1183             ogy.  Identifiers  passed  as real identifiers can be used by the
1184             runtime system when trying to access specific hardware;  if  they
1185             are  incorrect the behavior is undefined. Faked logical CPU iden‐
1186             tifiers are not accepted, as there is no point  in  defining  the
1187             CPU  topology without real logical CPU identifiers. Thread, core,
1188             processor, and node identifiers can be omitted. If  omitted,  the
1189             thread ID defaults to t0, the core ID defaults to c0, the proces‐
1190             sor ID defaults to p0, and the node ID is left undefined.  Either
1191             each  logical  processor must belong to only one NUMA node, or no
1192             logical processors must belong to any NUMA nodes.
1193
1194             Both increasing and decreasing <IdRange>s are allowed.
1195
1196             NUMA node identifiers are system wide. That is, each NUMA node on
1197             the  system  must have a unique identifier. Processor identifiers
1198             are also system wide. Core identifiers are processor wide. Thread
1199             identifiers are core wide.
1200
1201             The  order  of  the identifier types implies the hierarchy of the
1202             CPU topology. The valid orders are as follows:
1203
1204             * <LogicalIds><ThreadIds><CoreIds><ProcessorIds><NodeIds>,   that
1205               is, thread is part of a core that is part of a processor, which
1206               is part of a NUMA node.
1207
1208             * <LogicalIds><ThreadIds><CoreIds><NodeIds><ProcessorIds>,   that
1209               is, thread is part of a core that is part of a NUMA node, which
1210               is part of a processor.
1211
1212             A CPU topology can consist of both processor external,  and  pro‐
1213             cessor  internal NUMA nodes as long as each logical processor be‐
1214             longs to only one NUMA node. If <ProcessorIds>  is  omitted,  its
1215             default  position  is  before  <NodeIds>. That is, the default is
1216             processor external NUMA nodes.
1217
1218             If a list of identifiers is used in an <IdDefs>:
1219
1220             * <LogicalIds> must be a list of identifiers.
1221
1222             * At least one other identifier type  besides  <LogicalIds>  must
1223               also have a list of identifiers.
1224
1225             * All  lists of identifiers must produce the same number of iden‐
1226               tifiers.
1227
1228             A simple example. A single quad core processor can  be  described
1229             as follows:
1230
1231           % erl +sct L0-3c0-3
1232           1> erlang:system_info(cpu_topology).
1233           [{processor,[{core,{logical,0}},
1234                        {core,{logical,1}},
1235                        {core,{logical,2}},
1236                        {core,{logical,3}}]}]
1237
1238             A  more  complicated  example with two quad core processors, each
1239             processor in its own NUMA node. The ordering of  logical  proces‐
1240             sors  is a bit weird. This to give a better example of identifier
1241             lists:
1242
1243           % erl +sct L0-1,3-2c0-3p0N0:L7,4,6-5c0-3p1N1
1244           1> erlang:system_info(cpu_topology).
1245           [{node,[{processor,[{core,{logical,0}},
1246                               {core,{logical,1}},
1247                               {core,{logical,3}},
1248                               {core,{logical,2}}]}]},
1249            {node,[{processor,[{core,{logical,7}},
1250                               {core,{logical,4}},
1251                               {core,{logical,6}},
1252                               {core,{logical,5}}]}]}]
1253
1254             As long as real identifiers are correct, it is OK to pass  a  CPU
1255             topology  that  is not a correct description of the CPU topology.
1256             When used with care this can be very useful. This  to  trick  the
1257             emulator  to bind its schedulers as you want. For example, if you
1258             want to run multiple Erlang runtime systems on the same  machine,
1259             you  want  to reduce the number of schedulers used and manipulate
1260             the CPU topology so that they bind to different logical CPUs.  An
1261             example, with two Erlang runtime systems on a quad core machine:
1262
1263           % erl +sct L0-3c0-3 +sbt db +S3:2 -detached -noinput -noshell -sname one
1264           % erl +sct L3-0c0-3 +sbt db +S3:2 -detached -noinput -noshell -sname two
1265
1266             In this example, each runtime system have two schedulers each on‐
1267             line, and all schedulers online will run on different  cores.  If
1268             we  change  to  one  scheduler  online on one runtime system, and
1269             three schedulers online on the other, all schedulers online  will
1270             still run on different cores.
1271
1272             Notice  that  a  faked CPU topology that does not reflect how the
1273             real CPU topology looks like is likely to  decrease  the  perfor‐
1274             mance of the runtime system.
1275
1276             For more information, see erlang:system_info(cpu_topology).
1277
1278           +ssrct:
1279             Skips reading CPU topology.
1280
1281       Note:
1282           Reading CPU topology slows down startup when starting many parallel
1283           instances of ERTS on systems with large amount of cores, using this
1284           flag might speed up execution in such scenarios.
1285
1286
1287           +sfwi Interval:
1288             Sets scheduler-forced wakeup interval. All run queues are scanned
1289             each Interval milliseconds. While there are  sleeping  schedulers
1290             in  the  system,  one  scheduler  is woken for each non-empty run
1291             queue found. Interval default to 0, meaning this feature is  dis‐
1292             abled.
1293
1294       Note:
1295           This  feature  has  been  introduced  as a temporary workaround for
1296           long-executing native code, and native code that does not bump  re‐
1297           ductions  properly  in  OTP.  When these bugs have been fixed, this
1298           flag will be removed.
1299
1300
1301           +spp Bool:
1302             Sets default scheduler hint for port parallelism. If set to true,
1303             the  virtual machine schedules port tasks when it improves paral‐
1304             lelism in the system. If set to false, the virtual machine  tries
1305             to  perform  port tasks immediately, improving latency at the ex‐
1306             pense of parallelism. Default to false. The default used  can  be
1307             inspected in runtime by calling erlang:system_info(port_parallel‐
1308             ism). The default can be overridden on port creation  by  passing
1309             option parallelism to erlang:open_port/2.
1310
1311           +sss size:
1312             Suggested  stack size, in kilowords, for scheduler threads. Valid
1313             range is 20-8192 kilowords. The default suggested stack  size  is
1314             128 kilowords.
1315
1316           +sssdcpu size:
1317             Suggested  stack  size,  in  kilowords,  for  dirty CPU scheduler
1318             threads. Valid range is 20-8192 kilowords. The default  suggested
1319             stack size is 40 kilowords.
1320
1321           +sssdio size:
1322             Suggested  stack  size,  in  kilowords,  for  dirty  IO scheduler
1323             threads. Valid range is 20-8192 kilowords. The default  suggested
1324             stack size is 40 kilowords.
1325
1326           +stbt BindType:
1327             Tries  to  set the scheduler bind type. The same as flag +sbt ex‐
1328             cept how some errors are handled. For more information, see +sbt.
1329
1330           +sub true|false:
1331             Enables or disables  scheduler utilization balancing of load.  By
1332             default  scheduler  utilization balancing is disabled and instead
1333             scheduler compaction of load is enabled, which strives for a load
1334             distribution that causes as many scheduler threads as possible to
1335             be fully loaded (that is, not run out of  work).  When  scheduler
1336             utilization  balancing  is  enabled,  the system instead tries to
1337             balance scheduler utilization between schedulers. That is, strive
1338             for equal scheduler utilization on all schedulers.
1339
1340             +sub  true  is only supported on systems where the runtime system
1341             detects  and  uses  a  monotonically  increasing  high-resolution
1342             clock. On other systems, the runtime system fails to start.
1343
1344             +sub  true  implies  +scl false. The difference between +sub true
1345             and +scl false is that +scl false does not  try  to  balance  the
1346             scheduler utilization.
1347
1348           +swct very_eager|eager|medium|lazy|very_lazy:
1349             Sets  scheduler  wake cleanup threshold. Defaults to medium. Con‐
1350             trols how eager schedulers are to be requesting wakeup because of
1351             certain  cleanup  operations.  When  a lazy setting is used, more
1352             outstanding cleanup operations can be left undone while a  sched‐
1353             uler  is  idling.  When  an eager setting is used, schedulers are
1354             more frequently woken, potentially increasing CPU-utilization.
1355
1356       Note:
1357           This flag can be removed or changed at any time without  prior  no‐
1358           tice.
1359
1360
1361           +sws default|legacy:
1362             Sets  scheduler wakeup strategy. Default strategy changed in ERTS
1363             5.10 (Erlang/OTP R16A). This strategy was known  as  proposal  in
1364             Erlang/OTP  R15. The legacy strategy was used as default from R13
1365             up to and including R15.
1366
1367       Note:
1368           This flag can be removed or changed at any time without  prior  no‐
1369           tice.
1370
1371
1372           +swt very_low|low|medium|high|very_high:
1373             Sets  scheduler wakeup threshold. Defaults to medium. The thresh‐
1374             old determines when to wake up sleeping schedulers when more work
1375             than  can  be handled by currently awake schedulers exists. A low
1376             threshold causes earlier wakeups, and  a  high  threshold  causes
1377             later wakeups. Early wakeups distribute work over multiple sched‐
1378             ulers faster, but work does more  easily  bounce  between  sched‐
1379             ulers.
1380
1381       Note:
1382           This  flag  can be removed or changed at any time without prior no‐
1383           tice.
1384
1385
1386           +swtdcpu very_low|low|medium|high|very_high:
1387             As +swt but affects dirty CPU schedulers. Defaults to medium.
1388
1389       Note:
1390           This flag can be removed or changed at any time without  prior  no‐
1391           tice.
1392
1393
1394           +swtdio very_low|low|medium|high|very_high:
1395             As +swt but affects dirty IO schedulers. Defaults to medium.
1396
1397       Note:
1398           This  flag  can be removed or changed at any time without prior no‐
1399           tice.
1400
1401
1402         +t size:
1403           Sets the maximum number of atoms the virtual  machine  can  handle.
1404           Defaults to 1,048,576.
1405
1406         +T Level:
1407           Enables  modified  timing and sets the modified timing level. Valid
1408           range is 0-9. The timing of the runtime system is changed.  A  high
1409           level usually means a greater change than a low level. Changing the
1410           timing can be very useful for finding timing-related bugs.
1411
1412           Modified timing affects the following:
1413
1414           Process spawning:
1415             A process calling spawn, spawn_link, spawn_monitor, or  spawn_opt
1416             is  scheduled  out  immediately  after  completing the call. When
1417             higher modified timing levels are used, the  caller  also  sleeps
1418             for a while after it is scheduled out.
1419
1420           Context reductions:
1421             The number of reductions a process is allowed to use before it is
1422             scheduled out is increased or reduced.
1423
1424           Input reductions:
1425             The number of reductions performed before  checking  I/O  is  in‐
1426             creased or reduced.
1427
1428     Note:
1429         Performance  suffers  when  modified  timing is enabled. This flag is
1430         only intended for testing and debugging.
1431
1432         return_to and return_from trace messages are lost when tracing on the
1433         spawn BIFs.
1434
1435         This flag can be removed or changed at any time without prior notice.
1436
1437
1438         +v:
1439           Verbose.
1440
1441         +V:
1442           Makes the emulator print its version number.
1443
1444         +W w | i | e:
1445           Sets  the  mapping  of  warning messages for error_logger. Messages
1446           sent to the error logger using one of the warning routines  can  be
1447           mapped  to  errors  (+W e), warnings (+W w), or information reports
1448           (+W i). Defaults to warnings. The current mapping can be  retrieved
1449           using  error_logger:warning_map/0.  For  more  information, see er‐
1450           ror_logger:warning_map/0 in Kernel.
1451
1452         +zFlag Value:
1453           Miscellaneous flags:
1454
1455           +zdbbl size:
1456             Sets the distribution buffer busy limit (dist_buf_busy_limit)  in
1457             kilobytes. Valid range is 1-2097151. Defaults to 1024.
1458
1459             A  larger  buffer  limit allows processes to buffer more outgoing
1460             messages over the distribution. When the buffer  limit  has  been
1461             reached,  sending  processes  will  be suspended until the buffer
1462             size has shrunk. The buffer limit is per distribution channel.  A
1463             higher limit gives lower latency and higher throughput at the ex‐
1464             pense of higher memory use.
1465
1466             This limit only affects processes that have disabled fully  asyn‐
1467             chronous distributed signaling .
1468
1469           +zdntgc time:
1470             Sets   the  delayed  node  table  garbage  collection  time  (de‐
1471             layed_node_table_gc) in seconds. Valid values are either infinity
1472             or an integer in the range 0-100000000. Defaults to 60.
1473
1474             Node  table entries that are not referred linger in the table for
1475             at least the amount of time that this parameter  determines.  The
1476             lingering  prevents  repeated deletions and insertions in the ta‐
1477             bles from occurring.
1478
1479           +zosrl limit:
1480             Sets a limit on the amount of outstanding requests made by a sys‐
1481             tem  process  orchestrating  system  wide changes. Valid range of
1482             this limit is [1,  134217727].  See  erlang:system_flag(outstand‐
1483             ing_system_requests_limit, Limit) for more information.
1484

ENVIRONMENT VARIABLES

1486         ERL_CRASH_DUMP:
1487           If  the  emulator  needs  to  write a crash dump, the value of this
1488           variable is the filename of the crash dump file. If the variable is
1489           not  set,  the name of the crash dump file is erl_crash.dump in the
1490           current directory.
1491
1492         ERL_CRASH_DUMP_NICE:
1493           Unix systems: If the emulator needs to write a crash dump, it  uses
1494           the  value  of this variable to set the nice value for the process,
1495           thus lowering its priority. Valid range is 1-39 (higher values  are
1496           replaced  with  39).  The  highest value, 39, gives the process the
1497           lowest priority.
1498
1499         ERL_CRASH_DUMP_SECONDS:
1500           Unix systems: This variable gives the number of  seconds  that  the
1501           emulator  is  allowed to spend writing a crash dump. When the given
1502           number of seconds have elapsed, the emulator is terminated.
1503
1504           ERL_CRASH_DUMP_SECONDS=0:
1505             If the variable is set to 0 seconds, the runtime system does  not
1506             even  attempt  to  write the crash dump file. It only terminates.
1507             This is the default  if  option  -heart  is  passed  to  erl  and
1508             ERL_CRASH_DUMP_SECONDS is not set.
1509
1510           ERL_CRASH_DUMP_SECONDS=S:
1511             If  the variable is set to a positive value S, wait for S seconds
1512             to complete the crash dump file and then terminates  the  runtime
1513             system with a SIGALRM signal.
1514
1515           ERL_CRASH_DUMP_SECONDS=-1:
1516             A  negative value causes the termination of the runtime system to
1517             wait indefinitely until the crash dump file has  been  completely
1518             written.  This  is  the default if option -heart is not passed to
1519             erl and ERL_CRASH_DUMP_SECONDS is not set.
1520
1521           See also heart(3).
1522
1523         ERL_CRASH_DUMP_BYTES:
1524           This variable sets the maximum size of a crash dump file in  bytes.
1525           The  crash dump will be truncated if this limit is exceeded. If the
1526           variable is not set, no size limit is enforced by default.  If  the
1527           variable  is  set to 0, the runtime system does not even attempt to
1528           write a crash dump file.
1529
1530           Introduced in ERTS 8.1.2 (Erlang/OTP 19.2).
1531
1532         ERL_AFLAGS:
1533           The content of this variable is added to the beginning of the  com‐
1534           mand line for erl.
1535
1536           Flag  -extra is treated in a special way. Its scope ends at the end
1537           of the environment variable content. Arguments following an  -extra
1538           flag  are  moved  on the command line into section -extra, that is,
1539           the end of the command line following an -extra flag.
1540
1541         ERL_ZFLAGS and ERL_FLAGS:
1542           The content of these variables are added to the end of the  command
1543           line for erl.
1544
1545           Flag  -extra is treated in a special way. Its scope ends at the end
1546           of the environment variable content. Arguments following an  -extra
1547           flag  are  moved  on the command line into section -extra, that is,
1548           the end of the command line following an -extra flag.
1549
1550         ERL_LIBS:
1551           Contains a list of additional library  directories  that  the  code
1552           server  searches  for  applications  and adds to the code path; see
1553           code(3).
1554
1555         ERL_EPMD_ADDRESS:
1556           Can be set to a comma-separated list of IP addresses, in which case
1557           the  epmd  daemon  listens only on the specified address(es) and on
1558           the loopback address (which is implicitly added to the list  if  it
1559           has not been specified).
1560
1561         ERL_EPMD_PORT:
1562           Can  contain  the  port number to use when communicating with epmd.
1563           The default port works fine in most cases. A different port can  be
1564           specified to allow nodes of independent clusters to co-exist on the
1565           same host. All nodes in a cluster must use the same epmd port  num‐
1566           ber.
1567

SIGNALS

1569       On  Unix  systems,  the Erlang runtime will interpret two types of sig‐
1570       nals.
1571
1572         SIGUSR1:
1573           A SIGUSR1 signal forces a crash dump.
1574
1575         SIGTERM:
1576           A SIGTERM will produce a stop message to the init process. This  is
1577           equivalent to a init:stop/0 call.
1578
1579           Introduced in ERTS 8.3 (Erlang/OTP 19.3)
1580
1581       The signal SIGUSR2 is reserved for internal usage. No other signals are
1582       handled.
1583

CONFIGURATION

1585       The standard Erlang/OTP system can be reconfigured to  change  the  de‐
1586       fault behavior on startup.
1587
1588         The .erlang startup file:
1589           When  Erlang/OTP  is  started, the system searches for a file named
1590           .erlang  in   the    user's   home   directory   and   then   file‐
1591           name:basedir(user_config, "erlang").
1592
1593           If  an .erlang file is found, it is assumed to contain valid Erlang
1594           expressions. These expressions are evaluated as if they were  input
1595           to the shell.
1596
1597           A typical .erlang file contains a set of search paths, for example:
1598
1599         io:format("executing user profile in $HOME/.erlang\n",[]).
1600         code:add_path("/home/calvin/test/ebin").
1601         code:add_path("/home/hobbes/bigappl-1.2/ebin").
1602         io:format(".erlang rc finished\n",[]).
1603
1604         user_default and shell_default:
1605           Functions  in  the shell that are not prefixed by a module name are
1606           assumed to be functional objects (funs), built-in functions (BIFs),
1607           or belong to the module user_default or shell_default.
1608
1609           To include private shell commands, define them in a module user_de‐
1610           fault and add the following argument as the first line in the  .er‐
1611           lang file:
1612
1613         code:load_abs("..../user_default").
1614
1615         erl:
1616           If  the  contents  of  .erlang are changed and a private version of
1617           user_default is defined, the Erlang/OTP environment can be  custom‐
1618           ized.  More  powerful changes can be made by supplying command-line
1619           arguments in the startup script  erl.  For  more  information,  see
1620           init(3).
1621

SEE ALSO

1623       epmd(1),  erl_prim_loader(3),  erts_alloc(3),  init(3), application(3),
1624       auth(3), code(3), erl_boot_server(3), heart(3), net_kernel(3), make(3)
1625
1626
1627
1628Ericsson AB                      erts 13.2.2.4                          erl(1)
Impressum