Skip to contentSkip to conversation

Not getting ICMP reports from the UDP socket in rxrpc

DISCUSSION David Howells 1 participant 2 messages Aug 26, 2022

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

Hi Eric,

Do you know if ICMP handling has changed inside of ipv4/ipv6? I've realised that though rxrpc tries to get ICMP events, they're not coming through.

rxrpc_open_socket() does:

	usk->sk_error_report = rxrpc_error_report;

to set the error collector and:

		ip6_sock_set_recverr(usk);
		ip_sock_set_recverr(usk);

as appropriate to say that it wants to get ICMP messages, but they don't seem to come. I put a printk() into sk_error_report(), but I don't see anything printed when ICMP messages come in (but I do if I telnet to a random port on my test server).

Thanks,
David

#1 lore raw
Quoted 9 lines · David Howells

Do you know if ICMP handling has changed inside of ipv4/ipv6? I've realised that though rxrpc tries to get ICMP events, they're not coming through.

rxrpc_open_socket() does:

	usk->sk_error_report = rxrpc_error_report;

to set the error collector and:

Quoted 7 lines
		ip6_sock_set_recverr(usk);
		ip_sock_set_recverr(usk);

as appropriate to say that it wants to get ICMP messages, but they don't seem to come. I put a printk() into sk_error_report(), but I don't see anything printed when ICMP messages come in (but I do if I telnet to a random port on my test server).

Ah... there's a separate error handling hook (encap_err_lookup) for tunnels. I guess I need that. Do you know if only ICMP/ICMP6 messages go through that and not other SO_EE_ORIGIN_* types?

David