Facing error in BlocScout manual deployment's

when i try to execute blocscout in my localsystem then i get this error please help me to resolve this error

Compiling NIF crate :exkeccak (native/exkeccak)…
Compiling rustler v0.21.1
error: failed to run custom build command for rustler v0.21.1

Caused by:
process didn’t exit successfully: /home/ankit/Desktop/bsc/blockscout/_build/dev/rustler_crates/exkeccak/release/build/rustler-6a72775c47ff9e24/build-script-build (exit code: 101)
— stderr
thread ‘main’ panicked at ‘Erlang version 2.16 not handled, please file a a bug report.’, /root/.cargo/registry/src/github.com-1ecc6299db9ec823/rustler-0.21.1/build.rs:50:10
note: run with RUST_BACKTRACE=1 environment variable to display a backtrace
could not compile dependency :ex_keccak, “mix compile” failed. You can recompile this dependency with “mix deps.compile ex_keccak”, update it with “mix deps.update ex_keccak” or clean it with “mix deps.clean ex_keccak”
** (RuntimeError) Rust NIF compile error (rustc exit code 101)
(rustler 0.21.1) lib/mix/tasks/compile.rustler.ex:68: Mix.Tasks.Compile.Rustler.compile_crate/1
(elixir 1.12.2) lib/enum.ex:1582: Enum."-map/2-lists^map/1-0-"/2
(rustler 0.21.1) lib/mix/tasks/compile.rustler.ex:15: Mix.Tasks.Compile.Rustler.run/1
(mix 1.12.2) lib/mix/task.ex:394: anonymous fn/3 in Mix.Task.run_task/3
(mix 1.12.2) lib/mix/tasks/compile.all.ex:92: Mix.Tasks.Compile.All.run_compiler/2
(mix 1.12.2) lib/mix/tasks/compile.all.ex:72: Mix.Tasks.Compile.All.compile/4
(mix 1.12.2) lib/mix/tasks/compile.all.ex:59: Mix.Tasks.Compile.All.with_logger_app/2
(mix 1.12.2) lib/mix/tasks/compile.all.ex:36: Mix.Tasks.Compile.All.run/1

Hi @nankit0, welcome to the forum!

This issue’s comment might help?
Rustler doesn’t compile with Erlang OTP 24

2 Likes

try and update https://github.com/tzumby/ex_keccak to latest which uses rustler 0.22…

2 Likes

Thanks for your reply @03juan and @outlog but it’s not work for me because i’m facing this error in BlockScout

Hello all
I found the solution of this error
step1 - In our code we have " .tools-versions " files, open it and check elixir,erlang and node’s version
step2 - Install asdf in your system threw github ( " Getting Started | asdf " )
step-3 - Install same version of elixir and erlang using asdf using github or these websites
Elixir { github = GitHub - asdf-vm/asdf-elixir: Elixir plugin for asdf version manager
websites’s link = https://www.pluralsight.com/guides/installing-elixir-erlang-with-asdf ,
website link = Elixir 1.11 and Erlang Docs - Thinking Elixir } ,
Erlang = { github = GitHub - asdf-vm/asdf-erlang: Erlang plugin for asdf version manager }

3 Likes

Hey @nankit0
Were you able to run Blockscout locally in your system?
If yes can you please share the steps you have taken because I’m trying to run it in my system but ending up with these errors

blockscout git:(master) iex -S mix phx.server
Erlang/OTP 23 [erts-11.2.2.1] [source] [64-bit] [smp:4:4] [ds:4:4:10] [async-threads:1] [hipe]

2021-08-19T22:15:43.376 application=que [info] [Que] Booting Que
2021-08-19T22:15:43.376 application=que [info] [Que] Booting Server Supervisor for Workers
2021-08-19T22:15:43.527 fetcher=block_catchup [error] Task #PID<0.768.0> started from Indexer.Block.Catchup.BoundIntervalSupervisor terminating
** (MatchError) no match of right hand side value: {:error, :econnrefused}
    (indexer 0.1.0) lib/indexer/block/catchup/fetcher.ex:76: Indexer.Block.Catchup.Fetcher.task/1
    (elixir 1.11.4) lib/task/supervised.ex:90: Task.Supervised.invoke_mfa/2
    (elixir 1.11.4) lib/task/supervised.ex:35: Task.Supervised.reply/5
    (stdlib 3.14.2) proc_lib.erl:226: :proc_lib.init_p_do_apply/3
Function: &Indexer.Block.Catchup.Fetcher.task/1
    Args: [%Indexer.Block.Catchup.Fetcher{block_fetcher: %Indexer.Block.Fetcher{broadcast: :catchup, callback_module: Indexer.Block.Catchup.Fetcher, json_rpc_named_arguments: [transport: EthereumJSONRPC.HTTP, transport_options: [http: EthereumJSONRPC.HTTP.HTTPoison, url: "http://localhost:7545", http_options: [recv_timeout: 60000, timeout: 60000, hackney: [pool: :ethereum_jsonrpc]]], variant: EthereumJSONRPC.Ganache], receipts_batch_size: 250, receipts_concurrency: 10}, blocks_batch_size: 10, blocks_concurrency: 10, memory_monitor: Indexer.Memory.Monitor}]
2021-08-19T22:15:43.552 application=indexer fetcher=block_catchup [error] Catchup index stream exited with reason ({{:badmatch, {:error, :econnrefused}}, [{Indexer.Block.Catchup.Fetcher, :task, 1, [file: 'lib/indexer/block/catchup/fetcher.ex', line: 76]}, {Task.Supervised, :invoke_mfa, 2, [file: 'lib/task/supervised.ex', line: 90]}, {Task.Supervised, :reply, 5, [file: 'lib/task/supervised.ex', line: 35]}, {:proc_lib, :init_p_do_apply, 3, [file: 'proc_lib.erl', line: 226]}]}). Restarting
2021-08-19T22:15:43.576 fetcher=block_catchup [error] Task #PID<0.873.0> started from Indexer.Block.Catchup.BoundIntervalSupervisor terminating
** (MatchError) no match of right hand side value: {:error, :econnrefused}
    (indexer 0.1.0) lib/indexer/block/catchup/fetcher.ex:76: Indexer.Block.Catchup.Fetcher.task/1
    (elixir 1.11.4) lib/task/supervised.ex:90: Task.Supervised.invoke_mfa/2
    (elixir 1.11.4) lib/task/supervised.ex:35: Task.Supervised.reply/5
    (stdlib 3.14.2) proc_lib.erl:226: :proc_lib.init_p_do_apply/3
Function: &Indexer.Block.Catchup.Fetcher.task/1
    Args: [%Indexer.Block.Catchup.Fetcher{block_fetcher: %Indexer.Block.Fetcher{broadcast: :catchup, callback_module: Indexer.Block.Catchup.Fetcher, json_rpc_named_arguments: [transport: EthereumJSONRPC.HTTP, transport_options: [http: EthereumJSONRPC.HTTP.HTTPoison, url: "http://localhost:7545", http_options: [recv_timeout: 60000, timeout: 60000, hackney: [pool: :ethereum_jsonrpc]]], variant: EthereumJSONRPC.Ganache], receipts_batch_size: 250, receipts_concurrency: 10}, blocks_batch_size: 10, blocks_concurrency: 10, memory_monitor: Indexer.Memory.Monitor}]
2021-08-19T22:15:43.578 application=indexer fetcher=block_catchup [error] Catchup index stream exited with reason ({{:badmatch, {:error, :econnrefused}}, [{Indexer.Block.Catchup.Fetcher, :task, 1, [file: 'lib/indexer/block/catchup/fetcher.ex', line: 76]}, {Task.Supervised, :invoke_mfa, 2, [file: 'lib/task/supervised.ex', line: 90]}, {Task.Supervised, :reply, 5, [file: 'lib/task/supervised.ex', line: 35]}, {:proc_lib, :init_p_do_apply, 3, [file: 'proc_lib.erl', line: 226]}]}). Restarting
** (Mix) Could not start application block_scout_web: BlockScoutWeb.Application.start(:normal, []) returned an error: shutdown: failed to start child: BlockScoutWeb.Endpoint
    ** (EXIT) an exception was raised:
        ** (ArgumentError) could not start Cowboy2 adapter, the file /Users/ambi/Desktop/blockscout-f/blockscout/_build/dev/lib/block_scout_web/priv/cert/selfsigned_key.pem required by SSL's :keyfile either does not exist, or the application does not have permission to access it
            (plug_cowboy 2.4.1) lib/plug/cowboy.ex:335: Plug.Cowboy.fail/1
            (plug_cowboy 2.4.1) lib/plug/cowboy.ex:80: Plug.Cowboy.args/4
            (plug_cowboy 2.4.1) lib/plug/cowboy.ex:188: Plug.Cowboy.child_spec/1
            (phoenix 1.5.6) lib/phoenix/endpoint/cowboy2_adapter.ex:84: Phoenix.Endpoint.Cowboy2Adapter.child_spec/3
            (phoenix 1.5.6) lib/phoenix/endpoint/cowboy2_adapter.ex:64: anonymous fn/5 in Phoenix.Endpoint.Cowboy2Adapter.child_specs/2
            (elixir 1.11.4) lib/enum.ex:2193: Enum."-reduce/3-lists^foldl/2-0-"/3
            (phoenix 1.5.6) lib/phoenix/endpoint/cowboy2_adapter.ex:55: Phoenix.Endpoint.Cowboy2Adapter.child_specs/2
            (phoenix 1.5.6) lib/phoenix/endpoint/supervisor.ex:106: Phoenix.Endpoint.Supervisor.init/1
            (stdlib 3.14.2) supervisor.erl:301: :supervisor.init/1
            (stdlib 3.14.2) gen_server.erl:417: :gen_server.init_it/2
            (stdlib 3.14.2) gen_server.erl:385: :gen_server.init_it/6
            (stdlib 3.14.2) proc_lib.erl:226: :proc_lib.init_p_do_apply/3
2021-08-19T22:15:43.594 fetcher=block_catchup [error] Task #PID<0.876.0> started from Indexer.Block.Catchup.BoundIntervalSupervisor terminating
** (MatchError) no match of right hand side value: {:error, :econnrefused}
    (indexer 0.1.0) lib/indexer/block/catchup/fetcher.ex:76: Indexer.Block.Catchup.Fetcher.task/1
    (elixir 1.11.4) lib/task/supervised.ex:90: Task.Supervised.invoke_mfa/2
    (elixir 1.11.4) lib/task/supervised.ex:35: Task.Supervised.reply/5
    (stdlib 3.14.2) proc_lib.erl:226: :proc_lib.init_p_do_apply/3
Function: &Indexer.Block.Catchup.Fetcher.task/1
    Args: [%Indexer.Block.Catchup.Fetcher{block_fetcher: %Indexer.Block.Fetcher{broadcast: :catchup, callback_module: Indexer.Block.Catchup.Fetcher, json_rpc_named_arguments: [transport: EthereumJSONRPC.HTTP, transport_options: [http: EthereumJSONRPC.HTTP.HTTPoison, url: "http://localhost:7545", http_options: [recv_timeout: 60000, timeout: 60000, hackney: [pool: :ethereum_jsonrpc]]], variant: EthereumJSONRPC.Ganache], receipts_batch_size: 250, receipts_concurrency: 10}, blocks_batch_size: 10, blocks_concurrency: 10, memory_monitor: Indexer.Memory.Monitor}]
2021-08-19T22:15:43.599 application=indexer fetcher=block_catchup [error] Catchup index stream exited with reason ({{:badmatch, {:error, :econnrefused}}, [{Indexer.Block.Catchup.Fetcher, :task, 1, [file: 'lib/indexer/block/catchup/fetcher.ex', line: 76]}, {Task.Supervised, :invoke_mfa, 2, [file: 'lib/task/supervised.ex', line: 90]}, {Task.Supervised, :reply, 5, [file: 'lib/task/supervised.ex', line: 35]}, {:proc_lib, :init_p_do_apply, 3, [file: 'proc_lib.erl', line: 226]}]}). Restarting
2021-08-19T22:15:43.597 [info] Application block_scout_web exited: BlockScoutWeb.Application.start(:normal, []) returned an error: shutdown: failed to start child: BlockScoutWeb.Endpoint
    ** (EXIT) an exception was raised:
        ** (ArgumentError) could not start Cowboy2 adapter, the file /Users/ambi/Desktop/blockscout-f/blockscout/_build/dev/lib/block_scout_web/priv/cert/selfsigned_key.pem required by SSL's :keyfile either does not exist, or the application does not have permission to access it
            (plug_cowboy 2.4.1) lib/plug/cowboy.ex:335: Plug.Cowboy.fail/1
            (plug_cowboy 2.4.1) lib/plug/cowboy.ex:80: Plug.Cowboy.args/4
            (plug_cowboy 2.4.1) lib/plug/cowboy.ex:188: Plug.Cowboy.child_spec/1
            (phoenix 1.5.6) lib/phoenix/endpoint/cowboy2_adapter.ex:84: Phoenix.Endpoint.Cowboy2Adapter.child_spec/3
            (phoenix 1.5.6) lib/phoenix/endpoint/cowboy2_adapter.ex:64: anonymous fn/5 in Phoenix.Endpoint.Cowboy2Adapter.child_specs/2
            (elixir 1.11.4) lib/enum.ex:2193: Enum."-reduce/3-lists^foldl/2-0-"/3
            (phoenix 1.5.6) lib/phoenix/endpoint/cowboy2_adapter.ex:55: Phoenix.Endpoint.Cowboy2Adapter.child_specs/2
            (phoenix 1.5.6) lib/phoenix/endpoint/supervisor.ex:106: Phoenix.Endpoint.Supervisor.init/1
            (stdlib 3.14.2) supervisor.erl:301: :supervisor.init/1
            (stdlib 3.14.2) gen_server.erl:417: :gen_server.init_it/2
            (stdlib 3.14.2) gen_server.erl:385: :gen_server.init_it/6
            (stdlib 3.14.2) proc_lib.erl:226: :proc_lib.init_p_do_apply/3
2021-08-19T22:15:43.605 fetcher=block_catchup [error] Task #PID<0.898.0> started from Indexer.Block.Catchup.BoundIntervalSupervisor terminating
** (MatchError) no match of right hand side value: {:error, :econnrefused}
    (indexer 0.1.0) lib/indexer/block/catchup/fetcher.ex:76: Indexer.Block.Catchup.Fetcher.task/1
    (elixir 1.11.4) lib/task/supervised.ex:90: Task.Supervised.invoke_mfa/2
    (elixir 1.11.4) lib/task/supervised.ex:35: Task.Supervised.reply/5
    (stdlib 3.14.2) proc_lib.erl:226: :proc_lib.init_p_do_apply/3
Function: &Indexer.Block.Catchup.Fetcher.task/1
    Args: [%Indexer.Block.Catchup.Fetcher{block_fetcher: %Indexer.Block.Fetcher{broadcast: :catchup, callback_module: Indexer.Block.Catchup.Fetcher, json_rpc_named_arguments: [transport: EthereumJSONRPC.HTTP, transport_options: [http: EthereumJSONRPC.HTTP.HTTPoison, url: "http://localhost:7545", http_options: [recv_timeout: 60000, timeout: 60000, hackney: [pool: :ethereum_jsonrpc]]], variant: EthereumJSONRPC.Ganache], receipts_batch_size: 250, receipts_concurrency: 10}, blocks_batch_size: 10, blocks_concurrency: 10, memory_monitor: Indexer.Memory.Monitor}]
2021-08-19T22:15:43.607 application=indexer fetcher=block_catchup [error] Catchup index stream exited with reason ({{:badmatch, {:error, :econnrefused}}, [{Indexer.Block.Catchup.Fetcher, :task, 1, [file: 'lib/indexer/block/catchup/fetcher.ex', line: 76]}, {Task.Supervised, :invoke_mfa, 2, [file: 'lib/task/supervised.ex', line: 90]}, {Task.Supervised, :reply, 5, [file: 'lib/task/supervised.ex', line: 35]}, {:proc_lib, :init_p_do_apply, 3, [file: 'proc_lib.erl', line: 226]}]}). Restarting

i have done all General Requirements / BlockScout Prerequisites
mentioned on blockscout site
GitHub: bloclscout
still errors popping up

1 Like

Hello @ambareesha7 i also get this error and i also trying to resolve it
once it’s resolve i’ll tell you or you resolved it then please tell me how

Sure, thank you

1 Like

Hello @ambareesha7 hope you are doing well
have you resolve your error ?
if not click on this link here i get my error’s solution

1 Like

Thank you @nankit0

1 Like

@nankit0 Hello, can you tell me the specific steps of this problem? I also encountered the same problem. The version I use is
erlang_24.1-1
Elixir 1.12
PostGIS30_12
PostgresSQL 12
nodejs v14.0.0

Hello @mgl_mkc
could you please share your .tools-versions file’s text here ( in this file we have actual version of elixir, erlang and node which we want to require.)

try with erlang 23. I couldn’t make rustler work on erlang 24 also @03juan has mentioned that in the thread earler

Where is the. Tools versions file
I use blockscout: v3 7.3-beta
Reference link is Installing blockscout under centos7

I’ll try Thank you

[root@aubin blockscout]# find / -name ‘tools-
/var/lib/yum/yumdb/a/1bf477eec3dedcb1886351c87eb19b82c8114e42-alsa-tools-firmware-1.1.0-1.el7-x86_64
/var/lib/yum/yumdb/k/edb34fa3fec0b5ea6eb0e9dad5c24ae70b479839-kernel-tools-libs-3.10.0-1160.59.1.el7-x86_64
/var/lib/yum/yumdb/k/53da3757aaa98da54f9276741ae694f28da3432f-kexec-tools-2.0.15-51.el7_9.3-x86_64
/var/lib/yum/yumdb/k/61fd47f64447eb5675e60e6eb619776efbf08187-kernel-tools-3.10.0-1160.59.1.el7-x86_64
/var/lib/yum/yumdb/g/c2bc1fddac1842a7c742eaa22dd690374f722b06-grub2-tools-minimal-2.02-0.87.el7.centos.7-x86_64
/var/lib/yum/yumdb/g/d17a509635a1c39263340cc6312042ab1cf1883e-grub2-tools-extra-2.02-0.87.el7.centos.7-x86_64
/var/lib/yum/yumdb/g/f13a6ec21d5824f520825a5315d334c560337f9b-grub2-tools-2.02-0.87.el7.centos.7-x86_64
/var/lib/yum/yumdb/s/9832d1ee8eb926d669fb02ad850867abf9c91d5d-sysvinit-tools-2.88-14.dsf.el7-x86_64
/var/lib/yum/yumdb/n/028834ec48befdf50052eaf3ecbddd6711db61eb-net-tools-2.0-0.25.20131004git.el7-x86_64
/var/lib/yum/yumdb/n/fc72404159a498d30cb6345c6b877391c9d8d23b-nss-tools-3.67.0-4.el7_9-x86_64
/var/lib/yum/yumdb/i/1d48d512e1a0097ee5dba51905701e72cb36dce5-inotify-tools-3.14-9.el7-x86_64
/usr/lib/udev/rules.d/90-alsa-tools-firmware.rules
/usr/lib/erlang/lib/parsetools-2.3.1
/usr/lib/erlang/lib/runtime_tools-1.17
/usr/lib/erlang/lib/syntax_tools-2.6
/usr/lib/erlang/lib/tools-3.5.1
/usr/share/doc/sysvinit-tools-2.88
/usr/share/doc/alsa-tools-1.1.0
/usr/share/doc/kexec-tools-2.0.15
/usr/share/doc/git-1.8.3.1/mergetools-diff.txt
/usr/share/doc/git-1.8.3.1/mergetools-merge.txt
/usr/share/doc/net-tools-2.0
/usr/share/doc/inotify-tools-3.14

This is what’s in the tools-versions file

elixir 1.11.4-otp-23

erlang 23.3.4.1

nodejs 14.17.0

@mgl_mkc you have 2 options choose any of them
1- you need to install same version which is mentioned in tool-versions file
2- or you can change text in tool-versions file like in your system elixir version is 1.12 and in tool-version file elixir version is 1.14 than change tool-version file text from 1.14 to 1.12. than compile it again.

Ok thank you