How To Setup Miners For Monero (XMR)

Learn how to securely set up and operate a Monero miner, to mitigate against cyber theft with Alessanco Innocenzi.

How To Setup Miners For Monero (XMR)

SPOILER ALERT: This isn’t a tutorial to get rich with yet another cryptocurrency, it’s for study purposes only because I'm a cryptogeek as well as a sec practitioner.

What Is Monero?

In case you didn't already know, Monero is a cryptocurrency created in April 2014. Yet another cryptocurrency? - I hear you groan! But Monero has something going for it that Bitcoin doesn’t have: privacy.

Monero obfuscates all. There’s no way to know the sending address, the amount sent and/or the receiving address. You can also use Tor to connect to other Monero nodes which is really cool and the reason why people use Monero to buy drugs, weapons and other interesting things.

A good starting point is Monero How which has a ton of information for you about Monero and how to get started mining it.

Like this article about how to create a Monero command line wallet. For sure there is MyMonero, a web wallet like Coinbase, but be careful with web wallets, because you could lose all your coins if those wallets closed (Mt.Gox docet).

So, if you can, use a local wallet or better an hardware wallet, there’s a Monero wallet application for Ledger Blue and Nano S.

Setup Miners

If you’re reading this article, you want to setup a miner, obviously. First of all, check the Monero Mining Calculator to verify if it’s worth it. The hash rate depends from your hardware, you can check some benchmarks with XMR-Stak here.

Just to say, XMR-Stak on a CentOS virtual machine with 4GB of RAM (my notebook has 16GB) and 4 cores of an i7–6820HQ processor, has an hash rate of 110h/s. Instead, the max hash rate with Claymore’s CryptoNote Windows CPU Miner directly on my notebook is 260h/s. And no, we’ll not become rich.

Second, because I don’t think you have a data center like Google to mine Monero or other cryptocurrencies, I recommend you to become a member of a mining pool, a group of people that share their processing power to mine all together and split the reward equally, based on their contribute. I’ve used supportXMR, check their getting started!

XMR-Stak On CentOS

CentOS is a Linux distribution that derives from Red Hat Enterprise Linux (known as RHEL). I’ve downloaded the Minimal ISO from here and just for testing I’ve created a virtual machine with VirtualBox (a free and open-source hypervisor like VMware or others, with which you can create and run operating systems into your operating system!).

Once you’ve installed CentOS, download XMR-Stak from GitHub, an all-in-one mining pool software. With this guide and the help of Antonio, a person with whom it’s a real pleasure to talk, share and put hands-on on blockchain and IoT projects, I did the following steps:

yum update
yum install git
sudo yum install centos-release-scl epel-release
sudo yum install cmake3 devtoolset-4-gcc* hwloc-devel libmicrohttpd-devel openssl-devel make
scl enable devtoolset-4 bash
git clone
mkdir xmr-stak/build
cd xmr-stak/build
make install

Furthermore, I’ve configured Huge Pages with the command

sysctl -w vm.nr_hugepages=128

If you want this value even on boot, add the above line into /etc/sysctl.conf.

Now, start the miner with the command


and fill the prompts. Select monero7 as cryptocurrency to mine, (firewall bypass, as you can see in the Pick a mining server and port section on supportXMR Getting Started) as mining pool, enter your Monero address, put some others info and start the mining!

Just a note: as pool password, insert something like miner01:[email protected], where miner01 is an arbitrary name that I use in the supportXMR Dashboard, and the email address is the same that I’ve used on supportXMR.

In the supportXMR Dashboard, you can add a payment address to see live stats of all your miners. Very useful!

Claymore’s CryptoNote On Windows

As I just said, there is a Windows miner, the Claymore’s CryptoNote Windows CPU Miner, which it’s very easy to use.

Download it here and edit the config.txt file like this:

-o ssl://
-u 42AdW89Qc5UM5BFsabC9oo11...
-p miner02:[email protected]
-t 4
-pow7 1

The parameters are:

-o to set the pool address. You can see the list in the Pick a mining server and port section on supportXMR Getting Started.
-u to set your wallet address.
-p to set the password. As seen above, in this case miner02 is the arbitrary name that I use in the supportXMR Dashboard for the Windows client.
-t to set number of threads.
-pow7 1 to support Monero hardfork.

Stats of miner02 on supportXMR dashboard.
Stats of miner02 on supportXMR dashboard.

After doing that, launch the NsCpuCNMiner64.exe file and check your speed. You can try to change the configuration parameters (for example using -lowcpu) to find your best hash rate!

Tony Monero On Android

At the time of writing, apparently only one app has been updated to support the hard fork monerov7: Tony Monero!

With mobile miners, it’s recommend to use a mining pool with low mining difficulty like MoneroOcean.

My mobile miner runs… with an handbreak.
My mobile miner runs… with an handbreak.

I tested it on a Samsung J7 2016, giving it 4 cores. I arrived at the impressive speed of 9.2h/s while with 6 cores the max speed was 7.8h/s. Note that Tony Monero get 1 core to handle mining process, so Android doesn’t perform with only 1 core for him.

Anyway, no, I still don’t get rich.

A big THANK YOU to Antonio to for always being available to share his knowledge and put up with me and my hundreds of questions!