Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Linux instruction for enabling huge pages #720

Closed
wants to merge 1 commit into from

Conversation

Artoria2e5
Copy link

No description provided.

@trasherdk
Copy link

Please notice. HugePage support has to be enabled in the kernel.
In Slackware 14.2 it's not.
To enable, a config and compile from source is required.

@xmrig
Copy link
Owner

xmrig commented Aug 1, 2020

@xmrig xmrig closed this Aug 1, 2020
@trasherdk
Copy link

None of the suggestions in the linked page help a stock Slackware installation.

The path in the enable_1gb_pages.sh script, /sys/devices/system/node/node* does not exist on Slackware :)

Unless recompiling the kernel, enabling hugepages, the path /proc/sys/vm/nr_hugepages does not exist.

# cat /proc/sys/vm/nr_hugepages
4
# echo 1280 > /proc/sys/vm/nr_hugepages
# cat /proc/sys/vm/nr_hugepages        
1024
# sysctl -w vm.nr_hugepages=1280
vm.nr_hugepages = 1280
# sysctl -n vm.nr_hugepages     
1025
# cat /proc/sys/vm/nr_hugepages
1025

Running xmrig as root, with the msr stuff in place.

 * ABOUT        XMRig/6.3.1 gcc/5.5.0
 * LIBS         libuv/1.35.0 OpenSSL/1.0.2u hwloc/2.1.0rc2-git
 * HUGE PAGES   supported
 * 1GB PAGES    unavailable
 * CPU          Intel(R) Xeon(R) CPU E3-1230 v5 @ 3.40GHz (1) x64 AES
                L2:1.0 MB L3:32.0 MB 4C/4T NUMA:1
 * MEMORY       7.2/7.8 GB (93%)
 * DONATE       1%
 * ASSEMBLY     auto:intel
 * POOL #1      localhost:8004 coin monero self-select localhost:38081
 * COMMANDS     hashrate, pause, resume, results, connection
 * OPENCL       disabled
 * CUDA         disabled
[2020-08-01 11:35:42.717]  net      use pool localhost:8004  127.0.0.1
[2020-08-01 11:39:22.380]  net      new job from localhost:8004 diff 1000 algo rx/0 height 634999
[2020-08-01 11:39:22.380]  cpu      use argon2 implementation AVX2
[2020-08-01 11:39:22.385]  msr      register values for "intel" preset has been set successfully (5 ms)
[2020-08-01 11:39:22.385]  randomx  init dataset algo rx/0 (4 threads) seed 3e01ec441ac88b75...
[2020-08-01 11:39:22.385]  randomx  failed to allocate RandomX dataset using 1GB pages
[2020-08-01 11:39:22.398]  randomx  allocated 2336 MB (2080+256) huge pages 11% 128/1168 +JIT (13 ms)
[2020-08-01 11:39:36.842]  randomx  dataset ready (14443 ms)
[2020-08-01 11:39:36.954]  cpu      use profile  rx  (2 threads) scratchpad 2048 KB
[2020-08-01 11:39:36.977]  cpu      READY threads 2/2 (2) huge pages 100% 2/2 memory 4096 KB (23 ms)
[2020-08-01 11:40:00.436]  cpu      accepted (1/0) diff 1000 (22983 ms)
[2020-08-01 11:40:06.945]  miner    speed 10s/60s/15m 458.5 n/a n/a H/s max 482.8 H/s
[2020-08-01 11:40:36.951]  miner    speed 10s/60s/15m 435.0 n/a n/a H/s max 482.8 H/s
[2020-08-01 11:41:06.986]  miner    speed 10s/60s/15m 435.4 435.5 n/a H/s max 482.8 H/s

Compared to running same config as non-privileged user, without the msr stuff.

 * ABOUT        XMRig/6.3.1 gcc/5.5.0
 * LIBS         libuv/1.35.0 OpenSSL/1.0.2u hwloc/2.1.0rc2-git
 * HUGE PAGES   supported
 * 1GB PAGES    unavailable
 * CPU          Intel(R) Xeon(R) CPU E3-1230 v5 @ 3.40GHz (1) x64 AES
                L2:1.0 MB L3:32.0 MB 4C/4T NUMA:1
 * MEMORY       5.6/7.8 GB (72%)
 * DONATE       1%
 * ASSEMBLY     auto:intel
 * POOL #1      localhost:8004 coin monero self-select localhost:38081
 * COMMANDS     hashrate, pause, resume, results, connection
 * OPENCL       disabled
 * CUDA         disabled
[2020-08-01 11:43:23.339]  net      use pool localhost:8004  127.0.0.1
[2020-08-01 11:43:23.417]  net      new job from localhost:8004 diff 1000 algo rx/0 height 635000
[2020-08-01 11:43:23.417]  cpu      use argon2 implementation AVX2
[2020-08-01 11:43:23.662]  msr      cannot read MSR 0x000001a4
[2020-08-01 11:43:23.662]  msr      cannot set MSR 0x000001a4 to 0x0000000f
[2020-08-01 11:43:23.662]  msr      FAILED TO APPLY MSR MOD, HASHRATE WILL BE LOW
[2020-08-01 11:43:23.663]  randomx  init dataset algo rx/0 (4 threads) seed 3e01ec441ac88b75...
[2020-08-01 11:43:23.663]  randomx  failed to allocate RandomX dataset using 1GB pages
[2020-08-01 11:43:23.678]  randomx  allocated 2336 MB (2080+256) huge pages 11% 128/1168 +JIT (15 ms)
[2020-08-01 11:43:32.411]  randomx  dataset ready (8734 ms)
[2020-08-01 11:43:32.411]  cpu      use profile  rx  (2 threads) scratchpad 2048 KB
[2020-08-01 11:43:32.435]  cpu      READY threads 2/2 (2) huge pages 100% 2/2 memory 4096 KB (23 ms)
[2020-08-01 11:43:51.088]  cpu      accepted (1/0) diff 1000 (17700 ms)
[2020-08-01 11:44:02.439]  miner    speed 10s/60s/15m 630.5 n/a n/a H/s max 631.4 H/s
[2020-08-01 11:44:32.458]  miner    speed 10s/60s/15m 631.3 n/a n/a H/s max 631.4 H/s

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants