notes:linux_miners
This is an old revision of the document!
Table of Contents
Gminer
- The
x
for--user
is the BTC Wallet address Nightwane
for--user
is the worker name and can be changed
./miner --algo 'ethash' --server 'stratum+ssl://stratum.usa-east.nicehash.com:33353' --user 'x.Nightwane'
Nightwane
- RTX 3060 (LHRv2)
- CUDA
- Sets GPU fan speed to static 80%
- Sets GPU core clock offset to +125
- Sets GPU memory clock offset to +1300
- Sets GPU power limit to max 190W
#!/usr/bin/bash # GPU OC sync nvidia-settings --assign='GPUFanControlState'='1' nvidia-settings --assign='GPUTargetFanSpeed'='80' nvidia-settings --assign='GPUPowerMizerMode'='1' nvidia-settings --assign='GPUGraphicsClockOffsetAllPerformanceLevels'='125' nvidia-settings --assign='GPUMemoryTransferRateOffsetAllPerformanceLevels'='1300' sudo nvidia-smi --power-limit='190' # Miner sync ./miner --algo 'ethash' --server 'stratum+ssl://stratum.usa-east.nicehash.com:33353' --user 'x.Nightwane'
T-Rex
- The
x
for--user
is the BTC Wallet address
./'t-rex' --algo 'ethash' --url 'stratum+ssl://stratum.usa-east.nicehash.com:33353' --user 'x' --worker 'Nightwane'
Nightwane
- RTX 3060 (LHRv2)
- CUDA
- Sets GPU fan speed to static 80%
- Sets GPU core clock offset to +125
- Sets GPU memory clock offset to +1300
- Sets GPU power limit to max 190W
#!/usr/bin/bash # GPU OC sync nvidia-settings --assign='GPUFanControlState'='1' nvidia-settings --assign='GPUTargetFanSpeed'='80' nvidia-settings --assign='GPUPowerMizerMode'='1' nvidia-settings --assign='GPUGraphicsClockOffsetAllPerformanceLevels'='125' nvidia-settings --assign='GPUMemoryTransferRateOffsetAllPerformanceLevels'='1300' sudo nvidia-smi --power-limit='190' # Miner sync ./'t-rex' --algo 'ethash' --url 'stratum+ssl://stratum.usa-east.nicehash.com:33353' --user 'x' --worker 'Nightwane'
nsfminer
- The
x
before.Nightwane
is the BTC Wallet address
./'nsfminer' -P 'stratum2+tcp://x.Nightwane@daggerhashimoto.usa.nicehash.com:3353'
Oak
- RX 580
#!/usr/bin/bash # Miner sync ./miner --algo 'ethash' --server 'stratum+ssl://stratum.usa-east.nicehash.com:33353' --user 'x.Oak'
AMDGPU-PRO
- Last tested: 2022/03/16 on Fedora 35
- This failed to work 2022/03/17 on a fresh Fedora 35 install, and magically worked later. This is seemingly unreliable.
Shim
- This is apparently required so that AMDGPU doesn't replace Mesa files and cause a black screen on next boot
sudo dnf copr enable 'rmnscnce/amdgpu-pro-shims'
sudo dnf install 'amdgpu-pro-shims'
Download
- 21.30 is the last release from AMD with the full driver package in
.xz
cd ~/'Downloads'
aria2c 'https://drivers.amd.com/drivers/linux/amdgpu-pro-21.30-1290604-rhel-8.4.tar.xz' --referer='drivers.amd.com'
Extract
cd '/var/local'
sudo tar xf ~/'Downloads/amdgpu-pro-21.30-1290604-rhel-8.4.tar.xz'
sudo mv 'amdgpu-pro-21.30-1290604-rhel-8.4' 'amdgpu'
Repo
sudo -e '/etc/yum.repos.d/amdgpu.repo'
[amdgpu] name=AMDGPU Packages baseurl=file:///var/local/amdgpu/ enabled=1 skip_if_unavailable=1 gpgcheck=0 cost=500 metadata_expire=300
Packages
sudo dnf update && sudo dnf install opencl-rocr-amdgpu-pro rocm-device-libs-amdgpu-pro hsa-runtime-rocr-amdgpu hsakmt-roct-amdgpu hip-rocr-amdgpu-pro comgr-amdgpu-pro opencl-orca-amdgpu-pro-icd libdrm-amdgpu-common ocl-icd-amdgpu-pro opencl-rocr-amdgpu-pro amdgpu-pro-core clinfo && sync
Finalize
sync && systemctl reboot
clinfo
Service
- Change
x
to a BTC wallet address
mkdir -p ~/'.local/bin/nsfminer' && sudo -e '/etc/systemd/system/nsfminer.service' && sudo sed -i 's/CHANGEME/'$USER'/g' '/etc/systemd/system/nsfminer.service' && sudo systemctl daemon-reload && sudo systemctl enable 'nsfminer'
[Unit] Description=nsfminer GPU Miner Wants=network-online.target After=network-online.target [Service] Type=simple User=CHANGEME Group=CHANGEME WorkingDirectory=/home/CHANGEME/.local/bin/nsfminer ExecStart='/home/CHANGEME/.local/bin/nsfminer/nsfminer' -P 'stratum2+tcp://x.Oak@daggerhashimoto.usa.nicehash.com:3353' Restart=always RestartSec=5 [Install] WantedBy=multi-user.target
Group
- It appears for OpenCL applications in the background, they need
video
permissions - TODO: Test without this
sudo usermod --append --groups 'video' 'espionage724'
SELinux
Context
sudo restorecon -F -I -R -v ~/'.local/bin/nsfminer'
Bool
- This appears to allow DNS resolutions
sudo setsebool -P 'nis_enabled' 'on'
Permissions
sudo setenforce 0
sudo systemctl start 'nsfminer' && sudo systemctl status 'nsfminer' -l
mkdir -p ~/'policies' && cd ~/'policies' && sudo grep 'miner' '/var/log/audit/audit.log' | sudo audit2allow -M 'miner' && sudo semodule -i 'miner.pp' && cd ~
mkdir -p ~/'policies' && cd ~/'policies' && sudo grep 'cl-0' '/var/log/audit/audit.log' | sudo audit2allow -M 'cl-0' && sudo semodule -i 'cl-0.pp' && cd ~
sudo systemctl stop 'nsfminer' && sudo setenforce 1 && sync
/var/www/wiki/data/attic/notes/linux_miners.1647535760.txt.gz ยท Last modified: 2022/03/17 12:49 by Sean Rhone