LoginSignup
2
0

More than 5 years have passed since last update.

erlangのバージョンを上げたらphoenixが起動しなくなった

Posted at

バージョン情報

  • elixir 1.5.1
  • phoenix 1.3.0

内容

ある日、いつものようにphoenixサーバを起動しようとしたら下記のようなエラーになった。

$ mix phx.server
=SUPERVISOR REPORT==== 21-Aug-2018::09:37:27.995612 ===
    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==== 21-Aug-2018::09:37:28.006225 ===
  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:

=INFO REPORT==== 21-Aug-2018::09:37:28.008886 ===
    application: logger
    exited: {{shutdown,
                 {failed_to_start_child,'Elixir.Logger.ErrorHandler',noproc}},
             {'Elixir.Logger.App',start,[normal,[]]}}
    type: temporary
=SUPERVISOR REPORT==== 21-Aug-2018::09:37:33.061893 ===
    supervisor: {local,'Elixir.Logger.Supervisor'}
    errorContext: start_error
    reason: noproc
    offender: [{pid,undefined},
               {id,'Elixir.Logger.ErrorHandler'},
               {mfargs,

先日何も考えずにerlangをアップデートしたのが怪しいと感じたため、次のコマンドでerlangのバージョンを戻してみたところ、解決した。

$ brew switch erlang 20.3.7

別解

別の方法として、elixirのtravis.ymlを見る限りは、elixir 1.7であればerlang21でも動くらしい。
https://github.com/elixir-lang/elixir/blob/v1.7/.travis.yml

2
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
0