Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Network Traffic on Default Interface #4440

Open
bw-solana opened this issue Jan 13, 2025 · 6 comments
Open

Network Traffic on Default Interface #4440

bw-solana opened this issue Jan 13, 2025 · 6 comments
Assignees

Comments

@bw-solana
Copy link

Problem

Even after setting bind-address and gossip-host to some other interface IP, some network egress appears to be sent from the bond0 interface during startup. This subsequently results in traffic being received on this interface.

It is desired to be able to route all traffic to be sent from a specified interface.

Likely related to how this works: https://github.com/anza-xyz/agave/blob/v2.1.7/net-utils/src/lib.rs#L104-L109

Proposed Solution

Need to debug where traffic is originating from and send it from a specified interface. Could piggy back on the bind-address param or create something new, depending on what is appropriate after root cause.

@alexpyattaev alexpyattaev self-assigned this Jan 13, 2025
@alexpyattaev
Copy link

Metrics traffic seems to go from default gateway no matter what is in bind-address

@bw-solana
Copy link
Author

Metrics traffic seems to go from default gateway no matter what is in bind-address

good catch!

Main thing we'll need to update is this:
https://github.com/anza-xyz/agave/blob/master/metrics/src/metrics.rs#L147-L149

to add something like .local_address("".parse().unwrap())

We also have shell scripts, but I think this is more for testing:
https://github.com/anza-xyz/agave/blob/master/scripts/metrics-write-datapoint.sh will have the kernel pick the interface.

need something like --local-address <bind address>

@alexpyattaev
Copy link

alexpyattaev commented Jan 16, 2025

Assembled a test setup with 2 nodes (bootstrap and 1 validator) with two network interfaces. Specified the bind address for agave in both cases. No traffic found on bond0.

There are some irregularities though, there are a few open listen ports on all interfaces:
UDP 8003 (solana-quic-client)
3 dynamic UDP ports (still tracking down why they are opened there)

@alexpyattaev
Copy link

Ok so to trigger the bug the cluster entrypoint needs to be NOT in the DZ network.

@alexpyattaev
Copy link

alexpyattaev commented Jan 17, 2025

Identified bind on port 8003 -

fn create_endpoint(&self) -> Endpoint {

 solana_quic_client::nonblocking::quic_client] Local endpoint is : UdpSocket { addr: 0.0.0.0:8003, fd: 29 }

@alexpyattaev
Copy link

Need to also test that transactions made via RPC work correctly

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants