Freebsd 15 ICMP issue

Hello,

I am rookie in Freebsd, currently installed Freebsd 15 trough Virtualbox to test some stuff like monitoring software.

I've noticed i cannot ping outside of my LAN. Currently on bridged adapter, switched from Adapter type: Intel PRO/1000 MT Desktop (82540EM) to Paravirtualized Network (virtio-net) with both i couldnt get pinging to work from outside my LAN. Tried with NAT and still theres no resolve to this issue.

Internet is working on the Freebsd i can do fetch and it works, my monitoring tool nagios i changed the commands to check_tcp instead of ping and it works, i just cannot understand why i cannot ping from the freebsd itself. I have not done anything in the firewall and its off.
Currently on paravirtualized:
netstat -rn
Routing tables

Internet:
Destination Gateway Flags Netif Expire
default 192.168.0.1 UGS vtnet0
127.0.0.1 link#2 UH lo0
192.168.0.0/24 link#1 U vtnet0
192.168.0.158 link#2 UHS lo0


tcpdump -n -i vtnet0 icmp
tcpdump: verbose output suppressed, use -v[v]... for full protocol decode
listening on vtnet0, link-type EN10MB (Ethernet), snapshot length 262144 bytes
05:35:20.880041 IP 192.168.0.158 > 8.8.8.8: ICMP echo request, id 19737, seq 0, length 64
05:35:21.946071 IP 192.168.0.158 > 8.8.8.8: ICMP echo request, id 19737, seq 1, length 64
05:35:23.018665 IP 192.168.0.158 > 8.8.8.8: ICMP echo request, id 19737, seq 2, length 64

Tried - ifconfig vtnet0 -rxcsum -txcsum -tso -lro still nothing.

nc -vz 8.8.8.8 53
Connection to 8.8.8.8 53 port [tcp/domain] succeeded!

cat /etc/rc.conf
ifconfig_vtnet0="DHCP"
#ifconfig_em0_ipv6="inet6 accept_rtadv"
 
Then the issue is on the host or your router. Not the FreeBSD guest. Can you ping the default gateway address?
Yes i do have ping to my local home network:

PING 192.168.0.1 (192.168.0.1): 56 data bytes
64 bytes from 192.168.0.1: icmp_seq=0 ttl=64 time=0.825 ms
64 bytes from 192.168.0.1: icmp_seq=1 ttl=64 time=0.728 ms
64 bytes from 192.168.0.1: icmp_seq=2 ttl=64 time=1.537 ms
64 bytes from 192.168.0.1: icmp_seq=3 ttl=64 time=0.912 ms

cat /etc/resolv.conf
# Generated by resolvconf
nameserver 192.168.0.1

I've tried with nameserver 1.1.1.1 and 8.8.8.8 for both resolvconf and dhclient.conf but it didn't work so i changed it back to as how it was when i installed the Freebsd with 192.168.0.1 as DNS.

cat /etc/dhclient.conf
supersede domain-name-servers 192.168.0.1;


On my windows i can ping outside my network like for example 8.8.8.8 or anything else. Also installed ubuntu not long ago and it was working fine with the ICMP. Im i doing something wrong?

Routing tables

Internet:
Destination Gateway Flags Netif Expire
default 192.168.0.1 UGS vtnet0
127.0.0.1 link#2 UH lo0
192.168.0.0/24 link#1 U vtnet0
192.168.0.158 link#2 UHS lo0


192.168.0.158 is my vtnet0


ifconfig
vtnet0: flags=1008843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST,LOWER_UP> metric 0 mtu 1500
options=ec07bb<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,JUMBO_MTU,VLAN_HWCSUM,TSO4,TSO6,LRO,VLAN_HWTSO,LINKSTATE,RXCSUM_IPV6,TXCSUM_IPV6,HWSTATS>
inet 192.168.0.158 netmask 0xffffff00 broadcast 192.168.0.255
media: Ethernet autoselect (10Gbase-T <full-duplex>)
status: active
nd6 options=29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>

lo0: flags=1008049<UP,LOOPBACK,RUNNING,MULTICAST,LOWER_UP> metric 0 mtu 16384
options=680003<RXCSUM,TXCSUM,LINKSTATE,RXCSUM_IPV6,TXCSUM_IPV6>
inet 127.0.0.1 netmask 0xff000000
inet6 ::1 prefixlen 128
inet6 fe80::1%lo0 prefixlen 64 scopeid 0x2
groups: lo
nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
 
I've tried with nameserver 1.1.1.1 and 8.8.8.8 for both resolvconf and dhclient.conf but it didn't work so i changed it back to as how it was when i installed the Freebsd with 192.168.0.1 as DNS.
Changing DNS settings isn't magically going make routing work.

Again, the issue is not on the FreeBSD guest. The FreeBSD guest can ping the gateway but nothing beyond that gateway, which means the problem is on the gateway itself.
 
Or a firewall that's blocking it, or the packets aren't NAT'ed and thrown onto the internet with an RFC1918 source address (so you will never receive the responses).

In any case, the local network works (you can ping the gateway and other hosts on your LAN), that means the FreeBSD guest is properly configured.
 
Thank you for the replies, it seems like there's a problem with the network in that case.

We can safely say that it is not Freebsd's fault and i should further investigate my own network.

I am not sure if the gateway uses PPPoE, the way i receive internet is trough optical cable and then a PON device (which i dont have credentials), then it is connected to my router with ftp cable - configured dynamically and ive never had any routing issues like i said every other host can ping except Freebsd this is why i wanted to maybe ask if theres something needed to be configured in that case.

I have disabled windows firewall for a moment to test but again i couldn't get it to work.

I will further investigate the problem but its pointing towards gateway issue, thanks again for the replies.
 
Back
Top