MoneroOcean / xmrig

Monero (rx/0, rx/wow, rx/loki, defyx, rx/arq, rx/sfx, rx/keva, cn/0, cn/1, cn/2, cn/r, cn/fast, cn/half, cn/xao, cn/rto, cn/rwz, cn/zls, cn/double, cn/gpu, cn-lite/0, cn-lite/1, cn-heavy/0, cn-heavy/tube, cn-heavy/xhv, cn-pico, cn-pico/tlo, argon2/chukwa, argon2/wrkz, astrobwt) CPU/GPU miner
https://moneroocean.stream
GNU General Public License v3.0
272 stars 84 forks source link

Failed to allocate RandomX dataset using 1GB pages #113

Open dominikj111 opened 1 year ago

dominikj111 commented 1 year ago

I have previously running xmrig/xmrig on my Ubuntu 20.04 fine, so I suppose I have set the huge pages correctly. I switched to MoneroOcean with this config (upgraded to Ubuntu 22.04 too):

{
  "autosave": false,
  "randomx": {
    "1gb-pages": true
  },
  "cpu": {
    "memory-pool": true,
    "yield": true
  },
  "pools": [
    {
      "url": "gulf.moneroocean.stream:10128",
      "user": "wallet",
      "rig-id": "camera-server",
      "keepalive": true,
      "enabled": true
    }
  ]
}

And even I see in the xmrig output HUGE PAGES: supported as well as the 1GB PAGES I'm getting this error "Failed to allocate RandomX dataset using 1GB pages".

My memory is 17.4/31.4 GB and I'm running only cpu mining.

The log for randomx show "#0 allocated 2080 MB huge pages 100%" and just twice on the start that issue I'm talking about.

This a part of the log I see after:

randomx  #0 allocated  256 MB huge pages   0% +JIT (1 ms)
randomx  -- allocated 4416 MB huge pages  94% 2080/2208 (970 ms)
randomx  #0 dataset ready (4128 ms)
randomx  #1 dataset ready (882 ms)
cpu      use profile  rx  (12 threads) scratchpad 2048 KB
benchmk   Algo rx/0 Starting test 
cpu      READY threads 12/12 (12) huge pages 100% 12/12 memory 24576 KB (15 ms)
benchmk   Algo rx/0 hashrate: 2258.674133 
benchmk   Algo rx/graft Preparation 
cpu      stopped (5 ms)
randomx  init datasets algo rx/graft (24 threads) seed 0000000000000000...
randomx  #0 dataset ready (2939 ms)
randomx  #1 dataset ready (808 ms)
cpu      use profile  panthera  (12 threads) scratchpad 256 KB
benchmk   Algo panthera Starting test 
cpu      READY threads 12/12 (12) huge pages 100% 12/12 memory 3072 KB (19 ms)
benchmk   Algo panthera hashrate: 2962.803720 
benchmk   ALGO PERFORMANCE CALIBRATION COMPLETE 
net      use pool gulf.moneroocean.stream:10128  199.247.0.216
net      new job from gulf.moneroocean.stream:10128 diff 128001 algo rx/0 height 2717996 (4 tx)
cpu      stopped (21 ms)
randomx  init datasets algo rx/0 (24 threads) seed 8ec7aa5c3230468a...
randomx  #0 dataset ready (4448 ms)

Maybe it is just initial issue what is not a case later?

Spudz76 commented 1 year ago

Add kernel options hugepagesz=1GB hugepages=3 to /etc/default/grub

sudo update-grub

reboot

dominikj111 commented 1 year ago

This is not the way to fix this unfortunately. I wrote above that I had working xmrig/xmrig on this system and I had change the kernel options.

realsetvin commented 2 months ago

This is not the way to fix this unfortunately. I wrote above that I had working xmrig/xmrig on this system and I had change the kernel options.

is it running as root? is it a vps instance?