From c59845e74693ce79cd6391c38fdefbb3bd211859 Mon Sep 17 00:00:00 2001 From: SChernykh Date: Sun, 29 Oct 2023 09:43:22 +0100 Subject: [PATCH 1/3] Fixed cppcheck errors --- src/side_chain.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/side_chain.cpp b/src/side_chain.cpp index e571ab1..17b9f8d 100644 --- a/src/side_chain.cpp +++ b/src/side_chain.cpp @@ -1568,7 +1568,7 @@ void SideChain::verify(PoolBlock* block) } // Check that uncle and parent have the same ancestor (they must be on the same chain) - PoolBlock* tmp = parent; + const PoolBlock* tmp = parent; while (tmp->m_sidechainHeight > uncle->m_sidechainHeight) { tmp = get_parent(tmp); if (!tmp) { @@ -1591,7 +1591,7 @@ void SideChain::verify(PoolBlock* block) } bool same_chain = false; - PoolBlock* tmp2 = uncle; + const PoolBlock* tmp2 = uncle; for (size_t j = 0; (j < UNCLE_BLOCK_DEPTH) && tmp && tmp2 && (tmp->m_sidechainHeight + UNCLE_BLOCK_DEPTH >= block->m_sidechainHeight); ++j) { if (tmp->m_parent == tmp2->m_parent) { same_chain = true; From 7b02c3d24a43b922b2568c883009df40e4aab013 Mon Sep 17 00:00:00 2001 From: SChernykh Date: Mon, 30 Oct 2023 09:49:36 +0100 Subject: [PATCH 2/3] Documentation: recommend more in-peers This will balance out peers which can only have outgoing connections. --- README.md | 10 +++++----- docker-compose/cfg/docker-compose.jinja2 | 4 ++-- docker-compose/docker-compose.yml | 4 ++-- docs/html/index.html | 5 +++-- docs/html/mini/index.html | 5 +++-- 5 files changed, 15 insertions(+), 13 deletions(-) diff --git a/README.md b/README.md index 31a9835..41872a3 100644 --- a/README.md +++ b/README.md @@ -119,12 +119,12 @@ sudo sysctl vm.nr_hugepages=3072 4. Check that ports 18080 (Monero p2p port) and 37889/37888 (P2Pool/P2Pool mini p2p port) are open in your local firewall to ensure better connectivity. 5. Start `monerod` with the following command/options: ``` -./monerod --zmq-pub tcp://127.0.0.1:18083 --out-peers 64 --in-peers 32 --add-priority-node=p2pmd.xmrvsbeast.com:18080 --add-priority-node=nodes.hashvault.pro:18080 --disable-dns-checkpoints --enable-dns-blocklist +./monerod --zmq-pub tcp://127.0.0.1:18083 --out-peers 32 --in-peers 64 --add-priority-node=p2pmd.xmrvsbeast.com:18080 --add-priority-node=nodes.hashvault.pro:18080 --disable-dns-checkpoints --enable-dns-blocklist ``` **Note:** The `--zmq-pub` option is required for P2Pool to work properly. -`--out-peers 64 --in-peers 32` is needed to (1) have many connections to other nodes and (2) limit incoming connection count because it can grow uncontrollably and cause problems when it goes above 1000 (open files limit in Linux). If your network connection's **upload** bandwidth is less than **10 Mbit**, use `--out-peers 16 --in-peers 8` instead. +`--out-peers 32 --in-peers 64` is needed to (1) have many connections to other nodes and (2) limit incoming connection count because it can grow uncontrollably and cause problems when it goes above 1000 (open files limit in Linux). If your network connection's **upload** bandwidth is less than **10 Mbit**, use `--out-peers 8 --in-peers 16` instead. `--add-priority-node=p2pmd.xmrvsbeast.com:18080 --add-priority-node=nodes.hashvault.pro:18080` is needed to have guaranteed good working nodes in your connected peers. @@ -187,12 +187,12 @@ nocreate 8. Start `monerod` with the following command/options: ``` -.\Monero\monerod.exe --zmq-pub tcp://127.0.0.1:18083 --out-peers 64 --in-peers 32 --add-priority-node=p2pmd.xmrvsbeast.com:18080 --add-priority-node=nodes.hashvault.pro:18080 --disable-dns-checkpoints --enable-dns-blocklist +.\Monero\monerod.exe --zmq-pub tcp://127.0.0.1:18083 --out-peers 32 --in-peers 64 --add-priority-node=p2pmd.xmrvsbeast.com:18080 --add-priority-node=nodes.hashvault.pro:18080 --disable-dns-checkpoints --enable-dns-blocklist ``` **Note:** The `--zmq-pub` option is required for P2Pool to work properly. -`--out-peers 64 --in-peers 32` is needed to (1) have many connections to other nodes and (2) limit incoming connection count because it can grow uncontrollably and cause problems when it goes above 1000 (open files limit in Linux). If your network connection's **upload** bandwidth is less than **10 Mbit**, use `--out-peers 16 --in-peers 8` instead. +`--out-peers 32 --in-peers 64` is needed to (1) have many connections to other nodes and (2) limit incoming connection count because it can grow uncontrollably and cause problems when it goes above 1000 (open files limit in Linux). If your network connection's **upload** bandwidth is less than **10 Mbit**, use `--out-peers 8 --in-peers 16` instead. `--add-priority-node=p2pmd.xmrvsbeast.com:18080 --add-priority-node=nodes.hashvault.pro:18080` is needed to have guaranteed good working nodes in your connected peers. @@ -218,7 +218,7 @@ The `--zmq-pub` option is required for P2Pool to work properly. 13. *(Optional but highly recommended)* You can create a Quickstart by creating a batch (.bat) file with the following contents and placing it in your P2Pool directory along with `xmrig.exe`. ``` @ECHO OFF -start cmd /k %~dp0\Monero\monerod.exe --zmq-pub tcp://127.0.0.1:18083 --out-peers 64 --in-peers 32 --add-priority-node=p2pmd.xmrvsbeast.com:18080 --add-priority-node=nodes.hashvault.pro:18080 --disable-dns-checkpoints --enable-dns-blocklist +start cmd /k %~dp0\Monero\monerod.exe --zmq-pub tcp://127.0.0.1:18083 --out-peers 32 --in-peers 64 --add-priority-node=p2pmd.xmrvsbeast.com:18080 --add-priority-node=nodes.hashvault.pro:18080 --disable-dns-checkpoints --enable-dns-blocklist ECHO Wait until the Monero daemon shows fully synced before continuing. This can take some time. Type 'status' in other window to check progress. PAUSE start cmd /k %~dp0\p2pool.exe --wallet YOUR_WALLET_ADDRESS --mini diff --git a/docker-compose/cfg/docker-compose.jinja2 b/docker-compose/cfg/docker-compose.jinja2 index 129c048..8dbf91f 100644 --- a/docker-compose/cfg/docker-compose.jinja2 +++ b/docker-compose/cfg/docker-compose.jinja2 @@ -120,8 +120,8 @@ services: --zmq-pub tcp://0.0.0.0:18083 --disable-dns-checkpoints --enable-dns-blocklist - --out-peers 32 - --in-peers 16 + --out-peers 16 + --in-peers 32 --add-priority-node=nodes.hashvault.pro:18080 --add-priority-node=p2pmd.xmrvsbeast.com:18080 --non-interactive diff --git a/docker-compose/docker-compose.yml b/docker-compose/docker-compose.yml index e1ba153..73e0461 100644 --- a/docker-compose/docker-compose.yml +++ b/docker-compose/docker-compose.yml @@ -96,8 +96,8 @@ services: --zmq-pub tcp://0.0.0.0:18083 --disable-dns-checkpoints --enable-dns-blocklist - --out-peers 32 - --in-peers 16 + --out-peers 16 + --in-peers 32 --add-priority-node=nodes.hashvault.pro:18080 --add-priority-node=p2pmd.xmrvsbeast.com:18080 --non-interactive diff --git a/docs/html/index.html b/docs/html/index.html index 6f101ab..5737ebf 100644 --- a/docs/html/index.html +++ b/docs/html/index.html @@ -248,8 +248,8 @@ It's highly recommended to create a new wallet for mining because wallet address @@ -267,6 +267,7 @@ It's highly recommended to create a new wallet for mining because wallet address
  • Once P2Pool sync is complete, XMRig should be able to connect to the stratum server on port 3333
  • Run ./xmrig -o 127.0.0.1:3333. Note that you don't need to specify wallet address for xmrig. Wallet address set in xmrig config will be ignored!
  • To set custom fixed difficulty for your miner (for example, 10000), run ./xmrig -u x+10000 -o 127.0.0.1:3333 +
  • To connect another mining rig to your P2Pool node, run ./xmrig -o YOUR_P2POOL_NODE_IP:3333 on that mining rig
    Checking your progress diff --git a/docs/html/mini/index.html b/docs/html/mini/index.html index 9bdcfbe..0acc279 100644 --- a/docs/html/mini/index.html +++ b/docs/html/mini/index.html @@ -248,8 +248,8 @@ It's highly recommended to create a new wallet for mining because wallet address
    • Download the latest Monero release
    • [Optional] Open port 18080 (Monero p2p port) in your firewall to ensure better connectivity -
    • Run ./monerod --zmq-pub tcp://127.0.0.1:18083 --out-peers 64 --in-peers 32 --add-priority-node=p2pmd.xmrvsbeast.com:18080 --add-priority-node=nodes.hashvault.pro:18080 --disable-dns-checkpoints --enable-dns-blocklist -
    • If your network connection's upload bandwidth is less than 10 Mbit, use --out-peers 16 --in-peers 8 instead. +
    • Run ./monerod --zmq-pub tcp://127.0.0.1:18083 --out-peers 32 --in-peers 64 --add-priority-node=p2pmd.xmrvsbeast.com:18080 --add-priority-node=nodes.hashvault.pro:18080 --disable-dns-checkpoints --enable-dns-blocklist +
    • If your network connection's upload bandwidth is less than 10 Mbit, use --out-peers 8 --in-peers 16 instead.
    • Wait until it's fully synchronized. If you didn't run Monero node before, it can take up to several days to synchronize (5-6 hours on a modern PC with fast SSD and fast Internet connection). You can add --prune-blockchain argument to the command line to run a pruned node (3-4 times less disk usage)
    @@ -267,6 +267,7 @@ It's highly recommended to create a new wallet for mining because wallet address
  • Once P2Pool sync is complete, XMRig should be able to connect to the stratum server on port 3333
  • Run ./xmrig -o 127.0.0.1:3333. Note that you don't need to specify wallet address for xmrig. Wallet address set in xmrig config will be ignored!
  • To set custom fixed difficulty for your miner (for example, 10000), run ./xmrig -u x+10000 -o 127.0.0.1:3333 +
  • To connect another mining rig to your P2Pool node, run ./xmrig -o YOUR_P2POOL_NODE_IP:3333 on that mining rig
    Checking your progress From 837a33480e8181680d0d207ac14c39cf5b9f6b7e Mon Sep 17 00:00:00 2001 From: SChernykh Date: Tue, 31 Oct 2023 12:32:36 +0100 Subject: [PATCH 3/3] p2pool v3.8 --- src/util.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/util.h b/src/util.h index 8f47f72..10bbdac 100644 --- a/src/util.h +++ b/src/util.h @@ -35,7 +35,7 @@ namespace p2pool { #define P2POOL_VERSION_MAJOR 3 -#define P2POOL_VERSION_MINOR 7 +#define P2POOL_VERSION_MINOR 8 #define P2POOL_VERSION_PATCH 0 extern const char* VERSION;