A couple of years ago Monero and other cryptonight based coins were really not worthwhile to mine on cpu's anylonger because of the creation of GPU miner programs then the creation of ASIC's, With the RandomX and RandomX based algo's cpu's will once again become worthwhile to use cpu's to mine.
Some of you know about and have played around some mining one of the few current crypto coins that are out that use RandomX or a version of RandomX, Loki seems to be the most stable, so this is really not geared to you but to those that are unfamiliar with RandomX and have some older Open Compute servers or other servers that are underutilized and collecting dust.
RandomX is the next algo that Monero will use with the next network update due in October (EDIT: Now the network update will be on November 30.) It is VERY ASIC and GPU unfreindly but works extremely well on cpu's especially the new Ryzen 3XXX and EPYC Rome cpu's.
But as long as the cpu has the following specs it will mine Monero/RandomX MUCH faster than the old cryptonight based algos:
64-bit architecture.
16 KiB of L1 cache, 256 KiB of L2 cache and 2 MiB of L3 cache per mining thread.
IEEE 754 compliant floating point unit.
Hardware AES support (AES-NI extension for x86, Cryptography extensions for ARMv8).
Support for large memory pages.
Plus you will need at least 2.5 GiB of free RAM per NUMA node, multiple channels and the faster* the ram the better.
*DDR3 memory is limited to about 1500-2000 H/s per channel (depending on frequency and timings)
*DDR4 memory is limited to about 4000-6000 H/s per channel (depending on frequency and timings)
Github of RandomX's creator for more info:
tevador/RandomX
This guide is about using and cheaply upgrading older hardware that alot of people still have for home use since they are new enough to be really usefull to use for many purposes and old enough to be cheap to run or upgrade.
E5-26xx Xeons are good enough to mine, not as good as the new AMD cpu's but alot of people have these readily available.
(Also old AMD Opteron four cpu servers seem to be very usable mining RandomX tho very power hungry.)
I do have a couple of Ryzen 3XXX cpu pc's but I also have these old Open Compute servers that I bought about three years ago.
Each was built mainly to a price/low tdp as possible as a priority.
Specs on them:
Wiwynn Windmill socket 2011 Open Compute Server with two dual socket 2011 nodes with 16 ram slots per node that can run DDR3 ECC 800, 1066, 1333 and 1600 speeds.
Will only run E5-26xx V1 cpu's so if you want to run V2 cpu's you need to use the Quanta version, yes I had trials and tribulations trying to mod the bios to accept Ivy Bridge microcode but gave up.
(But I was able to mod the bios with much newer V1 cpu microcode and newer code for the two network chips.)
Currently upgraded 2x E5-2650L v1 cpu's, 16x DDR3 PC8500R ram and WD 250 GB hard drives on each node.
*NOTE: Go ahead and install new CR2032 motherboard batterys, the old ones that still show around 3.0v instead of 3.3v caused the servers to have issues.
They all were cheap!! Cpu's $18.00 each, ram was $.32 per GB, and the hard drives were $4.00 each.
The cpu choice was because I wanted the most cores and lowest TDP as cheap as possible, the ram is way more than needed at 64gb per node but it was so cheap and if needed I can remove some if the power use is unacceptable.
The hard drives I already had as well as the three OC servers.
I admit this setup will not be nearly as efficient as the newer cpu's but it's about using what I have and getting the best bang for the buck out of them.
To update them I spent $56.83 per node and each node should hash about 4000 H/s with dual 2650L cpu's. So six nodes cost me $340 to update and should get about 24,000 H/s mining randomX total on the three OC servers with the 2650L's.
To put that in perspective my AMD Ryzen 3700X was $329.00, X570 MSI motherboard was $169.00 and the rest I already had and it mines RandomX at ~7700 H/s.
Yes I could have went for E5-2670's for more performance but they just put out too much heat and use too much power and the 2650L's should be a good price/performance/power/lower heat compromise. I also could have went with faster ram but I tested PC3-14900 ram and it was not a whole lot faster and 14900 is quite a bit more in price.
So that said lets get started.
I chose Ubuntu 19.04 simply because it runs so nice and is so easy to use on these servers and I had an issue with Ubuntu 18.04.3 with a 2 minute delay on booting waiting on Ubuntu deciding that it cant configure the second network interface that is unused.
My install procedure with Ubuntu 19.04 server:
1. Temporarily install an old PCI-e video card , keyboard and usb dvd drive or flash drive.
2. Boot up and go into bios and select the bootable install media drive.
3. Save and then reset and then start the install with the Ubuntu 19.04 installer.
4. I picked ALL the default install options including the use the whole disk without LVM and also the "install ssd server" option and nothing else, you can add additional roles if you would like but for now it is not needed by me.
5. Finish the install and reboot, and made sure it actually rebooted and is at the login prompt on the monitor. You may have to hit the reset or more likely the power off due to the reboot hang issue that all the newer versions of Ubuntu have with Open Compute servers that will get fixed in the steps below.
6. Log in via ssh from another pc with these instructions open.
7.To fix reboot hang in newer versions of Ubuntu type this command :
echo "options mei-me disable_msi=1" | sudo tee /etc/modprobe.d/mei-me.conf
Next enter sudo password when prompted.
8. To mine using hugepages with Xmrig 3.0 type in this command:
sudo nano /etc/sysctl.conf
Add this to the end:
vm.nr_hugepages = 2560
(Enabling hugepages is a must with RandomX as you will take a huge hit if it is not enabled. Also Xmrig mining RandomX needs alot more than the old algo, some have been able to set it to "vm.nr_hugepages =1280" and run fine with that.)
9.Next edit:
sudo nano /etc/security/limits.conf
Add these two lines at the end:
* soft memlock unlimited
* hard memlock unlimited
NOTE: Probably not a good idea to use "memlock unlimited" on a normal install but this server is mining only and will not have any other user except for me and I will only run one miner program and so far it seems to work fine.
10. Reboot
11. If it fails to reboot, power off then power back on.
I've had to enter this command again on about half the Ubuntu installs as it does not always "stick" the first time for some reason.
echo "options mei-me disable_msi=1" | sudo tee /etc/modprobe.d/mei-me.conf
12. Reboot again if you did the above.
13. Log in via ssh from your desktop.
14. Update Ubuntu then reboot again.
15. Install and configure lm-sensors to be able to monitor the cpu temps.
16. Download and compile what ever miner you are using, currently only Xmrig 3.0 for RandomX as of now.
Latest version of Xmrig:
xmrig/xmrig
17. Configure the miner config files and then start mining. ( I'm currently mining Loki for now just to test mining a RandomX algo.)
This like the original Dedicated Crypto Mining Open Compute server build from three years ago this is a work in progress.
Also I am in the middle of installing Ubuntu and configuring the servers as I was typing this so I only tested by using the randomx benchmark not actually mining on one node on one server with the 2650L cpu's and several ram combinations and also a couple of E5-2603 cpu's.
Using RandomX benchmark the binary version on a Open Compute node running Ubuntu 18.04.3:
Dual E5-2650L cpu's ~4000 H/s w/PC3-8500R ram in quad channel and ~4005 PC3-14900 in dual channel
Dua1 E5-2603 cpu's ~1900 H/s w/ PC3-8500 quad channel
Mining Loki with xmrig 3.0:
Ryzen 3700x ~7700 H/s Ubuntu 18.04.3 ~7400 H/s Windows 10
Dual E5-2667 V3 ES cpu's Ubuntu 18.04.3 ~ 6600 H/s
Some of you know about and have played around some mining one of the few current crypto coins that are out that use RandomX or a version of RandomX, Loki seems to be the most stable, so this is really not geared to you but to those that are unfamiliar with RandomX and have some older Open Compute servers or other servers that are underutilized and collecting dust.
RandomX is the next algo that Monero will use with the next network update due in October (EDIT: Now the network update will be on November 30.) It is VERY ASIC and GPU unfreindly but works extremely well on cpu's especially the new Ryzen 3XXX and EPYC Rome cpu's.
But as long as the cpu has the following specs it will mine Monero/RandomX MUCH faster than the old cryptonight based algos:
64-bit architecture.
16 KiB of L1 cache, 256 KiB of L2 cache and 2 MiB of L3 cache per mining thread.
IEEE 754 compliant floating point unit.
Hardware AES support (AES-NI extension for x86, Cryptography extensions for ARMv8).
Support for large memory pages.
Plus you will need at least 2.5 GiB of free RAM per NUMA node, multiple channels and the faster* the ram the better.
*DDR3 memory is limited to about 1500-2000 H/s per channel (depending on frequency and timings)
*DDR4 memory is limited to about 4000-6000 H/s per channel (depending on frequency and timings)
Github of RandomX's creator for more info:
tevador/RandomX
This guide is about using and cheaply upgrading older hardware that alot of people still have for home use since they are new enough to be really usefull to use for many purposes and old enough to be cheap to run or upgrade.
E5-26xx Xeons are good enough to mine, not as good as the new AMD cpu's but alot of people have these readily available.
(Also old AMD Opteron four cpu servers seem to be very usable mining RandomX tho very power hungry.)
I do have a couple of Ryzen 3XXX cpu pc's but I also have these old Open Compute servers that I bought about three years ago.
Each was built mainly to a price/low tdp as possible as a priority.
Specs on them:
Wiwynn Windmill socket 2011 Open Compute Server with two dual socket 2011 nodes with 16 ram slots per node that can run DDR3 ECC 800, 1066, 1333 and 1600 speeds.
Will only run E5-26xx V1 cpu's so if you want to run V2 cpu's you need to use the Quanta version, yes I had trials and tribulations trying to mod the bios to accept Ivy Bridge microcode but gave up.
(But I was able to mod the bios with much newer V1 cpu microcode and newer code for the two network chips.)
Currently upgraded 2x E5-2650L v1 cpu's, 16x DDR3 PC8500R ram and WD 250 GB hard drives on each node.
*NOTE: Go ahead and install new CR2032 motherboard batterys, the old ones that still show around 3.0v instead of 3.3v caused the servers to have issues.
They all were cheap!! Cpu's $18.00 each, ram was $.32 per GB, and the hard drives were $4.00 each.
The cpu choice was because I wanted the most cores and lowest TDP as cheap as possible, the ram is way more than needed at 64gb per node but it was so cheap and if needed I can remove some if the power use is unacceptable.
The hard drives I already had as well as the three OC servers.
I admit this setup will not be nearly as efficient as the newer cpu's but it's about using what I have and getting the best bang for the buck out of them.
To update them I spent $56.83 per node and each node should hash about 4000 H/s with dual 2650L cpu's. So six nodes cost me $340 to update and should get about 24,000 H/s mining randomX total on the three OC servers with the 2650L's.
To put that in perspective my AMD Ryzen 3700X was $329.00, X570 MSI motherboard was $169.00 and the rest I already had and it mines RandomX at ~7700 H/s.
Yes I could have went for E5-2670's for more performance but they just put out too much heat and use too much power and the 2650L's should be a good price/performance/power/lower heat compromise. I also could have went with faster ram but I tested PC3-14900 ram and it was not a whole lot faster and 14900 is quite a bit more in price.
So that said lets get started.
I chose Ubuntu 19.04 simply because it runs so nice and is so easy to use on these servers and I had an issue with Ubuntu 18.04.3 with a 2 minute delay on booting waiting on Ubuntu deciding that it cant configure the second network interface that is unused.
My install procedure with Ubuntu 19.04 server:
1. Temporarily install an old PCI-e video card , keyboard and usb dvd drive or flash drive.
2. Boot up and go into bios and select the bootable install media drive.
3. Save and then reset and then start the install with the Ubuntu 19.04 installer.
4. I picked ALL the default install options including the use the whole disk without LVM and also the "install ssd server" option and nothing else, you can add additional roles if you would like but for now it is not needed by me.
5. Finish the install and reboot, and made sure it actually rebooted and is at the login prompt on the monitor. You may have to hit the reset or more likely the power off due to the reboot hang issue that all the newer versions of Ubuntu have with Open Compute servers that will get fixed in the steps below.
6. Log in via ssh from another pc with these instructions open.
7.To fix reboot hang in newer versions of Ubuntu type this command :
echo "options mei-me disable_msi=1" | sudo tee /etc/modprobe.d/mei-me.conf
Next enter sudo password when prompted.
8. To mine using hugepages with Xmrig 3.0 type in this command:
sudo nano /etc/sysctl.conf
Add this to the end:
vm.nr_hugepages = 2560
(Enabling hugepages is a must with RandomX as you will take a huge hit if it is not enabled. Also Xmrig mining RandomX needs alot more than the old algo, some have been able to set it to "vm.nr_hugepages =1280" and run fine with that.)
9.Next edit:
sudo nano /etc/security/limits.conf
Add these two lines at the end:
* soft memlock unlimited
* hard memlock unlimited
NOTE: Probably not a good idea to use "memlock unlimited" on a normal install but this server is mining only and will not have any other user except for me and I will only run one miner program and so far it seems to work fine.
10. Reboot
11. If it fails to reboot, power off then power back on.
I've had to enter this command again on about half the Ubuntu installs as it does not always "stick" the first time for some reason.
echo "options mei-me disable_msi=1" | sudo tee /etc/modprobe.d/mei-me.conf
12. Reboot again if you did the above.
13. Log in via ssh from your desktop.
14. Update Ubuntu then reboot again.
15. Install and configure lm-sensors to be able to monitor the cpu temps.
16. Download and compile what ever miner you are using, currently only Xmrig 3.0 for RandomX as of now.
Latest version of Xmrig:
xmrig/xmrig
17. Configure the miner config files and then start mining. ( I'm currently mining Loki for now just to test mining a RandomX algo.)
This like the original Dedicated Crypto Mining Open Compute server build from three years ago this is a work in progress.
Also I am in the middle of installing Ubuntu and configuring the servers as I was typing this so I only tested by using the randomx benchmark not actually mining on one node on one server with the 2650L cpu's and several ram combinations and also a couple of E5-2603 cpu's.
Using RandomX benchmark the binary version on a Open Compute node running Ubuntu 18.04.3:
Dual E5-2650L cpu's ~4000 H/s w/PC3-8500R ram in quad channel and ~4005 PC3-14900 in dual channel
Dua1 E5-2603 cpu's ~1900 H/s w/ PC3-8500 quad channel
Mining Loki with xmrig 3.0:
Ryzen 3700x ~7700 H/s Ubuntu 18.04.3 ~7400 H/s Windows 10
Dual E5-2667 V3 ES cpu's Ubuntu 18.04.3 ~ 6600 H/s
Last edited: