sudo sysctl -w vm.nr_hugepages=1280
yada
sudo sysctl -w vm.nr_hugepages=$(nproc)
sudo bash -c "echo vm.nr_hugepages=1280 >> /etc/sysctl.conf"
yada
sudo bash -c "echo vm.nr_hugepages=$(nproc) >> /etc/sysctl.conf"
nano enable_1gb_pages.sh;
#!/bin/bash -e # https://xmrig.com/docs/miner/hugepages#onegb-huge-pages sysctl -w vm.nr_hugepages=$(nproc) for i in $(find /sys/devices/system/node/node* -maxdepth 0 -type d); do echo 3 > "$i/hugepages/hugepages-1048576kB/nr_hugepages"; done echo "1GB pages successfully enabled"
chmod +x enable_1gb_pages.sh;
nano randomx_boost.sh;
!/bin/bash modprobe msr if cat /proc/cpuinfo | grep "AMD Ryzen" > /dev/null; then echo "Detected Ryzen" wrmsr -a 0xc0011022 0x510000 wrmsr -a 0xc001102b 0x1808cc16 wrmsr -a 0xc0011020 0 wrmsr -a 0xc0011021 0x40 echo "MSR register values for Ryzen applied" elif cat /proc/cpuinfo | grep "Intel" > /dev/null; then echo "Detected Intel" wrmsr -a 0x1a4 0xf echo "MSR register values for Intel applied" else echo "No supported CPU detected" fi
chmod +x randomx_boost.sh;
Servis;
sudo nano /lib/systemd/system/xmrig.service
[Unit] Description=XmRIG [Service] Type=simple User=root WorkingDirectory=/home/hololu ExecStart=/home/hololu/xmrig/build/xmrig StandardOutput=null [Install] WantedBy=multi-user.target Alias=xmrig.service
systemctl enable xmrig.service systemctl start xmrig.service
İlk Yorumu Siz Yapın