Opened 6 years ago

Closed 9 months ago

#14982 closed bug (not reproducible)

Kills Host Networking when running in VirtualBox

Reported by: AGMS Owned by: axeld
Priority: normal Milestone: Unscheduled
Component: Network & Internet/IPv4 Version: R1/Development
Keywords: Cc: agmsmith@…
Blocked By: Blocking:
Platform: All

Description

Recent nightlies (hrev53001 and others after Beta 1) when running in VirtualBox kill the host networking somehow, by adding a packet that says the destination is unreachable. Stopping the Haiku VM (or just turning off networking in Haiku) resumes normal functionality.

Here's what a ping command looks like when running in the host (Fedora 29 Linux), the problems happen when Haiku networking starts working:

ping www.google.com
PING www.google.com (172.217.13.132) 56(84) bytes of data.
64 bytes from yul02s05-in-f4.1e100.net (172.217.13.132): icmp_seq=1 ttl=54 time=15.9 ms
...
64 bytes from yul02s05-in-f4.1e100.net (172.217.13.132): icmp_seq=28 ttl=54 time=24.0 ms
64 bytes from yul02s05-in-f4.1e100.net (172.217.13.132): icmp_seq=29 ttl=54 time=8.15 ms
From yul02s05-in-f4.1e100.net (172.217.13.132) icmp_seq=30 Destination Host Unreachable
64 bytes from yul02s05-in-f4.1e100.net (172.217.13.132): icmp_seq=30 ttl=54 time=85.10 ms
From yul02s05-in-f4.1e100.net (172.217.13.132) icmp_seq=31 Destination Host Unreachable
...

It looks like Haiku is sending a spurious reply ICMP packet with a destination host unreachable error code. That mixes in with the real reply to the ping. Not a big problem if you are just pinging, but in particular TCP is affected so web browsing stops working, etc. Though BitTorrent transfers keep on going (they use their own packet protocol).

However, other real computers on the network work fine, and other VMs keep on running too.

Happens with VBox set up for bridged networking (not VBox NAT mode); dynamic address assigned by the normal LAN DHCP server. Running an emulated Intel PRO/1000 MT Desktop (82540EM) in promiscuous "allow all" mode.

I'll be investigating this a bit more; trying to bisect which hrev causes this problem (or discovering that it's something else :-).

Change History (10)

comment:1 by waddlesplash, 6 years ago

We haven't touched TCP or ICMP in quite a while, so if this is a recent regression that would be surprising. If you find a fix, that will be most welcome, of course :)

comment:2 by AGMS, 6 years ago

I've tracked it down to hrev52708 being broken, and hrev52707 working. That's the one where the new FreeBSD 12 networking stack and Intel iPro/1000 drivers were added.

It happens in VirtualBox running under both Fedora Linux and Windows 10.

All Intel emulated network cards are affected, and virtio-net too (pleasantly surprised to see it recognised by Haiku). However, the "PCnet-PCI II (Am79C970A)" emulation does work properly (no Host Unreachable problems). "PCnet-FAST III (Am79C973)" seems to work but Haiku freezes up after a while.

So, switch to the PCnet-PCI card and things work. Or use the faster (I assume) virtio-net and put up with your host computer's TCP stack being put out of action.

comment:3 by waddlesplash, 6 years ago

It's interesting that it worked on the old ipro1000 driver but not the new one. But if it's broken under virtio_net, then this is definitely a larger network stack issue in general.

comment:4 by AGMS, 6 years ago

Just noticed that those iPro1000 updates in hrev53085 didn't fix it.

comment:5 by waddlesplash, 6 years ago

As stated already, if it's a problem in virtio_net too, then the problem is the stack, not the drivers.

comment:6 by waddlesplash, 2 years ago

Please retest after hrev56180 and see if there are any differences.

comment:7 by AGMS, 2 years ago

Sorry for the delay; out of action for a few months with tummy troubles.

Verified that with VirtualBox 6.1.36 (July 2022), and Haiku 64 bit Intel hrev54154+123 and virtio-net ethernet adapter, the host Linux computer (Fedora 35) network does malfunction. Also fails for iPro1000 network adapter. So the VirtualBox people haven't changed anything.

Also for 32 bit Haiku, hrev55877 virtio-net, host networking malfunctions. But works for an emulated ipro1000 network adapter (hmmm, used to not work, something fixed for iPro1000 between hrev54154 and hrev55877).

Still happens for current day 32 bit Haiku hrev56301 and virtio-net. But doesn't happen for Intel iPro1000 network adapters. Same for 64 bit hrev56301: now works for iPro1000, fails for virtio-net.

comment:8 by waddlesplash, 9 months ago

Keywords: VikrtualBox Networking ICMP Host Unreachable removed

comment:9 by AGMS, 9 months ago

Looks like VirtualBox fixed something. I tested it again with 32 bit Haiku hrev56301 and virtio-net adapter, which previously caused problems, and now it works! Using VirtualBox 7.0.14 on Fedora 39.

comment:10 by waddlesplash, 9 months ago

Resolution: not reproducible
Status: newclosed
Note: See TracTickets for help on using tickets.