scrtlabs / discovery-docker-network

Docker Network for the Discovery release of the Enigma Protocol
https://enigma.co
GNU Affero General Public License v3.0
21 stars 2 forks source link

libCppMicroServicesd.so.4.0.0: cannot open shared object file: No such file or directory #16

Closed lacabra closed 5 years ago

lacabra commented 5 years ago

Describe the bug When launching the network, both core and the key management nodes output the following error:

/opt/intel/libsgx-enclave-common/aesm/aesm_service: error while loading shared libraries: libCppMicroServicesd.so.4.0.0: cannot open shared object file: No such file or directory

followed by the following:

core_1      | [+] Home dir is /root
core_1      | [-] Create .enigma folder => AlreadyExists
core_1      | The current directory is /root/enigma-core/enigma-core/app
core_1      | [-] Open token file /root/.enigma/enclave.token error! Will create one.
core_1      | 06:10:21 [INFO] LOG DERIVE: Err(SGX_ERROR_NO_DEVICE)
core_1      | thread 'main' panicked at '[-] Init Enclave Failed: SGX_ERROR_NO_DEVICE', src/libcore/result.rs:999:5
core_1      | stack backtrace:
core_1      |    0: std::sys::unix::backtrace::tracing::imp::unwind_backtrace
core_1      |              at src/libstd/sys/unix/backtrace/tracing/gcc_s.rs:39
core_1      |    1: std::sys_common::backtrace::_print
core_1      |              at src/libstd/sys_common/backtrace.rs:71
core_1      |    2: std::panicking::default_hook::{{closure}}
core_1      |              at src/libstd/sys_common/backtrace.rs:59
core_1      |              at src/libstd/panicking.rs:197
core_1      |    3: std::panicking::default_hook
core_1      |              at src/libstd/panicking.rs:211
core_1      |    4: std::panicking::rust_panic_with_hook
core_1      |              at src/libstd/panicking.rs:474
core_1      |    5: std::panicking::continue_panic_fmt
core_1      |              at src/libstd/panicking.rs:381
core_1      |    6: rust_begin_unwind
core_1      |              at src/libstd/panicking.rs:308
core_1      |    7: core::panicking::panic_fmt
core_1      |              at src/libcore/panicking.rs:85
core_1      |    8: core::result::unwrap_failed
core_1      |              at /rustc/3991285f55a4b7cd92b7ffcdc396a3023076f5cb/src/libcore/macros.rs:18
core_1      |    9: core::result::Result<T,E>::expect
core_1      |              at /rustc/3991285f55a4b7cd92b7ffcdc396a3023076f5cb/src/libcore/result.rs:827
core_1      |   10: enigma_core_app::main
core_1      |              at src/main.rs:27
core_1      |   11: std::rt::lang_start::{{closure}}
core_1      |              at /rustc/3991285f55a4b7cd92b7ffcdc396a3023076f5cb/src/libstd/rt.rs:64
core_1      |   12: std::panicking::try::do_call
core_1      |              at src/libstd/rt.rs:49
core_1      |              at src/libstd/panicking.rs:293
core_1      |   13: __rust_maybe_catch_panic
core_1      |              at src/libpanic_unwind/lib.rs:85
core_1      |   14: std::rt::lang_start_internal
core_1      |              at src/libstd/panicking.rs:272
core_1      |              at src/libstd/panic.rs:388
core_1      |              at src/libstd/rt.rs:48
core_1      |   15: std::rt::lang_start
core_1      |              at /rustc/3991285f55a4b7cd92b7ffcdc396a3023076f5cb/src/libstd/rt.rs:64
core_1      |   16: main
core_1      |   17: __libc_start_main
core_1      |   18: _start

Possibly a side-effect of PR 157 ?

To Reproduce Steps to reproduce the behavior:

  1. Launch the Docker network: ./launch.bash

Expected behavior This error should not occur

elichai commented 5 years ago

Yep. it's a change by intel. you should replace these: https://github.com/enigmampc/discovery-integration-tests/blob/develop/enigma-core/start_km.bash#L4 https://github.com/enigmampc/discovery-integration-tests/blob/develop/enigma-core/start_core.bash#L2 with this line: LD_LIBRARY_PATH=/opt/intel/libsgx-enclave-common/aesm /opt/intel/libsgx-enclave-common/aesm/aesm_service &

lacabra commented 5 years ago

Thanks @elichai, I confirm this fixes the issue.