Pool connection definition is issued via -P
argument which has this syntax:
-P scheme://user[.workername][:password]@hostname:port[/...]
values in square brackets are optional
where scheme
can be any of:
http
for getwork mode (geth)stratum+tcp
for plain stratum modestratum1+tcp
for plain stratum eth-proxy compatible modestratum2+tcp
for plain stratum NiceHash compatible mode
This notation is called URI notation and gives us great flexibility allowing ethminer to specify all needed arguments per single connection (other miners offer single dedicated CLI arguments which are valid for all connections). An URI is formed like this
Authority
+---------------------------------------------------------------------+
stratum://0x123456789012345678901234567890.Worker:[email protected]:4444
+------+ +----------------------------------------------+ +---------------+ +--+
| | | |
| | | + > Port
| | + ------------- > Host
| + ------------------------------------------------ > User Info
+ -------------------------------------------------------------------------- > Scheme
Optionally you can append to the above notation anything which might be useful in the form of a path. Example
stratum://0x123456789012345678901234567890.Worker:[email protected]:4444/something/else
+--------------+
|
Path --------------- +
Anything you put in the Path
part must be Url Encoded thus, for example, @
must be written as %40
As you may have noticed due to compatibility with pools we need to know exactly which are the delimiters for the account, the workername (if any) and the password (if any) which are respectively a dot .
and a column :
.
Should your values contain any of the above mentioned chars or any other char which may impair the proper parsing of the URI you have two options:
- either enclose the string in backticks (ASCII 96)
- or URL encode the impairing chars
Say you need to provide the pool with an account name which contains a dot. At your discretion you may either write
-P stratum://`account.1234`.Worker:[email protected]:4444
or
-P stratum://account%2e1234.Worker:[email protected]:4444
The above samples produce the very same result.
*Backticks on nix. The backtick enclosure has a special meaning of execution thus you may need to further escape the sequence as
-P stratum://\`account.1234\`.Worker:[email protected]:4444
%
on Windows. The percent symbol %
has a special meaning in Windows batch files thus you may need to further escape it by doubling. Following example shows %2e
needs to be replaced as %%2e
-P stratum://account%%2e1234.Worker:[email protected]:4444
Ethminer supports secure socket communications (where pool implements and offers it) to avoid the risk of a man-in-the-middle attack To enable it simply replace tcp with either:
tls
to enable secure socket communicationssl
ortls12
to enable secure socket communication allowing only TLS 1.2 encryption
thus your connection scheme changes to -P stratum+tls://[...]
or -P stratum+tls12://[...]
. Same applies for stratum1
and stratum2
.
You can use the %xx (xx=hexvalue of character) to pass special values. Some examples:
Code | Character |
---|---|
%25 | % |
%26 | & |
%2e | . |
%2f | / |
%3a | : |
%3f | ? |
%40 | @ |
Stratum autodetection has been introduced to mitigate user's duty to guess/find which stratum flavour to apply (stratum or stratum1 or stratum2).
If you want to let ethminer do the tests for you simply enter scheme as stratum://
(note +tcp
is missing) or stratums://
for secure socket or stratumss://
for secure socket allowing only TLS 1.2 encryption.
Here you can find a collection of samples to connect to most commonly used ethash pools. (alphabetic order).
- Stratum connection is always to be preferred over getwork when pool offers it due to its better network latency.
- If possible the samples use a protocol which supports reporting of hashrate (
--report-hashrate
) if pool supports this.
Check for updates in the pool connection settings visiting the pools homepage.
We tried to merge the requirements of the variables so they match all pools.
Variables | Description | Sample |
---|---|---|
ETH_WALLET |
Replace ETH_WALLET with your Ethereum wallet number including the leading 0x . |
0x1234567890ABCDEF1234567890abcdef12345678 |
WORKERNAME |
WORKERNAME may only contain letters and numbers. Some pools also only allow up to a maximum of 8 characters! |
pl1rig01 |
EMAIL |
EMAIL may contain letters, numbers, underscores. Please encode dashes, @-sign and other uncommon charaters using the Special characters |
joe1.doe_jr-ny%40acme.com |
USERNAME |
USERNAME you got from the pool (like miningpoolhub.com) |
my_username |
WORKERPWD |
WORKERPWD is the password you got from the pool for the worker (like miningpoolhub.com) - if you have no password set try using 'x' |
my_workerpwd |
BTC_WALLET |
As some pools honor your work in BTC (eg nicehash.com) BTC_WALLET is your Bitcoin wallet address |
1A2b3C4d5e5F6g7H8I9j0kLmNoPqRstUvW |
The servers are listed in alphabetical order. To get best results reorder them from nearest to farest distance depending on your geographic location.
-P stratum1+tcp://[email protected]:2020
With email
-P stratum1+tcp://[email protected]:8008/WORKERNAME/EMAIL
-P stratum1+tcp://[email protected]:8008/WORKERNAME/EMAIL
-P stratum1+tcp://[email protected]:8008/WORKERNAME/EMAIL
-P stratum1+tcp://[email protected]:8008/WORKERNAME/EMAIL
-P stratum1+tcp://[email protected]:8008/WORKERNAME/EMAIL
-P stratum1+tcp://[email protected]:8008/WORKERNAME/EMAIL
-P stratum1+tcp://[email protected]:8008/WORKERNAME/EMAIL
-P stratum1+tcp://[email protected]:8008/WORKERNAME/EMAIL
-P stratum1+tcp://[email protected]:8008/WORKERNAME/EMAIL
-P stratum1+tcp://[email protected]:8008/WORKERNAME/EMAIL
-P stratum1+tcp://[email protected]:8008/WORKERNAME/EMAIL
-P stratum1+tcp://[email protected]:8008/WORKERNAME/EMAIL
-P stratum1+tcp://[email protected]:8008/WORKERNAME/EMAIL
Without email
-P stratum1+tcp://[email protected]:8008
-P stratum1+tcp://[email protected]:8008
-P stratum1+tcp://[email protected]:8008
-P stratum1+tcp://[email protected]:8008
-P stratum1+tcp://[email protected]:8008
-P stratum1+tcp://[email protected]:8008
-P stratum1+tcp://[email protected]:8008
-P stratum1+tcp://[email protected]:8008
-P stratum1+tcp://[email protected]:8008
-P stratum1+tcp://[email protected]:8008
-P stratum1+tcp://[email protected]:8008
-P stratum1+tcp://[email protected]:8008
-P stratum1+tcp://[email protected]:8008
HINTS:
- Use "%40" for the @-sign in your email address
Non-SSL connection:
-P stratum1+tcp://[email protected]:4444
-P stratum1+tcp://[email protected]:4444
-P stratum1+tcp://[email protected]:4444
-P stratum1+tcp://[email protected]:4444
SSL connection:
-P stratum1+ssl://[email protected]:5555
-P stratum1+ssl://[email protected]:5555
-P stratum1+ssl://[email protected]:5555
-P stratum1+ssl://[email protected]:5555
-P stratum1+tcp://[email protected]:3333
-P stratum1+tcp://[email protected]:3333
-P stratum1+tcp://[email protected]:3333
-P stratum1+tcp://[email protected]:8008
Non-SSL connection:
-P stratum1+tcp://[email protected]:4444
-P stratum1+tcp://[email protected]:4444
SSL connection:
-P stratum1+ssl://[email protected]:5555
-P stratum1+ssl://[email protected]:5555
-P stratum2+tcp://USERNAME%2eWORKERNAME:[email protected]:20535
-P stratum2+tcp://USERNAME%2eWORKERNAME:[email protected]:20535
-P stratum2+tcp://USERNAME%2eWORKERNAME:[email protected]:20535
HINTS:
- miningpoolhub.com needs username.workername in the internal login process. Use "%2e" to join them into one parameter.
- It seems the password is not being verified by the pool so you can use a plain
x
asWORKERPWD
.
With email:
-P stratum1+tcp://[email protected]:9999/WORKERNAME/EMAIL
-P stratum1+tcp://[email protected]:9999/WORKERNAME/EMAIL
-P stratum1+tcp://[email protected]:9999/WORKERNAME/EMAIL
-P stratum1+tcp://[email protected]:9999/WORKERNAME/EMAIL
-P stratum1+tcp://[email protected]:9999/WORKERNAME/EMAIL
Without email:
-P stratum1+tcp://[email protected]:9999
-P stratum1+tcp://[email protected]:9999
-P stratum1+tcp://[email protected]:9999
-P stratum1+tcp://[email protected]:9999
-P stratum1+tcp://[email protected]:9999
HINTS:
- Use "%40" for the @-sign in your email address
-P stratum2+tcp://[email protected]:3353
-P stratum2+tcp://[email protected]:3353
-P stratum2+tcp://[email protected]:3353
-P stratum2+tcp://[email protected]:3353
-P stratum2+tcp://[email protected]:3353
-P stratum2+tcp://[email protected]:3353
-P stratum1+tcp://[email protected]:3333
-P stratum1+tcp://[email protected]:3333
-P stratum1+tcp://[email protected]:3333
-P stratum1+tcp://[email protected]:3333
-P stratum1+tcp://[email protected]:3333
-P stratum1+tcp://[email protected]:3333
-P stratum1+tcp://[email protected]:3333
-P stratum1+tcp://[email protected]:8082