Closed gaia closed 6 years ago
Hi,
Can confirm that you are doing this with root access?
I am root, not even sudo.
I am also facing this issue even when I run the daemon as root. I began to experience this issue after syncing with the blockchain did not complete properly due to poor network connectivity here.
Is there any fix for this please?
Having same issue here, running as root or as myself with sudo heightened run.
Freshly built Ubuntu Server w/ Freshly Compiled from Source directives in this project.
myuser@myServer:~/electroneum/src/daemon$ uname -a Linux myServer 4.4.0-87-generic #110-Ubuntu SMP Tue Jul 18 12:55:35 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux myuser@myServer:~/electroneum/src/daemon$ electroneumd --os-version OS: Linux #110-Ubuntu SMP Tue Jul 18 12:55:35 UTC 2017 4.4.0-87-generic
Admittedly my first attempt at mining, but looking at the output:
root@MyServer:~# electroneumd --start-mining $MyETNWallet --log-file $HOME/electroneum/logs/electroneum.mining.log 2018-01-07 06:54:38.824 7fe623874740 INFO global src/daemon/main.cpp:279 Electroneum 'Helium Hydra' (v0.11.0.0-2769728) 2018-01-07 06:54:38.825 7fe623874740 INFO global src/daemon/protocol.h:55 Initializing cryptonote protocol... 2018-01-07 06:54:38.825 7fe623874740 INFO global src/daemon/protocol.h:60 Cryptonote protocol initialized OK 2018-01-07 06:54:38.825 7fe623874740 INFO global src/daemon/p2p.h:63 Initializing p2p server... 2018-01-07 06:54:39.170 7fe623874740 INFO global src/daemon/core.h:89 Deinitializing core... 2018-01-07 06:54:39.172 7fe623874740 ERROR daemon src/daemon/core.h:94 Failed to deinitialize core... 2018-01-07 06:54:39.172 7fe623874740 INFO global src/daemon/protocol.h:77 Stopping cryptonote protocol... 2018-01-07 06:54:39.172 7fe623874740 INFO global src/daemon/protocol.h:81 Cryptonote protocol stopped successfully 2018-01-07 06:54:39.172 7fe623874740 ERROR daemon src/daemon/main.cpp:287 Exception in main! Failed to initialize p2p server.
I went into the files of issue: $HOME/electroneum/src/daemon/core.h (see Line 94) 82 cryptonote::core & get() 83 { 84 return m_core; 85 } 86 87 ~t_core() 88 { 89 MGINFO("Deinitializing core..."); 90 try { 91 m_core.deinit(); 92 m_core.set_cryptonote_protocol(nullptr); 93 } catch (...) { 94 MERROR("Failed to deinitialize core..."); 95 }
And from $HOME/electroneum/src/daemon/main.cpp (Line 287)
279 MGINFO("Electroneum '" << MONERO_RELEASE_NAME << "' (v" << MONERO_VERSION_FULL << ")"); 280 281 MINFO("Moving from main() into the daemonize now."); 282 283 return daemonizer::daemonize(argc, argv, daemonize::t_executor{}, vm); 284 } 285 catch (std::exception const & ex) 286 { 287 LOG_ERROR("Exception in main! " << ex.what()); 288 }
So quick questions: 1) Are my arguments enough to start the miner? If not, what's missing/required? 2) Do I need to be in a mining pool for this to work with P2P setup etc or are there other IPs/Ports I should use/consider? If I need to be in a pool, anyone know of one I can use that doesn't require me to use thier bundled version of ETN Miner? (had issues installing the ones from NanoPool and electromine.fr.
Thanks in advance.
Hi gaia, Kill the PiD proceess /snap/electroneum/... and screen -S daemon and after ./electroneumd.
Here's a Docker for replicating the issue:
FROM ubuntu:latest as builder
RUN apt-get update \
&& apt-get upgrade -y \
&& apt-get install -y --no-install-recommends \
build-essential \
ca-certificates \
cmake \
doxygen \
git \
graphviz \
libboost-all-dev \
libexpat1-dev \
libgtest-dev \
libldns-dev \
liblzma-dev \
libminiupnpc-dev \
libssl-dev \
libunbound-dev \
libunwind8-dev \
pkg-config \
&& git clone https://github.com/electroneum/electroneum.git /root/electroneum \
&& cd /root/electroneum \
&& make release-static
FROM ubuntu:latest
WORKDIR /opt/electroneum
RUN apt-get update \
&& apt-get upgrade -y \
&& apt-get install -y --no-install-recommends \
ca-certificates \
curl \
gnupg \
libboost-all-dev \
software-properties-common \
&& curl -sL https://deb.nodesource.com/setup_9.x | bash \
&& apt-get install -y nodejs \
&& npm install -g pm2 \
&& apt-get autoclean \
&& apt-get autoremove -y \
&& rm -rf /var/lib/apt/lists/*
COPY --from=builder /root/electroneum/build/release/bin/* /opt/electroneum/
EXPOSE 26967 26968
CMD ["pm2-docker", "process.json"]
anyone solved this ? have same issue
user shell is /bin/false. homedir is /mnt/electroneum