fireice-uk / xmr-stak

Free Monero RandomX Miner and unified CryptoNight miner
GNU General Public License v3.0
4.05k stars 1.79k forks source link

Slow program termination NVIDIA GPU mode #358

Closed Angel996 closed 6 years ago

Angel996 commented 6 years ago

Hello.

Ubuntu 16.04 LTS.

I have noticed miner takes very long to terminate: be it CTRL-C in terminal, or killall command. Terminal appears frozen, not reacting up to 30 seconds. In a scenario where we do multi-algo mining, switching miners etc this poses a bit of a problem.

Problem is only Nvidia GPU related. If I run CPU only mining or AMD GPU mining, miner terminates fast, although also appears frozen for 1-2 secs.

thanks. ))

mecrip commented 6 years ago

In my case the entire rig freeze when I close xmr-stak, and I have to reset the machine

JerichoJones commented 6 years ago

Try the new release and let us know if it's resolved.

mecrip commented 6 years ago

i've trouble building it on ubuntu 17.4 with cuda8. VArious issues with both Gcc 5 6 or 7.. /home/mirko/miner/xmr-stak/xmr-stak/xmrstak/version.hpp:13:33: error: 'to_strin' is not a member of 'std'

still have to find a solution..

Angel996 commented 6 years ago

JerichoJones, just tried the new release, and couldn't get it working at all. Also, there is a weird thing going on with pool logon, miner only logs in after several attempts: I specifically rechecked: older version does not have this problem.

[2017-12-10 00:46:59] : Start mining: MONERO
[2017-12-10 00:47:00] : Starting NVIDIA GPU thread 0, no affinity.
[2017-12-10 00:47:00] : Starting NVIDIA GPU thread 1, no affinity.
[2017-12-10 00:47:00] : Starting NVIDIA GPU thread 2, no affinity.
[2017-12-10 00:47:00] : Starting NVIDIA GPU thread 3, no affinity.
[2017-12-10 00:47:00] : Starting 1x thread, affinity: 0.
[2017-12-10 00:47:00] : hwloc: memory pinned
[2017-12-10 00:47:00] : Fast-connecting to etn-eu2.nanopool.org:13433 pool ...
[2017-12-10 00:47:00] : Fast-connecting to stratum+ssl://etn-eu2.nanopool.org:13433 pool ...
[2017-12-10 00:47:00] : Pool stratum+ssl://etn-eu2.nanopool.org:13433 connected. Logging in...
[2017-12-10 00:47:00] : SOCKET ERROR - [stratum+ssl://etn-eu2.nanopool.org:13433] RECEIVE error: socket closed
[2017-12-10 00:47:00] : TLS fingerprint [etn-eu2.nanopool.org:13433] SHA256:w4iG797lQuvZmAG3XHXTSY2Xl4u83sB8cnHLGXKeAU8=
[2017-12-10 00:47:00] : Pool etn-eu2.nanopool.org:13433 connected. Logging in...
[2017-12-10 00:47:00] : Difficulty changed. Now: 120001.
[2017-12-10 00:47:00] : Pool logged in.
[CUDA] Error gpu 0: </home/user/xmr-stak/xmrstak/backend/nvidia/nvcc_code/cuda_extra.cu>:246
terminate called after throwing an instance of 'std::runtime_error'
  what():  [CUDA] Error: invalid configuration argument
./exec_miner.sh: line 173: 11796 Aborted                 (core dumped) $cmd

Here is the log from the older version:


> 
> [2017-12-10 00:53:14] : Start mining: MONERO
> [2017-12-10 00:53:14] : Starting NVIDIA GPU thread 0, no affinity.
> [2017-12-10 00:53:14] : Starting NVIDIA GPU thread 1, no affinity.
> [2017-12-10 00:53:14] : Starting NVIDIA GPU thread 2, no affinity.
> [2017-12-10 00:53:14] : Starting NVIDIA GPU thread 3, no affinity.
> [2017-12-10 00:53:14] : Starting single thread, affinity: 0.
> [2017-12-10 00:53:14] : hwloc: memory pinned
> [2017-12-10 00:53:14] : Fast-connecting to etn-eu2.nanopool.org:13433 pool ...
> [2017-12-10 00:53:14] : TLS fingerprint [etn-eu2.nanopool.org:13433] SHA256:w4iG797lQuvZmAG3XHXTSY2Xl4u83sB8cnHLGXKeAU8=
> [2017-12-10 00:53:14] : Pool etn-eu2.nanopool.org:13433 connected. Logging in...
> [2017-12-10 00:53:14] : Difficulty changed. Now: 120001.
> [2017-12-10 00:53:14] : Pool logged in.
> [2017-12-10 00:53:30] : Difficulty changed. Now: 120001
> [2017-12-10 00:53:30] : New block detected.
> 
Angel996 commented 6 years ago

Little update. Deleted the old nvidia.txt and cpu.txt files. Now it runs for some time, but terminates again with this error:

[CUDA] Error gpu 0: </home/user/xmr-stak/xmrstak/backend/nvidia/nvcc_code/cuda_extra.cu>:266
terminate called after throwing an instance of 'std::runtime_error'
  what():  [CUDA] Error: the launch timed out and was terminated
Aborted (core dumped)
Angel996 commented 6 years ago

Deleted old config.txt file and let miner recreate it. Now, it's running.

Seriously, guys, you are making it SO HARD with all those config files... I already opened another issue concerning running the miner w/o the config file. They add so much confusion. No other miner requires having a config file. However, xmr-stak won't run w/o it, and would instantly crash if config file is not the right version/format.

psychocrypt commented 6 years ago

reduce the thraeds in nvidia.txt

fireice-uk commented 6 years ago

@Angel996 that's why it will create one for users that find them confusing.

Angel996 commented 6 years ago

I don't find them confusing, they add much confusion to usability of the miner. If every new miner release requires all new config files, maybe it would be a good idea to re-create them or warn user. Instead of terminating with segmentation fault messages.

My idea is, user should be able to run the miner with command line parameters ONLY. Let the miner create any files it wants. At the moment, it is not the case. There is no way to specify TLS handshake on the command line. There is no way to specify coin (Monero/Aeon).