ethereum-mining / ethminer

Ethereum miner with OpenCL, CUDA and stratum support
GNU General Public License v3.0
5.96k stars 2.28k forks source link

Segfault on connection loss #1928

Open dg1yfe opened 4 years ago

dg1yfe commented 4 years ago

Describe the bug When ethminer loses the connection to the geth/stratum proxy it segfaults instead of retrying or using the secondary proxy. I encountered this bug with v0.18rc0 as well as the latest master. As a workaround I call ethminer in a loop, but it is still annoying due to the loss in DAG generation on startup.

To Reproduce

Steps to reproduce the behavior:

  1. ethminer -U -P http://$proxy1/$worker_name
  2. kill the proxy / make proxy unreachable
  3. Enjoy segfault (see log below)

Expected behavior Retry the connection / try secondary/tertiary connection.

Screenshots (Optional)

ethminer 0.19.0-alpha.0-1+commit.7015b1a8 Build: linux/release/gnu [...] X 11:20:38 ethminer Error connecting to 127.0.0.1:8080 : Connection refused X 11:20:38 ethminer No more IP addresses to try for host: 127.0.0.1 i 11:20:38 ethminer Disconnected from 127.0.0.1:8080 i 11:20:38 ethminer No connection. Suspend mining ... i 11:20:38 ethminer Selected pool 127.0.0.1:8080 X 11:20:38 ethminer Error connecting to 127.0.0.1:8080 : Connection refused X 11:20:38 ethminer No more IP addresses to try for host: 127.0.0.1 SIGSEGV encountered ... stack trace: backtrace() returned 14 addresses /usr/local/bin/ethminer() [0x423e59] /lib/x86_64-linux-gnu/libc.so.6(+0x354b0) [0x7f86536cf4b0] /usr/local/bin/ethminer() [0x4a5bd6] /usr/local/bin/ethminer() [0x4a6414] /usr/local/bin/ethminer() [0x4a8ff4] /usr/local/bin/ethminer() [0x4abc5a] /usr/local/bin/ethminer() [0x4abf48] /usr/local/bin/ethminer() [0x4ac1ed] /usr/local/bin/ethminer() [0x4ac4e5] /usr/local/bin/ethminer() [0x481fc7] /usr/local/bin/ethminer() [0x420cc2] /usr/local/bin/ethminer() [0x7dd260] /lib/x86_64-linux-gnu/libpthread.so.0(+0x76ba) [0x7f8653f8a6ba] /lib/x86_64-linux-gnu/libc.so.6(clone+0x6d) [0x7f86537a141d]

ethminer 0.18.0-rc.0-1+commit.17313073 Build: linux/release/gnu i 11:35:02 ethminer Configured pool 192.168.1.207:8080 i 11:35:02 ethminer Configured pool 127.0.0.1:8080 i 11:35:02 ethminer Selected pool 192.168.1.207:8080 X 11:35:03 ethminer Error connecting to 192.168.1.207:8080 : No route to host X 11:35:03 ethminer No more IP addresses to try for host: 192.168.1.207 SIGSEGV encountered ... stack trace: backtrace() returned 14 addresses /usr/local/bin/ethminer() [0x423e59] /lib/x86_64-linux-gnu/libc.so.6(+0x354b0) [0x7fb642f404b0] /usr/local/bin/ethminer() [0x4a5c46] /usr/local/bin/ethminer() [0x4a6484] /usr/local/bin/ethminer() [0x4a9064] /usr/local/bin/ethminer() [0x4abcca] /usr/local/bin/ethminer() [0x4abfb8] /usr/local/bin/ethminer() [0x4ac25d] /usr/local/bin/ethminer() [0x4ac555] /usr/local/bin/ethminer() [0x482037] /usr/local/bin/ethminer() [0x420cc2] /usr/local/bin/ethminer() [0x7dd260] /lib/x86_64-linux-gnu/libpthread.so.0(+0x76ba) [0x7fb6437fb6ba] /lib/x86_64-linux-gnu/libc.so.6(clone+0x6d) [0x7fb64301241d]

Environment (please complete the following information):

Additional context This issues already bugs me a really long time

orien3243 commented 3 years ago

Nothing on this? I am having a similar issue.