Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build: signal: 11, SIGSEGV: invalid memory reference fail #990

Closed
OvoNemaSmisla opened this issue Jan 11, 2024 · 21 comments
Closed

Build: signal: 11, SIGSEGV: invalid memory reference fail #990

OvoNemaSmisla opened this issue Jan 11, 2024 · 21 comments
Labels
bug Something isn't working build

Comments

@OvoNemaSmisla
Copy link

Have you read the documentation?
Yes.

Did you double-check that you installed all dependencies?
Yes.

Which command failed?
cargo build --locked --release

What was the error message?

Error message
   Compiling libc v0.2.151
   Compiling proc-macro2 v1.0.71
   Compiling serde v1.0.171
   Compiling autocfg v1.1.0                                                                                                                                                                                                                  /lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x6c4430)[0x7f8c2e4430]                                                                                                                                                          linux-vdso.so.1(__kernel_rt_sigreturn+0x0)[0x7f8f34d7bc]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(+0x132a9f0)[0x7f8695a9f0]
linux-vdso.so.1(__kernel_rt_sigreturn+0x0)[0x7f8f34d7bc]                                                                                                                                                                            [60/1000]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(+0x132a9f0)[0x7f8695a9f0]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm11raw_ostream5writeEPKcm+0x164)[0x7f864ab49c]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x6c4430)[0x7f9a4b4430]
linux-vdso.so.1(__kernel_rt_sigreturn+0x0)[0x7f9d5277bc]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(+0x132a9f0)[0x7f94b2a9f0]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm11raw_ostream5writeEPKcm+0x164)[0x7f9467b49c]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm9MCContext16createTempSymbolERKNS_5TwineEb+0xb4)[0x7f87861048]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm9MCContext16createTempSymbolERKNS_5TwineEb+0xb4)[0x7f95a31048]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x6c4430)[0x7fb4404430]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm9MCContext16createTempSymbolEv+0x3c)[0x7f878613f0]
linux-vdso.so.1(__kernel_rt_sigreturn+0x0)[0x7fb74757bc]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(+0x132a9f0)[0x7faea7a9f0]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm9MCContext16createTempSymbolEv+0x3c)[0x7f95a313f0]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm11raw_ostream5writeEPKcm+0x164)[0x7fae5cb49c]                                                                                                                                                 /lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm16MCObjectStreamer18emitCFIEndProcImplERNS_16MCDwarfFrameInfoE+0x1c)[0x7f87885c6c]                                                                                                            /lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm16MCObjectStreamer18emitCFIEndProcImplERNS_16MCDwarfFrameInfoE+0x1c)[0x7f95a55c6c]                                                                                                            /lib/aarch64-linux-gnu/libLLVM-14.so.1(+0x165f4c0)[0x7f94e5f4c0]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(+0x165f4c0)[0x7f86c8f4c0]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm9MCContext16createTempSymbolERKNS_5TwineEb+0xb4)[0x7faf981048]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm10AsmPrinter16emitFunctionBodyEv+0x264c)[0x7f86c70b6c]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm10AsmPrinter16emitFunctionBodyEv+0x264c)[0x7f94e40b6c]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm9MCContext16createTempSymbolEv+0x3c)[0x7faf9813f0]                                                                                                                                            /lib/aarch64-linux-gnu/libLLVM-14.so.1(+0x2764ba4)[0x7f95f64ba4]                                                                                                                                                                             /lib/aarch64-linux-gnu/libLLVM-14.so.1(+0x2764ba4)[0x7f87d94ba4]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm19MachineFunctionPass13runOnFunctionERNS_8FunctionE+0x140)[0x7f949f122c]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm19MachineFunctionPass13runOnFunctionERNS_8FunctionE+0x140)[0x7f8682122c]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm16MCObjectStreamer18emitCFIEndProcImplERNS_16MCDwarfFrameInfoE+0x1c)[0x7faf9a5c6c]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm13FPPassManager13runOnFunctionERNS_8FunctionE+0x26c)[0x7f947d4390]                                                                                                                            /lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm13FPPassManager13runOnFunctionERNS_8FunctionE+0x26c)[0x7f86604390]                                                                                                                            /lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm13FPPassManager11runOnModuleERNS_6ModuleE+0x3c)[0x7f947daf70]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm13FPPassManager11runOnModuleERNS_6ModuleE+0x3c)[0x7f8660af70]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm6legacy15PassManagerImpl3runERNS_6ModuleE+0x7b4)[0x7f947d4d98]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm6legacy15PassManagerImpl3runERNS_6ModuleE+0x7b4)[0x7f86604d98]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x951d8c)[0x7f9a741d8c]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(+0x165f4c0)[0x7faedaf4c0]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x951d8c)[0x7f8c571d8c]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x92c114)[0x7f9a71c114]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x92c114)[0x7f8c54c114]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x930d88)[0x7f9a720d88]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x930d88)[0x7f8c550d88]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x925db4)[0x7f9a715db4]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x925db4)[0x7f8c545db4]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x921230)[0x7f9a711230]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x921230)[0x7f8c541230]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x80c0c0)[0x7f9a5fc0c0]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x80c0c0)[0x7f8c42c0c0]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x8f6608)[0x7f9a6e6608]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x8f6608)[0x7f8c516608]
/lib/aarch64-linux-gnu/libstd-4e83e61126e325db.so(rust_metadata_std_aeb45179e3b08762+0x9ffec)[0x7f99cdffec]
/lib/aarch64-linux-gnu/libc.so.6(+0x7ee18)[0x7f99b0ee18]
/lib/aarch64-linux-gnu/libstd-4e83e61126e325db.so(rust_metadata_std_aeb45179e3b08762+0x9ffec)[0x7f8bb0ffec]
/lib/aarch64-linux-gnu/libc.so.6(+0x7ee18)[0x7f8b93ee18]
/lib/aarch64-linux-gnu/libc.so.6(+0xe7e9c)[0x7f99b77e9c]
/lib/aarch64-linux-gnu/libc.so.6(+0xe7e9c)[0x7f8b9a7e9c]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm10AsmPrinter16emitFunctionBodyEv+0x264c)[0x7faed90b6c]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(+0x2764ba4)[0x7fafeb4ba4]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm19MachineFunctionPass13runOnFunctionERNS_8FunctionE+0x140)[0x7fae94122c]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm13FPPassManager13runOnFunctionERNS_8FunctionE+0x26c)[0x7fae724390]                                                                                                                            /lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm13FPPassManager11runOnModuleERNS_6ModuleE+0x3c)[0x7fae72af70]                                                                                                                                 /lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm6legacy15PassManagerImpl3runERNS_6ModuleE+0x7b4)[0x7fae724d98]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x951d8c)[0x7fb4691d8c]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm6legacy15PassManagerImpl3runERNS_6ModuleE+0x7b4)[0x7fae724d98]                                                                                                                        [0/1000]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x951d8c)[0x7fb4691d8c]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x92c114)[0x7fb466c114]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x930d88)[0x7fb4670d88]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x925db4)[0x7fb4665db4]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x921230)[0x7fb4661230]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x80c0c0)[0x7fb454c0c0]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x8f6608)[0x7fb4636608]
/lib/aarch64-linux-gnu/libstd-4e83e61126e325db.so(rust_metadata_std_aeb45179e3b08762+0x9ffec)[0x7fb3c2ffec]
/lib/aarch64-linux-gnu/libc.so.6(+0x7ee18)[0x7fb3a5ee18]
/lib/aarch64-linux-gnu/libc.so.6(+0xe7e9c)[0x7fb3ac7e9c]
error: could not compile `serde`

Caused by:
  process didn't exit successfully: `rustc --crate-name build_script_build /home/admin/.cargo/registry/src/github.com-1ecc6299db9ec823/serde-1.0.171/build.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --crate-type bin --emit=dep-info,link -C embed-bitcode=no -C debug-assertions=off --cfg 'feature="alloc"' --cfg 'feature="default"' --cfg 'feature="derive"' --cfg 'feature="serde_derive"' --cfg 'feature="std"' -C metadata=78795a5c89f57fcd -C extra-filename=-78795a5c89f57fcd --out-dir /home/admin/rust/electrs/target/release/build/serde-78795a5c89f57fcd -L dependency=/home/admin/rust/electrs/target/release/deps --cap-lints allow` (signal: 11, SIGSEGV: invalid memory reference)
warning: build failed, waiting for other jobs to finish...
error: could not compile `proc-macro2`

Caused by:
  process didn't exit successfully: `rustc --crate-name build_script_build --edition=2021 /home/admin/.cargo/registry/src/github.com-1ecc6299db9ec823/proc-macro2-1.0.71/build.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --crate-type bin --emit=dep-info,link -C embed-bitcode=no -C debug-assertions=off --cfg 'feature="default"' --cfg 'feature="proc-macro"' -C metadata=beb95e6656d1e006 -C extra-filename=-beb95e6656d1e006 --out-dir /home/admin/rust/electrs/target/release/build/proc-macro2-beb95e6656d1e006 -L dependency=/home/admin/rust/electrs/target/release/deps --cap-lints allow` (signal: 11, SIGSEGV: invalid memory reference)
error: could not compile `libc`

Caused by:
  process didn't exit successfully: `rustc --crate-name build_script_build /home/admin/.cargo/registry/src/github.com-1ecc6299db9ec823/libc-0.2.151/build.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --crate-type bin --emit=dep-info,link -C embed-bitcode=no -C debug-assertions=off --cfg 'feature="default"' --cfg 'feature="std"' -C metadata=fafbb2462b388e90 -C extra-filename=-fafbb2462b388e90 --out-dir /home/admin/rust/electrs/target/release/build/libc-fafbb2462b388e90 -L dependency=/home/admin/rust/electrs/target/release/deps --cap-lints allow` (signal: 11, SIGSEGV: invalid memory reference)
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x6c4430)[0x7faebe4430]
linux-vdso.so.1(__kernel_rt_sigreturn+0x0)[0x7fb1c4e7bc]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(+0x132a9f0)[0x7fa925a9f0]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm11raw_ostream5writeEPKcm+0x164)[0x7fa8dab49c]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm9MCContext16createTempSymbolERKNS_5TwineEb+0xb4)[0x7faa161048]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm9MCContext16createTempSymbolEv+0x3c)[0x7faa1613f0]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm16MCObjectStreamer18emitCFIEndProcImplERNS_16MCDwarfFrameInfoE+0x1c)[0x7faa185c6c]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(+0x165f4c0)[0x7fa958f4c0]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm10AsmPrinter16emitFunctionBodyEv+0x264c)[0x7fa9570b6c]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(+0x2764ba4)[0x7faa694ba4]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm19MachineFunctionPass13runOnFunctionERNS_8FunctionE+0x140)[0x7fa912122c]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm13FPPassManager13runOnFunctionERNS_8FunctionE+0x26c)[0x7fa8f04390]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm13FPPassManager11runOnModuleERNS_6ModuleE+0x3c)[0x7fa8f0af70]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm6legacy15PassManagerImpl3runERNS_6ModuleE+0x7b4)[0x7fa8f04d98]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x951d8c)[0x7faee71d8c]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x92c114)[0x7faee4c114]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x930d88)[0x7faee50d88]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x925db4)[0x7faee45db4]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x921230)[0x7faee41230]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x80c0c0)[0x7faed2c0c0]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x8f6608)[0x7faee16608]
/lib/aarch64-linux-gnu/libstd-4e83e61126e325db.so(rust_metadata_std_aeb45179e3b08762+0x9ffec)[0x7fae40ffec]
/lib/aarch64-linux-gnu/libc.so.6(+0x7ee18)[0x7fae23ee18]
/lib/aarch64-linux-gnu/libc.so.6(+0xe7e9c)[0x7fae2a7e9c]
error: could not compile `autocfg`

Caused by:
  process didn't exit successfully: `rustc --crate-name autocfg /home/admin/.cargo/registry/src/github.com-1ecc6299db9ec823/autocfg-1.1.0/src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --crate-type lib --emit=dep-info,metadata,link -C embed-bitcode=no -C debug-assertions=off -C metadata=a60d3e6346f26eda -C extra-filename=-a60d3e6346f26eda --out-dir /home/admin/rust/electrs/target/release/deps -L dependency=/home/admin/rust/electrs/target/release/deps --cap-lints allow` (signal: 11, SIGSEGV: invalid memory reference)

System
OS name and version: (If Linux, the distribution name and version)
uname -a
Linux raspibolt 6.1.0-rpi7-rpi-v8 #1 SMP PREEMPT Debian 1:6.1.63-1+rpt1 (2023-11-24) aarch64 GNU/Linux
lsb_release -a
No LSB modules are available. Distributor ID: Debian Description: Debian GNU/Linux 12 (bookworm) Release: 12 Codename: bookworm
rustc version: (run rustc --version)
rustc 1.63.0
cargo version: (run cargo --version; not guaranteed to be same as rustc version!)
cargo 1.65.0

Compilation
Linking: static
Cross compilation: no
Target architecture: (uname -m on Linux if not cross-compiling)
aarch64

Additional context
I'm trying to install electrs on Raspberry Pi 3b with Raspberry Pi OS Lite 64 booting from USB 2TB HDD with 4GB swap file.
I've installed cargo using apt install cargo, I have Bitcoin Core version v26.0.0 installed and running and I've installed the latest Electrum Wallet.
I've executed the following commands:

  1. sudo apt update
  2. sudo apt install clang cmake build-essential # for building 'rust-rocksdb'
  3. git clone https://github.com/romanz/electrs
  4. cd electrs
  5. cargo build --locked --release
@OvoNemaSmisla OvoNemaSmisla added bug Something isn't working build labels Jan 11, 2024
@OvoNemaSmisla
Copy link
Author

Maybe another way to go about this is to cross compile on my Odroid N2 running with Ubuntu 18.04:
uname -a
Linux odroid 4.9.333-79 #1 SMP PREEMPT Tue Dec 6 22:41:40 -03 2022 aarch64 aarch64 aarch64 GNU/Linux
lsb_release -a
No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 18.04.6 LTS Release: 18.04 Codename: bionic
Or maybe it doesn't require cross compile at all and I can just copy the existing, compiled electrs version from Odroid?

@romanz
Copy link
Owner

romanz commented Jan 12, 2024

Many thanks for reporting this issue!

CC: @Kixunil

@romanz
Copy link
Owner

romanz commented Jan 13, 2024

Seems like a segfault in rustc?

rustc --crate-name build_script_build /home/admin/.cargo/registry/src/github.com-1ecc6299db9ec823/serde-1.0.171/build.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --crate-type bin --emit=dep-info,link -C embed-bitcode=no -C debug-assertions=off --cfg 'feature="alloc"' --cfg 'feature="default"' --cfg 'feature="derive"' --cfg 'feature="serde_derive"' --cfg 'feature="std"' -C metadata=78795a5c89f57fcd -C extra-filename=-78795a5c89f57fcd --out-dir /home/admin/rust/electrs/target/release/build/serde-78795a5c89f57fcd -L dependency=/home/admin/rust/electrs/target/release/deps --cap-lints allow (signal: 11, SIGSEGV: invalid memory reference`

rustc --crate-name build_script_build --edition=2021 /home/admin/.cargo/registry/src/github.com-1ecc6299db9ec823/proc-macro2-1.0.71/build.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --crate-type bin --emit=dep-info,link -C embed-bitcode=no -C debug-assertions=off --cfg 'feature="default"' --cfg 'feature="proc-macro"' -C metadata=beb95e6656d1e006 -C extra-filename=-beb95e6656d1e006 --out-dir /home/admin/rust/electrs/target/release/build/proc-macro2-beb95e6656d1e006 -L dependency=/home/admin/rust/electrs/target/release/deps --cap-lints allow (signal: 11, SIGSEGV: invalid memory reference`

rustc --crate-name build_script_build /home/admin/.cargo/registry/src/github.com-1ecc6299db9ec823/libc-0.2.151/build.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --crate-type bin --emit=dep-info,link -C embed-bitcode=no -C debug-assertions=off --cfg 'feature="default"' --cfg 'feature="std"' -C metadata=fafbb2462b388e90 -C extra-filename=-fafbb2462b388e90 --out-dir /home/admin/rust/electrs/target/release/build/libc-fafbb2462b388e90 -L dependency=/home/admin/rust/electrs/target/release/deps --cap-lints allow (signal: 11, SIGSEGV: invalid memory reference`

rustc --crate-name autocfg /home/admin/.cargo/registry/src/github.com-1ecc6299db9ec823/autocfg-1.1.0/src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --crate-type lib --emit=dep-info,metadata,link -C embed-bitcode=no -C debug-assertions=off -C metadata=a60d3e6346f26eda -C extra-filename=-a60d3e6346f26eda --out-dir /home/admin/rust/electrs/target/release/deps -L dependency=/home/admin/rust/electrs/target/release/deps --cap-lints allow (signal: 11, SIGSEGV: invalid memory reference`

@romanz
Copy link
Owner

romanz commented Jan 13, 2024

@OvoNemaSmisla Could you please try to install Rust via https://rustup.rs/ (instead of apt)?

@romanz
Copy link
Owner

romanz commented Jan 13, 2024

@OvoNemaSmisla Also, could you please try to build electrs in debug mode (to see if it also fails) using:

$ cargo build --locked

@OvoNemaSmisla
Copy link
Author

@OvoNemaSmisla Also, could you please try to build electrs in debug mode (to see if it also fails) using:

$ cargo build --locked

Here is the log:

   Compiling proc-macro2 v1.0.71
   Compiling unicode-ident v1.0.12
   Compiling cfg-if v1.0.0
   Compiling serde v1.0.171
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x6c4430)[0x7fad4c4430]
linux-vdso.so.1(__kernel_rt_sigreturn+0x0)[0x7fb05367bc]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(+0x132a9f0)[0x7fa7b3a9f0]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm11raw_ostream5writeEPKcm+0x164)[0x7fa768b49c]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm9MCContext16createTempSymbolERKNS_5TwineEb+0xb4)[0x7fa8a41048]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm9MCContext16createTempSymbolEv+0x3c)[0x7fa8a413f0]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm16MCDwarfLineEntry4makeEPNS_10MCStreamerEPNS_9MCSectionE+0x3c)[0x7fa8a49ec0]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm16MCObjectStreamer19emitInstructionImplERKNS_6MCInstERKNS_15MCSubtargetInfoE+0x94)[0x7fa8a66934]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm16MCObjectStreamer15emitInstructionERKNS_6MCInstERKNS_15MCSubtargetInfoE+0x140)[0x7fa8a66858]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(+0x28adf50)[0x7fa90bdf50]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(+0x2767f08)[0x7fa8f77f08]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm10AsmPrinter16emitFunctionBodyEv+0xa10)[0x7fa7e4ef30]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(+0x2764ba4)[0x7fa8f74ba4]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm19MachineFunctionPass13runOnFunctionERNS_8FunctionE+0x140)[0x7fa7a0122c]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm13FPPassManager13runOnFunctionERNS_8FunctionE+0x26c)[0x7fa77e4390]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm13FPPassManager11runOnModuleERNS_6ModuleE+0x3c)[0x7fa77eaf70]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm6legacy15PassManagerImpl3runERNS_6ModuleE+0x7b4)[0x7fa77e4d98]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x951d8c)[0x7fad751d8c]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x92c114)[0x7fad72c114]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x930d88)[0x7fad730d88]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x925db4)[0x7fad725db4]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x921230)[0x7fad721230]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x80c0c0)[0x7fad60c0c0]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x8f6608)[0x7fad6f6608]
/lib/aarch64-linux-gnu/libstd-4e83e61126e325db.so(rust_metadata_std_aeb45179e3b08762+0x9ffec)[0x7facceffec]
/lib/aarch64-linux-gnu/libc.so.6(+0x7ee18)[0x7facb1ee18]
/lib/aarch64-linux-gnu/libc.so.6(+0xe7e9c)[0x7facb87e9c]
error: could not compile `unicode-ident`                                                                                                                                                                                                                                                                                                                                                                                                                                                  Caused by:
  process didn't exit successfully: `rustc --crate-name unicode_ident --edition=2018 /home/admin/.cargo/registry/src/github.com-1ecc6299db9ec823/unicode-ident-1.0.12/src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifact
s,future-incompat --crate-type lib --emit=dep-info,metadata,link -C embed-bitcode=no -C debuginfo=2 -C metadata=6a9fcc9043637f9f -C extra-filename=-6a9fcc9043637f9f --out-dir /home/admin/rust/electrs/target/debug/deps -L dependency=/home
/admin/rust/electrs/target/debug/deps --cap-lints allow` (signal: 11, SIGSEGV: invalid memory reference)
warning: build failed, waiting for other jobs to finish...
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x6c4430)[0x7f8baf4430]
linux-vdso.so.1(__kernel_rt_sigreturn+0x0)[0x7f8eb687bc]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(+0x132a9f0)[0x7f8616a9f0]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm11raw_ostream5writeEPKcm+0x164)[0x7f85cbb49c]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm9MCContext16createTempSymbolERKNS_5TwineEb+0xb4)[0x7f87071048]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm10DwarfDebug11beginModuleEPNS_6ModuleE+0x494)[0x7f864adc48]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm10AsmPrinter16doInitializationERNS_6ModuleE+0xaf4)[0x7f8647b53c]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm13FPPassManager16doInitializationERNS_6ModuleE+0x40)[0x7f85e1afec]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm6legacy15PassManagerImpl3runERNS_6ModuleE+0x26c)[0x7f85e14850]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x951d8c)[0x7f8bd81d8c]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x92c114)[0x7f8bd5c114]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x930d88)[0x7f8bd60d88]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x925db4)[0x7f8bd55db4]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x921230)[0x7f8bd51230]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x80c0c0)[0x7f8bc3c0c0]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x8f6608)[0x7f8bd26608]
/lib/aarch64-linux-gnu/libstd-4e83e61126e325db.so(rust_metadata_std_aeb45179e3b08762+0x9ffec)[0x7f8b31ffec]
/lib/aarch64-linux-gnu/libc.so.6(+0x7ee18)[0x7f8b14ee18]
/lib/aarch64-linux-gnu/libc.so.6(+0xe7e9c)[0x7f8b1b7e9c]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x6c4430)[0x7f7e1b4430]
linux-vdso.so.1(__kernel_rt_sigreturn+0x0)[0x7f8121b7bc]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x6c4430)[0x7f7e1b4430]                                                                                                                                                 [161/221]
linux-vdso.so.1(__kernel_rt_sigreturn+0x0)[0x7f8121b7bc]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(+0x132a9f0)[0x7f7882a9f0]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm11raw_ostream5writeEPKcm+0x164)[0x7f7837b49c]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm9MCContext16createTempSymbolERKNS_5TwineEb+0xb4)[0x7f79731048]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm10DwarfDebug11beginModuleEPNS_6ModuleE+0x494)[0x7f78b6dc48]
error: could not compile `serde`

Caused by:
  process didn't exit successfully: `rustc --crate-name build_script_build /home/admin/.cargo/registry/src/github.com-1ecc6299db9ec823/serde-1.0.171/build.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat -
-crate-type bin --emit=dep-info,link -C embed-bitcode=no -C debuginfo=2 --cfg 'feature="alloc"' --cfg 'feature="default"' --cfg 'feature="derive"' --cfg 'feature="serde_derive"' --cfg 'feature="std"' -C metadata=0066472f0314da4a -C extra
-filename=-0066472f0314da4a --out-dir /home/admin/rust/electrs/target/debug/build/serde-0066472f0314da4a -L dependency=/home/admin/rust/electrs/target/debug/deps --cap-lints allow` (signal: 11, SIGSEGV: invalid memory reference)
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm10AsmPrinter16doInitializationERNS_6ModuleE+0xaf4)[0x7f78b3b53c]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm13FPPassManager16doInitializationERNS_6ModuleE+0x40)[0x7f784dafec]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm6legacy15PassManagerImpl3runERNS_6ModuleE+0x26c)[0x7f784d4850]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x951d8c)[0x7f7e441d8c]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x92c114)[0x7f7e41c114]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x930d88)[0x7f7e420d88]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x925db4)[0x7f7e415db4]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x921230)[0x7f7e411230]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x80c0c0)[0x7f7e2fc0c0]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x8f6608)[0x7f7e3e6608]
/lib/aarch64-linux-gnu/libstd-4e83e61126e325db.so(rust_metadata_std_aeb45179e3b08762+0x9ffec)[0x7f7d9dffec]
/lib/aarch64-linux-gnu/libc.so.6(+0x7ee18)[0x7f7d80ee18]
/lib/aarch64-linux-gnu/libc.so.6(+0xe7e9c)[0x7f7d877e9c]
error: could not compile `proc-macro2`

Caused by:
  process didn't exit successfully: `rustc --crate-name build_script_build --edition=2021 /home/admin/.cargo/registry/src/github.com-1ecc6299db9ec823/proc-macro2-1.0.71/build.rs --error-format=json --json=diagnostic-rendered-ansi,artifac
ts,future-incompat --crate-type bin --emit=dep-info,link -C embed-bitcode=no -C debuginfo=2 --cfg 'feature="default"' --cfg 'feature="proc-macro"' -C metadata=c1ecfba7dfb1a977 -C extra-filename=-c1ecfba7dfb1a977 --out-dir /home/admin/rus
t/electrs/target/debug/build/proc-macro2-c1ecfba7dfb1a977 -L dependency=/home/admin/rust/electrs/target/debug/deps --cap-lints allow` (signal: 11, SIGSEGV: invalid memory reference)
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x6c4430)[0x7f98494430]
linux-vdso.so.1(__kernel_rt_sigreturn+0x0)[0x7f9b4fa7bc]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(+0x132a9f0)[0x7f92b0a9f0]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm11raw_ostream5writeEPKcm+0x164)[0x7f9265b49c]                                                                                                                                                 /lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm9MCContext16createTempSymbolERKNS_5TwineEb+0xb4)[0x7f93a11048]                                                                                                                                /lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm10DwarfDebug11beginModuleEPNS_6ModuleE+0x494)[0x7f92e4dc48]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm10AsmPrinter16doInitializationERNS_6ModuleE+0xaf4)[0x7f92e1b53c]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm13FPPassManager16doInitializationERNS_6ModuleE+0x40)[0x7f927bafec]
/lib/aarch64-linux-gnu/libLLVM-14.so.1(_ZN4llvm6legacy15PassManagerImpl3runERNS_6ModuleE+0x26c)[0x7f927b4850]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x951d8c)[0x7f98721d8c]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x92c114)[0x7f986fc114]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x930d88)[0x7f98700d88]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x925db4)[0x7f986f5db4]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x921230)[0x7f986f1230]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x80c0c0)[0x7f985dc0c0]
/lib/aarch64-linux-gnu/librustc_driver-fe2d3f0c4114cdf4.so(+0x8f6608)[0x7f986c6608]
/lib/aarch64-linux-gnu/libstd-4e83e61126e325db.so(rust_metadata_std_aeb45179e3b08762+0x9ffec)[0x7f97cbffec]
/lib/aarch64-linux-gnu/libc.so.6(+0x7ee18)[0x7f97aeee18]
/lib/aarch64-linux-gnu/libc.so.6(+0xe7e9c)[0x7f97b57e9c]
error: could not compile `libc`

Caused by:
  process didn't exit successfully: `rustc --crate-name build_script_build /home/admin/.cargo/registry/src/github.com-1ecc6299db9ec823/libc-0.2.151/build.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --
crate-type bin --emit=dep-info,link -C embed-bitcode=no -C debuginfo=2 --cfg 'feature="default"' --cfg 'feature="std"' -C metadata=65744a22485bbeb5 -C extra-filename=-65744a22485bbeb5 --out-dir /home/admin/rust/electrs/target/debug/build
/libc-65744a22485bbeb5 -L dependency=/home/admin/rust/electrs/target/debug/deps --cap-lints allow` (signal: 11, SIGSEGV: invalid memory reference)```

@OvoNemaSmisla
Copy link
Author

OvoNemaSmisla commented Jan 13, 2024

@OvoNemaSmisla Could you please try to install Rust via https://rustup.rs/ (instead of apt)?

Should I first uninstall cargo with sudo apt purge cargo or just install rustup with curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh?

@romanz
Copy link
Owner

romanz commented Jan 13, 2024

Should I first uninstall cargo with sudo apt purge cargo or just install rustup with curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh?

Yep, let's try to uninstall first, and then install Rust from http://rustup.rs.

@OvoNemaSmisla
Copy link
Author

OvoNemaSmisla commented Jan 14, 2024

Success!
Finished release [optimized] target(s) in 602m 50s
Thank you for your help!

Maybe another way to go about this is to cross compile on my Odroid N2 running with Ubuntu 18.04:
uname -a
Linux odroid 4.9.333-79 #1 SMP PREEMPT Tue Dec 6 22:41:40 -03 2022 aarch64 aarch64 aarch64 GNU/Linux
lsb_release -a
No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 18.04.6 LTS Release: 18.04 Codename: bionic
Or maybe it doesn't require cross compile at all and I can just copy the existing, compiled electrs version from Odroid?

Can you tell me if this option is valid as it takes way less time to compile on Odroin N2?

@romanz
Copy link
Owner

romanz commented Jan 14, 2024

Success!
Finished release [optimized] target(s) in 602m 50s
Thank you for your help!

Cool, happy to help :)

@romanz
Copy link
Owner

romanz commented Jan 14, 2024

Can you tell me if this option is valid as it takes way less time to compile on Odroin N2?

It should be possible if both platforms use the same CPU architecture, right @Kixunil?

@OvoNemaSmisla did you follow https://github.com/romanz/electrs/blob/master/doc/install.md for cross-compilation?

@OvoNemaSmisla
Copy link
Author

I did, but since both Raspberry Pi 3b and Odroid N2 are aarch64 I thought that you actually don't need to cross compile. You can just copy the Odroid build to Raspberry Pi.

The difference is in the OS - rpi runs on Raspbian OS Lite 64 bit (which is Debian 12 afaik) and Odroid runs on Ubuntu 18.04 Bionic.

@romanz
Copy link
Owner

romanz commented Jan 15, 2024

Got it - it indeed may fail due to some missing dependencies...
Could you try and see if it works? :)

@Kixunil
Copy link
Contributor

Kixunil commented Jan 15, 2024

Uh, never seen an error like this. Probably should be reported to the Debian bug tracker. Yes, statically compiling on Odroid should be valid as long as it has compatible libc.

@OvoNemaSmisla
Copy link
Author

Got it - it indeed may fail due to some missing dependencies... Could you try and see if it works? :)

Seems to be working with static compile from Odroid :)

I am getting these errors and warnings no matter what build I use:

Jan 17 22:25:02 raspibolt electrs[1597]: [2024-01-17T21:25:02.347Z WARN  electrs::mempool] mempool sync failed: failed to get mempool txids
Jan 17 22:25:30 raspibolt electrs[1597]: [2024-01-17T21:25:30.561Z WARN  electrs::mempool] mempool sync failed: batch request failed
Jan 17 22:25:57 raspibolt electrs[1597]: [2024-01-17T21:25:57.901Z WARN  electrs::mempool] mempool sync failed: batch request failed
Jan 17 22:32:41 raspibolt electrs[1597]: [2024-01-17T21:32:41.670Z INFO  electrs::index] indexing 1 blocks: [826179..826179]
Jan 17 22:33:00 raspibolt electrs[1597]: [2024-01-17T21:33:00.719Z INFO  electrs::chain] chain updated: tip=00000000000000000002dd0f418bd304d9d211434f724c5bd0f09dc12c5610a2, height=826179
Jan 17 22:33:00 raspibolt electrs[1597]: [2024-01-17T21:33:00.720Z ERROR electrs::server] 4: disconnecting due to failed to send response: "{\"id\":3,\"jsonrpc\":\"2.0\",\"result\":\"Welcome to electrs 0.10.2 (Electrum Rust Server)!\"}\n"
Jan 17 22:33:00 raspibolt electrs[1597]: [2024-01-17T21:33:00.720Z WARN  electrs::server] 4: failed to shutdown TCP connection Transport endpoint is not connected (os error 107)
Jan 17 22:34:58 raspibolt electrs[1597]: [2024-01-17T21:34:58.928Z WARN  electrs::mempool] mempool sync failed: batch request failed
Jan 17 22:38:20 raspibolt electrs[1597]: [2024-01-17T21:38:20.094Z INFO  electrs::index] indexing 1 blocks: [826180..826180]
Jan 17 22:38:39 raspibolt electrs[1597]: [2024-01-17T21:38:39.251Z INFO  electrs::chain] chain updated: tip=00000000000000000001f8bf4036019ea977de499a21f086464a7021b4a91c32, height=826180
Jan 17 22:44:40 raspibolt electrs[1597]: [2024-01-17T21:44:40.498Z WARN  electrs::mempool] mempool sync failed: batch request failed
Jan 17 22:45:08 raspibolt electrs[1597]: [2024-01-17T21:45:08.363Z WARN  electrs::mempool] mempool sync failed: failed to get mempool txids
Jan 17 22:45:35 raspibolt electrs[1597]: [2024-01-17T21:45:35.755Z WARN  electrs::mempool] mempool sync failed: failed to get mempool txids
Jan 17 22:47:50 raspibolt electrs[1597]: [2024-01-17T21:47:49.905Z WARN  electrs::mempool] mempool sync failed: batch request failed
Jan 17 22:48:51 raspibolt electrs[1597]: [2024-01-17T21:48:51.635Z WARN  electrs::mempool] mempool sync failed: batch request failed

@romanz
Copy link
Owner

romanz commented Jan 20, 2024

It's possible that those warnings are related to #985.

@romanz
Copy link
Owner

romanz commented Jan 27, 2024

@OvoNemaSmisla Please try #997 - it should help with mempool sync issues.

@OvoNemaSmisla
Copy link
Author

Just to confirm, I should git checkout batch-refactor branch and build it?

@OvoNemaSmisla
Copy link
Author

I've built the branch and this is what's happening now:

Starting electrs 0.10.2 on aarch64 linux with Config { network: Bitcoin, db_path: "/***/electrs/db/bitcoin", db_log_dir: None, daemon_dir: "/data/bitcoin/", daemon_auth: CookieFile("/***/bitcoin/.cookie"), daemon_rpc_addr: 127.0.0.1:8332, daemon_p2p_addr: 127.0.0.1:8333, electrum_rpc_addr: 127.0.0.1:50001, monitoring_addr: 127.0.0.1:4224, wait_duration: 10s, jsonrpc_timeout: 15s, index_batch_size: 10, index_lookup_limit: None, reindex_last_blocks: 0, auto_reindex: true, ignore_mempool: false, sync_once: false, skip_block_download_wait: false, disable_electrum_rpc: false, server_banner: "Welcome to electrs 0.10.2 (Electrum Rust Server)!", signet_magic: f9beb4d9, args: [] }
[2024-01-29T23:12:15.419Z DEBUG tiny_http] Server listening on 127.0.0.1:4224
[2024-01-29T23:12:15.420Z INFO  electrs::metrics::metrics_impl] serving Prometheus metrics on 127.0.0.1:4224
[2024-01-29T23:12:15.420Z INFO  electrs::server] serving Electrum RPC on 127.0.0.1:50001
[2024-01-29T23:12:15.423Z DEBUG tiny_http] Running accept thread
[2024-01-29T23:12:29.250Z INFO  electrs::db] "/data/electrs/db/bitcoin": 187 SST files, 45.491338687 GB, 5.685728016 Grows
[2024-01-29T23:12:29.254Z DEBUG electrs::db] DB Some(Config { compacted: true, format: 0 })
[2024-01-29T23:12:29.899Z DEBUG electrs::db] auto-compactions enabled
[2024-01-29T23:13:02.016Z INFO  electrs::chain] loading 827511 headers, tip=000000000000000000036993a90b102d15834b236e28ad8a3f45cf6ca39c2961
[2024-01-29T23:13:34.598Z INFO  electrs::chain] chain updated: tip=000000000000000000036993a90b102d15834b236e28ad8a3f45cf6ca39c2961, height=827511
[2024-01-29T23:13:34.799Z DEBUG bitcoincore_rpc] JSON-RPC request: getblockchaininfo []
[2024-01-29T23:13:49.812Z DEBUG bitcoincore_rpc] JSON-RPC failed parsing reply of getblockchaininfo: JsonRpc(Transport(SocketError(Os { code: 11, kind: WouldBlock, message: "Resource temporarily unavailable" })))
[2024-01-29T23:13:49.813Z INFO  electrs::db] closing DB at /data/electrs/db/bitcoin
Error: electrs failed

Caused by:
    0: bitcoind RPC polling failed
    1: daemon not available
    2: JSON-RPC error: transport error: Couldn't connect to host: Resource temporarily unavailable (os error 11)

Here is my config:

network = "bitcoin"
daemon_dir="/***/bitcoin/"
daemon_rpc_addr = "127.0.0.1:8332"
daemon_p2p_addr = "127.0.0.1:8333"

electrum_rpc_addr = "127.0.0.1:50001"
db_dir = "/***/electrs/db"

log_filters = "DEBUG"
timestamp = true

@Kixunil
Copy link
Contributor

Kixunil commented Feb 20, 2024

Resource temporarily unavailable

Sounds like some kind of OS error.

@romanz
Copy link
Owner

romanz commented Mar 8, 2024

Success! Finished release [optimized] target(s) in 602m 50s Thank you for your help!

Closing :)

@romanz romanz closed this as completed Mar 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working build
Projects
None yet
Development

No branches or pull requests

3 participants