xmrig / xmrig-cuda

NVIDIA CUDA plugin for XMRig miner
GNU General Public License v3.0
368 stars 154 forks source link

CUDA Hashrate not being reported #33

Closed adamgall closed 4 years ago

adamgall commented 4 years ago

Old hardware and software:

Compiled libxmrig-cuda.so via

$ git clone https://github.com/xmrig/xmrig-cuda.git
$ cd xmrig-cuda
$ mkdir build
$ cd build
$ cmake .. -DCMAKE_C_COMPILER=gcc-5 -DCMAKE_CXX_COMPILER=g++-5`

Everything went well. Moved libxmrig-cuda.so to a different directory, then enabled cuda in my xmrig config and pointed to the loader.

Starting xmrig shows no errors.

$ xmrig -c .xmrig/config.json
 * ABOUT        XMRig/5.5.1 gcc/7.4.0
 * LIBS         libuv/1.18.0 OpenSSL/1.1.1 hwloc/1.11.9
 * HUGE PAGES   supported
 * 1GB PAGES    unavailable
 * CPU          Intel(R) Core(TM) i5-2400 CPU @ 3.10GHz (1) x64 AES
                L2:1.0 MB L3:6.0 MB 4C/4T NUMA:1
 * MEMORY       13.1/15.6 GB (84%)
 * DONATE       5%
 * ASSEMBLY     auto:intel
 * POOL #1      127.0.0.1:18081 coin monero
 * COMMANDS     hashrate, pause, resume
 * OPENCL       disabled
 * CUDA         8.0/9.1/2.1.0
 * NVML         9.390.129/390.129 press e for health report
 * CUDA GPU     #0 01:00.0 GeForce GT 430 1400/533 MHz smx:2 arch:21 mem:940/963 MB
[2020-02-04 05:49:04.411]  net  use daemon 127.0.0.1:18081  127.0.0.1
[2020-02-04 05:49:04.411]  net  new job from 127.0.0.1:18081 diff 157750235187 algo rx/0 height 2026019
[2020-02-04 05:49:04.426]  msr  msr kernel module is not available
[2020-02-04 05:49:04.426]  rx   init dataset algo rx/0 (4 threads) seed 7b8b843f368c19c6...
[2020-02-04 05:49:04.591]  rx   allocated 2336 MB (2080+256) huge pages 89% 1040/1168 +JIT (166 ms)
[2020-02-04 05:49:13.975]  rx   dataset ready (9383 ms)
[2020-02-04 05:49:13.975]  cpu  use profile  rx  (3 threads) scratchpad 2048 KB
[2020-02-04 05:49:14.015]  cpu  READY threads 3/3 (3) huge pages 100% 3/3 memory 6144 KB (41 ms)
[2020-02-04 05:49:14.035]  nv   use profile  rx  (1 thread) scratchpad 2048 KB
|  # | GPU |  BUS ID |    I |   T |   B | BF |  BS |  MEM | NAME
|  0 |   0 | 01:00.0 |  128 |  32 |   4 |  0 |   0 |  256 | GeForce GT 430
[2020-02-04 05:49:14.216]  nv   READY threads 1/1 (180 ms)

Typing h to pull up the hashing report shows the CPU hashing as expected, but gives n/a for my CUDA card.

|    CPU # | AFFINITY | 10s H/s | 60s H/s | 15m H/s |
|        0 |        0 |   384.0 |   402.9 |   403.9 |
|        1 |        1 |   277.6 |   303.4 |   325.8 |
|        2 |        2 |   390.3 |   409.3 |   406.4 |
|        - |        - |  1051.9 |  1115.7 |  1136.2 |
|   CUDA # | AFFINITY | 10s H/s | 60s H/s | 15m H/s |
|        0 |       -1 |     n/a |    10.1 |    10.0 | #0 01:00.0 GeForce GT 430
|        - |        - |     n/a |    10.1 |    10.0 |
[2020-02-04 06:10:18.906] speed 10s/60s/15m 1051.9 1125.7 1146.2 H/s max 1266.4 H/s

I've noticed that I start the miner, the card is reporting a temp of 62C, and 10 minutes later it's at 69C. That, coupled with no visible errors, makes me think that something is happening, but it's hard to tell because the hashrate is just n/a.

Any insight?

Spudz76 commented 4 years ago

This occurs on all old slow cards, increase bfactor and/or bsleep or reduce intensity (blocks*threads) until it has time to show you stats. Of course that reduces the hashrate basically only so you can see the hashrate... the 60s or 15m should eventually populate as they have for you. Your card is getting 10 hashes and probably burning as much or more power than the CPU is for its 1000 hashes.

RandomX also requires 3GB or more VRAM otherwise every dataset access has to come across the PCIe bus, and if you're on a X1 slot extension the xfer rate is even worse than X16.

I run an xmrig with no GPU support included on the CPU (for RandomX) and then run another xmrig with CPU disabled and the GPUs on whatever MoneroOcean supports that still works on GPU, like CN-Heavy types or GN-GPU. This is because the backends have to run the same algo and RandomX is basically useless on GPUs (by design).