Skip to content

Conversation

@willcl-ark
Copy link
Member

@willcl-ark willcl-ark commented Sep 3, 2022

Add some general guidance on lowering bandwidth usage when using I2P routers.

@ghost
Copy link

ghost commented Sep 3, 2022

Concept ACK

@DrahtBot DrahtBot added the Docs label Sep 3, 2022
@fanquake fanquake requested review from jonatack and vasild September 4, 2022 09:12
Copy link
Member

@jonatack jonatack left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some initial thoughts.

doc/i2p.md Outdated
Copy link
Member

@jonatack jonatack Sep 5, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
`transittunnels` options. For example to limit total I2P traffic to 256KB/s,
`transittunnels` options in the `i2pd/contrib/i2pd.conf` file. For example, to limit total I2P traffic to 256KB/s

Will test some of your recommendations, thanks!

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍🏼 I did test that disabling the transit traffic still permitted connections to and from the SAM proxy, and it worked between my two nodes. I also double checked on libera-chat#i2pd-dev that this is intended behaviour, and it is. So if you want only bitcoin traffic on your I2P proxy, you can disable everything else for ultimate minimum bandwidth-usage!

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think I might leave out the conf file path: 1) It might be in different locations for different people (e.g. /etc/i2pd/i2pd.conf or /var/lib/i2pd/i2pd.conf etc.) and 2) people might just be running with command line args.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggestions

 ## Bandwidth
 
-I2P routers may route a large amount of general network traffic with default
-settings enabled. Check your router's configuration to limit the amount of this
-traffic that is being relayed.
-
-For `i2pd` controlling the amount of bandwidth being shared with the wider
-network can be achieved by modifying the `bandwidth`, `share` and
-`transittunnels` options. For example to limit total I2P traffic to 256KB/s,
-and share 50% of this limit for a maximum of 20 transit tunnels you can use:
+I2P routers may route a large amount of general network traffic with their
+default settings. Check your router's configuration to limit the amount of
+traffic relayed, if desired.
+
+With `i2pd`, the amount of bandwidth shared with the wider network can be
+adjusted with the `bandwidth`, `share` and `transittunnels` options in
+`i2pd.conf`. For example, to limit I2P traffic to 256KB/s and share 50% of this
+limit for a maximum of 20 transit tunnels:

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think I might leave out the conf file path: 1) It might be in different locations for different people (e.g. /etc/i2pd/i2pd.conf or /var/lib/i2pd/i2pd.conf etc.) and 2) people might just be running with command line args.

Agree WRT the path. Maybe give the conf filename for both i2pd and i2p router or for neither.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe this is addressed here in response to vasild's comment.

Copy link
Member

@jonatack jonatack Sep 14, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe this is addressed here in response to vasild's comment.

How?

Mind having a look at #25993 (comment)? It would fix a few punctuation/grammar issues and improve clarity/brevity.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok I have adopted the changes from #25993 (comment)

How?

As the final clause now reads:

Similar bandwidth configuration options in the Java I2P router can be found in
the `http://127.0.0.1:7657/config`, under the "Bandwidth" tab.

Which I think, is roughly the equivalent of the i2p router conf file?

Copy link
Contributor

@vasild vasild left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The first commit looks ok (modulo the nits below). I am not sure about the second one - i2pd was tested and it worked with 2.35. Was it broken after 2.35 and then fixed in 2.42?

@willcl-ark
Copy link
Member Author

The first commit looks ok (modulo the nits below). I am not sure about the second one - i2pd was tested and it worked with 2.35. Was it broken after 2.35 and then fixed in 2.42?

Hmmm, I was trying on a totally fresh Debian install, and a not-so-fresh Ubuntu install. On Ubuntu apt served me 2.41 which worked. However Debain bullseye was serving me 2.36, which did not work, and resulted in crashing with log messages like this. Installing 2.41 did not seem to work, but I grabbed the 2.42 release and it just worked perfectly, so thought recommending this might be worthwhile.

@willcl-ark
Copy link
Member Author

  • Dropped the i2pd version recommendation for now, as it seems like this could be a system issue on my side.
  • Integrated spelling nits and added paragraph on where to find the bandwidth config from the Java router.

Copy link
Contributor

@vasild vasild left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK 27b9e098d163c292753cdd3df9cefefa28b648f8

@Rspigler
Copy link
Contributor

Rspigler commented Sep 6, 2022

Is i2pd used more often than the official I2p router? (that's what I use)

@willcl-ark
Copy link
Member Author

Is i2pd used more often than the official I2p router? (that's what I use)

Possibly....

@Rspigler
Copy link
Contributor

Rspigler commented Sep 6, 2022

I wasn't sure how I felt about giving implementation-specific directions, but I missed that you also gave them for the i2p router, which IMO covers the 2 major implementations, so Concept ACK from me. Sorry

Copy link
Contributor

@vasild vasild left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK 6119adcafd7b3379629ab64c2b0243a838900c24

@DrahtBot
Copy link
Contributor

DrahtBot commented Sep 23, 2022

The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

Conflicts

No conflicts as of last run.

Copy link
Member

@jonatack jonatack left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The PR description needs to be updated.

Adds some general guidance on lowering bandwidth usage when using I2P
routers.
@willcl-ark
Copy link
Member Author

The PR description needs to be updated.

Description updated and changes incorporated

Copy link
Member

@jonatack jonatack left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK 874c861

Thanks for updating!

can set the `notransit` option to `true`.

Similar bandwidth configuration options for the Java I2P router can be found in
`http://127.0.0.1:7657/config` under the "Bandwidth" tab.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ignore unless you need to retouch: dropping the backticks could make this a clickable URL.

Suggested change
`http://127.0.0.1:7657/config` under the "Bandwidth" tab.
http://127.0.0.1:7657/config under the "Bandwidth" tab.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @jonatack

Will indeed amend if I retouch.

Copy link
Contributor

@hernanmarino hernanmarino left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK 874c861

Copy link
Member

@pablomartin4btc pablomartin4btc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK 874c861.

Very useful info as I was testing I2P on v.24 a few weeks ago and I didn't know you could setup this options (bandwidth, share and transittunnels).

@fanquake fanquake merged commit 71abee8 into bitcoin:master Dec 5, 2022
sidhujag pushed a commit to syscoin/syscoin that referenced this pull request Dec 5, 2022
@bitcoin bitcoin locked and limited conversation to collaborators Dec 5, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants