Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/elixir/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Erlang Ejabberd iex实况转播';“坏的”;K";值:\';错误_Erlang_Elixir_Ejabberd - Fatal编程技术网

Erlang Ejabberd iex实况转播';“坏的”;K";值:\';错误

Erlang Ejabberd iex实况转播';“坏的”;K";值:\';错误,erlang,elixir,ejabberd,Erlang,Elixir,Ejabberd,我正确安装了ejabberd(我将其配置为--enabled all),没有任何错误。但当我想在elixir模式下运行它时,我会遇到以下错误: # ejabberdctl iexlive bad "K" value: \ Usage: beam.smp [flags] [ -- [init_args] ] The flags are: -a size suggested stack size in kilo words for threads in

我正确安装了
ejabberd
(我将其配置为
--enabled all
),没有任何错误。但当我想在elixir模式下运行它时,我会遇到以下错误:

# ejabberdctl iexlive
bad "K" value: \
Usage: beam.smp [flags] [ -- [init_args] ]
The flags are:

-a size        suggested stack size in kilo words for threads
               in the async-thread pool, valid range is [16-8192]
-A number      set number of threads in async thread pool,
               valid range is [0-1024]
-B[c|d|i]      c to have Ctrl-c interrupt the Erlang shell,
               d (or no extra option) to disable the break
               handler, i to ignore break signals
-c bool        enable or disable time correction
-C mode        set time warp mode; valid modes are:
               no_time_warp|single_time_warp|multi_time_warp
-d             don't write a crash dump for internally detected errors
               (halt(String) will still produce a crash dump)
-fn[u|a|l]     Control how filenames are interpreted
-hms size      set minimum heap size in words (default 233)
-hmbs size     set minimum binary virtual heap size in words (default 32768)
-hpds size     initial process dictionary size (default 10)
-K boolean     enable or disable kernel poll
-n[s|a|d]      Control behavior of signals to ports
               Note that this flag is deprecated!
-M<X> <Y>      memory allocator switches,
               see the erts_alloc(3) documentation for more info.
-pc <set>      Control what characters are considered printable (default latin1)
-P number      set maximum number of processes on this node,
               valid range is [1024-134217727]
-Q number      set maximum number of ports on this node,
               valid range is [1024-134217727]
-R number      set compatibility release number,
               valid range [16-18]
-r             force ets memory block to be moved on realloc
-rg amount     set reader groups limit
-sbt type      set scheduler bind type, valid types are:
-stbt type     u|ns|ts|ps|s|nnts|nnps|tnnps|db
-sbwt val      set scheduler busy wait threshold, valid values are:
               none|very_short|short|medium|long|very_long.
-scl bool      enable/disable compaction of scheduler load,
               see the erl(1) documentation for more info.
-sct cput      set cpu topology,
               see the erl(1) documentation for more info.
-secio bool    enable/disable eager check I/O scheduling,
               see the erl(1) documentation for more info.
-sub bool      enable/disable scheduler utilization balancing,
               see the erl(1) documentation for more info.
-sws val       set scheduler wakeup strategy, valid values are:
               default|legacy.
-swct val      set scheduler wake cleanup threshold, valid values are:
               very_lazy|lazy|medium|eager|very_eager.
-swt val       set scheduler wakeup threshold, valid values are:
               very_low|low|medium|high|very_high.
-sss size      suggested stack size in kilo words for scheduler threads,
               valid range is [4-8192]
-spp Bool      set port parallelism scheduling hint
-S n1:n2       set number of schedulers (n1), and number of
               schedulers online (n2), maximum for both
               numbers is 1024
-SP p1:p2      specify schedulers (p1) and schedulers online (p2)
               as percentages of logical processors configured and logical
               processors available, respectively
-t size        set the maximum number of atoms the emulator can handle
               valid range is [8192-0]
-T number      set modified timing level, valid range is [0-9]
-V             print Erlang version
-v             turn on chatty mode (GCs will be reported etc)
-W<i|w|e>      set error logger warnings mapping,
               see error_logger documentation for details
-zdbbl size    set the distribution buffer busy limit in kilobytes
               valid range is [1-2097151]
-zdntgc time   set delayed node table gc in seconds
               valid values are infinity or intergers in the range [0-100000000]

Note that if the emulator is started with erlexec (typically
from the erl script), these flags should be specified with +.
我把它改成

ERLANG_OPTS=""

它成功了。但我不知道这是否会造成进一步的问题。我将在他们的存储库中打开一个问题。

这是因为
+K$POLL
中的
$POLL
变量未正确初始化。
+K
标志启用或禁用Erlang VM的内核轮询功能,其可接受值为
true
false

ejabberdctl
shell脚本为
$POLL
和其他Erlang VM选项提供了一些默认值。它还使用
ejabberdctl.cfg
config文件,并使用此配置文件中包含的值覆盖默认值

您应该使用
ejabberdctl.cfg
设置所需选项,并按如下方式取消注释:

#' POLL: Kernel polling ([true|false])
#
# The kernel polling option requires support in the kernel.
# Additionally, you need to enable this feature while compiling Erlang.
#
# Default: true
#
POLL=true

#.
#' SMP: SMP support ([enable|auto|disable])
#
# Explanation in Erlang/OTP documentation:
# enable: starts the Erlang runtime system with SMP support enabled.
#   This may fail if no runtime system with SMP support is available.
# auto: starts the Erlang runtime system with SMP support enabled if it
#   is available and more than one logical processor are detected.
# disable: starts a runtime system without SMP support.
#
# Default: enable
#
SMP=enable

如果您手动安装ejabberd,则此文件位于
$ejabberd安装路径/conf
上。

哑巴问题。在命令行上传递“K”参数时会发生什么?也许您还需要指定所有相关软件的名称/版本:例如,我正在Elixir 1.1上运行此软件。1@OnorioCatenacci我更新了我的问题。我想你需要弄清楚这些环境变量应该是什么(看看下面的答案)而不仅仅是删除它们。这不也需要设置其他环境变量吗?ERL_进程和ERL_选项环境变量?@OnorioCatenacci Yes
ERL_进程
ERL_选项
以及一些其他选项在
ejabberdctl.cfg
配置文件中提供。@HamidrezaSoleimani感谢我尝试了这个解决方案,但不幸的是它对我不起作用。
#' POLL: Kernel polling ([true|false])
#
# The kernel polling option requires support in the kernel.
# Additionally, you need to enable this feature while compiling Erlang.
#
# Default: true
#
POLL=true

#.
#' SMP: SMP support ([enable|auto|disable])
#
# Explanation in Erlang/OTP documentation:
# enable: starts the Erlang runtime system with SMP support enabled.
#   This may fail if no runtime system with SMP support is available.
# auto: starts the Erlang runtime system with SMP support enabled if it
#   is available and more than one logical processor are detected.
# disable: starts a runtime system without SMP support.
#
# Default: enable
#
SMP=enable