From f1165c418aeed7f3c74c928d512a31f83aa0a28f Mon Sep 17 00:00:00 2001 From: buffalu <85544055+buffalu@users.noreply.github.com> Date: Wed, 10 Apr 2024 13:59:02 -0500 Subject: [PATCH] Add logs for ip:port (#123) --- core/src/tpu.rs | 4 +--- transaction-relayer/src/main.rs | 19 ++++++++++++++++++- 2 files changed, 19 insertions(+), 4 deletions(-) diff --git a/core/src/tpu.rs b/core/src/tpu.rs index 0dc86ca8..b78d89c7 100644 --- a/core/src/tpu.rs +++ b/core/src/tpu.rs @@ -19,9 +19,7 @@ use solana_core::{ }; use solana_sdk::{pubkey::Pubkey, signature::Keypair}; use solana_streamer::{ - nonblocking::quic::DEFAULT_WAIT_FOR_CHUNK_TIMEOUT, - quic::{spawn_server, MAX_STAKED_CONNECTIONS}, - streamer::StakedNodes, + nonblocking::quic::DEFAULT_WAIT_FOR_CHUNK_TIMEOUT, quic::spawn_server, streamer::StakedNodes, }; use crate::{fetch_stage::FetchStage, staked_nodes_updater_service::StakedNodesUpdaterService}; diff --git a/transaction-relayer/src/main.rs b/transaction-relayer/src/main.rs index 230f4750..cf983d40 100644 --- a/transaction-relayer/src/main.rs +++ b/transaction-relayer/src/main.rs @@ -352,7 +352,24 @@ fn main() { assert!(args.grpc_bind_ip.is_ipv4(), "must bind to IPv4 address"); let sockets = get_sockets(&args); - info!("Relayer listening at: {sockets:?}"); + + // make sure to allow your firewall to accept UDP packets on these ports + // if you're using staked overrides, you can provide one of these addresses + // to --rpc-send-transaction-tpu-peer + for s in &sockets.tpu_sockets.transactions_quic_sockets { + info!( + "TPU quic socket is listening at: {}:{}", + public_ip.to_string(), + s.local_addr().unwrap().port() + ); + } + for s in &sockets.tpu_sockets.transactions_forwards_quic_sockets { + info!( + "TPU forward quic socket is listening at: {}:{}", + public_ip.to_string(), + s.local_addr().unwrap().port() + ); + } let keypair = Arc::new(read_keypair_file(args.keypair_path).expect("keypair file does not exist"));