Patrick

How to start mining Monero in Docker

Notice: Page may contain affiliate links for which we may earn a small commission through services like Amazon Affiliates or Skimlinks.

Patrick

Administrator
Staff member
Dec 21, 2010
12,511
5,792
113
Patrick submitted a new resource:

How to start mining Monero in Docker - Your guide to turning servers into mining powerhouses

Since I am ultra tired today after a long workout, I decided to make a small resource for mining monero using Docker since I have a lot of requests for this.

It is a lot of text, but should take, at most 4-5 minutes to setup.

Step 1: Get a Monero wallet.

My suggestion: use an online wallet e.g. MyMonero

You will generate a key that has a whole bunch of random words. Best to keep that somewhere safe.

After you signup, you will be at an account...
Read more about this resource...
 

wlmbasson

New Member
Dec 17, 2017
2
0
1
37
Hi Patrick,

I can't quite figure out how to properly configure NUMA on the monero_xmrig docker for a dual AMD EPYC 7401 24-Core Processor server. I followed the how-to guide for AMD EPYC and only used the ranges before the commas, but I end up with some dockers doing 160 or 16 H/s.

I'm experimenting with different configs, but I was wondering do you know that the optimal for this server would be?

I noticed that some of the NUMA nodes don't register any cache so I assume I should avoid running on those. If I run with 6 threads on the four nodes that do register cache I get about 380 H/s per docker. If I increase the threads two dockers drop below 200.

I get better performance without configuring NUMA and just running numthreads=32 @1865.3 H/s. Doubling the thread count to 64 doesn't make a difference, in fact it makes it worse. According to Monero Mining Performance 1500 H/s should be possible on a single 7401. Any ideas?

My docker commands:

docker run -d -ti -e username=mywallet -e password=myemail -e numthreads=6 --cpuset-cpus="0-5" servethehome/monero_xmrig
docker run -d -ti -e username=mywallet -e password=myemail -e numthreads=6 --cpuset-cpus="6-11" servethehome/monero_xmrig
docker run -d -ti -e username=mywallet -e password=myemail -e numthreads=6 --cpuset-cpus="12-16" servethehome/monero_xmrig
docker run -d -ti -e username=mywallet -e password=myemail -e numthreads=6 --cpuset-cpus="18-23" servethehome/monero_xmrig

# numactl --hardware
available: 8 nodes (0-7)
node 0 cpus: 0 1 2 3 4 5 48 49 50 51 52 53
node 0 size: 65453 MB
node 0 free: 61554 MB
node 1 cpus: 6 7 8 9 10 11 54 55 56 57 58 59
node 1 size: 65536 MB
node 1 free: 63671 MB
node 2 cpus: 12 13 14 15 16 17 60 61 62 63 64 65
node 2 size: 0 MB
node 2 free: 0 MB
node 3 cpus: 18 19 20 21 22 23 66 67 68 69 70 71
node 3 size: 0 MB
node 3 free: 0 MB
node 4 cpus: 24 25 26 27 28 29 72 73 74 75 76 77
node 4 size: 65536 MB
node 4 free: 63220 MB
node 5 cpus: 30 31 32 33 34 35 78 79 80 81 82 83
node 5 size: 65520 MB
node 5 free: 63994 MB
node 6 cpus: 36 37 38 39 40 41 84 85 86 87 88 89
node 6 size: 0 MB
node 6 free: 0 MB
node 7 cpus: 42 43 44 45 46 47 90 91 92 93 94 95
node 7 size: 0 MB
node 7 free: 0 MB
node distances:
node 0 1 2 3 4 5 6 7
0: 10 16 16 16 32 32 32 32
1: 16 10 16 16 32 32 32 32
2: 16 16 10 16 32 32 32 32
3: 16 16 16 10 32 32 32 32
4: 32 32 32 32 10 16 16 16
5: 32 32 32 32 16 10 16 16
6: 32 32 32 32 16 16 10 16
7: 32 32 32 32 16 16 16 10
 

eroji

Active Member
Dec 1, 2015
276
52
28
40
I got the wallet address and put it into the script but docker logs shows this?

Code:
[xmr-usa.dwarfpool.com:8100] error: "invalid address used for login", code: -1
Took out the extra $hostname stuff in the example script for username and it's working.
 
Last edited:

Patrick

Administrator
Staff member
Dec 21, 2010
12,511
5,792
113
@eroji you are correct, it is not needed. Interesting. That script is the one I have been using.

The hostname is just for automatically using the machine's host name so you can have worker IDs.

BTW @wlmbasson if you have EPYC, you are better off mining Aeon and trading that for XMR.
 

eroji

Active Member
Dec 1, 2015
276
52
28
40
Got it running then tried to calculate the cost vs rewards based on my hash rate and the proceeded to deleted the VMs lol.
 

leebo_28

New Member
Apr 2, 2017
24
4
3
53
If you want to change the pools, simply change the pool name and the start port in the above and add those commands to the launch command.
Would someone be a little more clear on how this can be done? I want to use the Monero Docker image to mine a different coin.
 

jfoor

Member
Feb 4, 2017
81
20
8
36
Seems like the easiest way to mine Monero is to just docker pull some sketchy images from random users on the Docker hub. They'll start mining for you right away without you even knowing! ...just not to your wallet :)