1. 程式人生 > >RabbitMQ 安裝 rabbitmq-plugins 報錯

RabbitMQ 安裝 rabbitmq-plugins 報錯

 RabbitMQ windows 版本安裝成功後,啟動 rabbitmq-plugins.bat 外掛報錯。

當前安裝的 erlang 版本是 otp_win64_21.0.1.exe ,RabbitMQ 版本是 rabbitmq-server-3.7.5.exe 。版本不相容。

將erlang 版本更換為 otp_win64_20.2.exe ,並重新配置環境變數後解決。

安裝 rabbitmq-plugins.bat 外掛報錯的資訊

C:\Users\Administrator>"D:\Program Files\RabbitMQ Server\rabbitmq_server-3.7.5\sbin\rabbitmq-plugins.bat" enable rabbitmq_management
=SUPERVISOR REPORT==== 29-Aug-2018::17:50:47.492000 ===
    supervisor: {local,'Elixir.Logger.Supervisor'}
    errorContext: start_error
    reason: noproc
    offender: [{pid,undefined},
               {id,'Elixir.Logger.ErrorHandler'},
               {mfargs,
                   {'Elixir.Logger.Watcher',start_link,
                       [{error_logger,'Elixir.Logger.ErrorHandler',
                            {true,false,500}}]}},
               {restart_type,permanent},
               {shutdown,5000},
               {child_type,worker}]
=CRASH REPORT==== 29-Aug-2018::17:50:47.507000 ===
  crasher:
    initial call: application_master:init/4
    pid: <0.80.0>
    registered_name: []
    exception exit: {{shutdown,
                         {failed_to_start_child,'Elixir.Logger.ErrorHandler',
                             noproc}},
                     {'Elixir.Logger.App',start,[normal,[]]}}
      in function  application_master:init/4 (application_master.erl, line 138)
    ancestors: [<0.79.0>]
    message_queue_len: 1
    messages: [{'EXIT',<0.81.0>,normal}]
    links: [<0.79.0>,<0.42.0>]
    dictionary: []
    trap_exit: true
    status: running
    heap_size: 376
    stack_size: 27
    reductions: 193
  neighbours:

=CRASH REPORT==== 29-Aug-2018::17:50:47.492000 ===
  crasher:
    initial call: Elixir.Logger.Watcher:init/1
    pid: <0.87.0>
    registered_name: []
    exception exit: noproc
      in function  gen:do_for_proc/2 (gen.erl, line 228)
      in call from gen_event:rpc/2 (gen_event.erl, line 239)
      in call from 'Elixir.Logger.Watcher':init/1 (lib/logger/watcher.ex, line 23)
      in call from gen_server:init_it/2 (gen_server.erl, line 374)
      in call from gen_server:init_it/6 (gen_server.erl, line 342)
    ancestors: ['Elixir.Logger.Supervisor',<0.81.0>]
    message_queue_len: 0
    messages: []
    links: [<0.82.0>]
    dictionary: []
    trap_exit: true
    status: running
    heap_size: 376
    stack_size: 27
    reductions: 254
  neighbours:

=INFO REPORT==== 29-Aug-2018::17:50:47.507000 ===
    application: logger
    exited: {{shutdown,
                 {failed_to_start_child,'Elixir.Logger.ErrorHandler',noproc}},
             {'Elixir.Logger.App',start,[normal,[]]}}
    type: temporary
Could not start application logger: Logger.App.start(:normal, []) returned an error: shutdown: failed to start child: Logger.ErrorHandler
    ** (EXIT) no process: the process is not alive or there's no process currently associated with the given name, possibly because its application isn't started

重新安裝 erlang 後,重新配置 erlang 的環境變數

再次嘗試安裝 RabbitMQ-plugins

C:\Users\Administrator>cd D:\Program Files\RabbitMQ Server\rabbitmq_server-3.7.5\sbin

C:\Users\Administrator>d:

D:\Program Files\RabbitMQ Server\rabbitmq_server-3.7.5\sbin>"D:\Program Files\RabbitMQ Server\rabbitmq_server-3.7.5\sbin\rabbitmq-plugins.bat" enable rabbitmq_management
Enabling plugins on node 
[email protected]
: rabbitmq_management The following plugins have been configured: rabbitmq_management rabbitmq_management_agent rabbitmq_web_dispatch Applying plugin configuration to [email protected] The following plugins have been enabled: rabbitmq_management rabbitmq_management_agent rabbitmq_web_dispatch set 3 plugins. Offline change; changes will take effect at broker restart.

可以看到安裝成功。

參考文章 https://blog.csdn.net/weixin_39270764/article/details/80907917