[erlang-questions] Problems with cowboy:start_clear() - undefined function

Loïc Hoguin essen@REDACTED
Sun Aug 26 19:49:15 CEST 2018


You need to add this to your Makefile:

dep_cowboy_commit = master

See https://ninenines.eu/docs/en/cowboy/2.4/guide/getting_started/

If you really wanted Cowboy 1.x then you're reading the wrong docs.

On 08/26/2018 05:32 PM, Drasko DRASKOVIC wrote:
> Hi all,
> I am trying to run https://github.com/drasko/erlang-starter-kit and I
> am getting:
> 
> Exec: /home/drasko/erlang/esk/_rel/esk_release/erts-9.3.3.3/bin/erlexec
> -boot /home/drasko/erlang/esk/_rel/esk_release/releases/1/esk_release
> -mode embedded -boot_var ERTS_LIB_DIR
> /home/drasko/erlang/esk/_rel/esk_release/lib -config
> /home/drasko/erlang/esk/_rel/esk_release/releases/1/sys.config
> -args_file /home/drasko/erlang/esk/_rel/esk_release/releases/1/vm.args
> -pa -- console
> Root: /home/drasko/erlang/esk/_rel/esk_release
> /home/drasko/erlang/esk/_rel/esk_release
> heart_beat_kill_pid = 3160
> Erlang/OTP 20 [erts-9.3.3.3] [source] [64-bit] [smp:8:8] [ds:8:8:10]
> [async-threads:10] [kernel-poll:false]
> 
> 17:23:46.517 [info] Application lager started on node 'esk@REDACTED'
> 17:23:46.517 [info] Application asn1 started on node 'esk@REDACTED'
> 17:23:46.518 [info] Application public_key started on node 'esk@REDACTED'
> 17:23:46.519 [info] Application ssl started on node 'esk@REDACTED'
> 17:23:46.519 [info] Application unicode_util_compat started on node
> 'esk@REDACTED'
> 17:23:46.519 [info] Application idna started on node 'esk@REDACTED'
> 17:23:46.519 [info] Application mimerl started on node 'esk@REDACTED'
> 17:23:46.520 [info] Application certifi started on node 'esk@REDACTED'
> 17:23:46.520 [info] Application ssl_verify_fun started on node 'esk@REDACTED'
> 17:23:46.520 [info] Application metrics started on node 'esk@REDACTED'
> 17:23:46.520 [info] Application hackney started on node 'esk@REDACTED'
> 17:23:46.521 [info] Application couchbeam started on node 'esk@REDACTED'
> 17:23:46.522 [error] CRASH REPORT Process <0.608.0> with 0 neighbours
> exited with reason: call to undefined function
> cowboy:start_clear(esk_cowboy, [{ip,{0,0,0,0}},{port,8089}], #{env =>
> #{dispatch => [{'_',[],[{[<<"status">>],[],esk_status,[]},{[<<"user">>],[],esk_user,...},...]}]}})
> in application_master:init/4 line 134
> 17:23:46.522 [info] Application esk exited with reason: call to
> undefined function cowboy:start_clear(esk_cowboy,
> [{ip,{0,0,0,0}},{port,8089}], #{env => #{dispatch =>
> [{'_',[],[{[<<"status">>],[],esk_status,[]},{[<<"user">>],[],esk_user,...},...]}]}})
> {"Kernel pid terminated",application_controller,"{application_start_failure,esk,{bad_return,{{esk_app,start,[normal,[]]},{'EXIT',{undef,[{cowboy,start_clear,[esk_cowboy,[{ip,{0,0,0,0}},{port,8089}],#{env
> => #{dispatch =>
> [{'_',[],[{[<<\"status\">>],[],esk_status,[]},{[<<\"user\">>],[],esk_user,[]},{[<<\"login\">>],[],esk_login,[]}]}]}}],[]},{esk_app,start,2,[{file,\"src/esk_app.erl\"},{line,32}]},{application_master,start_it_old,4,[{file,\"application_master.erl\"},{line,273}]}]}}}}}"}
> Kernel pid terminated (application_controller)
> ({application_start_failure,esk,{bad_return,{{esk_app,start,[normal,[]]},{'EXIT',{undef,[{cowboy,start_clear,[esk_cowboy,[{ip,{0,0,0,0}},{port,8089}],#{e
> heart: Sun Aug 26 17:23:48 2018: Erlang is crashing .. (waiting for
> crash dump file)
> heart: Sun Aug 26 17:23:48 2018: Would reboot. Terminating.
> make: *** [erlang.mk:6782: run] Error 1
> 
> Any idea why this is happening?
> 
> I am running Debian Buster with Erlang/OTP 20.
> 
> BR,
> Drasko
> _______________________________________________
> erlang-questions mailing list
> erlang-questions@REDACTED
> http://erlang.org/mailman/listinfo/erlang-questions
> 

-- 
Loïc Hoguin
https://ninenines.eu



More information about the erlang-questions mailing list