Error Behind Keyboard causing No Route to Host when pinging WAN/Internet

Hi,

I've had FreeBSD (currently 12) running on an older AMD server for several years now. A few weeks back my Wifi router (and central router) died so I replaced it. The new router defaulted IP Addresses to 192.168.50.x, whereas I was running 192.168.1.x previously (both have cidr /24). Because most of my home network uses DHCP the transition was largely automatic, except for my FreeBSD server. "No problem" I says to myself. "I is smrt and goods at networkin'".

So, first I adjusted the IP address and for the main host (jail 0) in rc.conf:

Code:
russellh@sylvester:~> cat /etc/rc.conf
clear_tmp_enable="YES"
hostname="sylvester"
ifconfig_igb0="inet 192.168.50.2 netmask 255.255.255.0"
ifconfig_igb0_ipv6="inet6 accept_rtadv"
defaultrouter="192.168.50.1"
sshd_enable="YES"
powerd_enable="YES"
# Set dumpdev to "AUTO" to enable crash dumps, "NO" to disable
dumpdev="AUTO"
zfs_enable="YES"
iocell_enable="YES"

I was able to ping the new router without issue so I swaped over all my jails via iocell (note my complete failure as a systems engineer to check the WAN before continuing?). My main Ethernet adapter now looks like this:

Code:
russellh@sylvester:~> ifconfig igb0
igb0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
        options=e527bb<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,JUMBO_MTU,VLAN_HWCSUM,TSO4,TSO6,LRO,WOL_MAGIC,VLAN_HWFILTER,VLAN_HWTSO,RXCSUM_IPV6,TXCSUM_IPV6>
        ether 00:25:90:70:d3:70
        inet 192.168.50.2 netmask 0xffffff00 broadcast 192.168.50.255
        inet 192.168.50.6 netmask 0xffffff00 broadcast 192.168.50.255
        inet 192.168.50.8 netmask 0xffffff00 broadcast 192.168.50.255
        inet6 fe80::225:90ff:fe70:d370%igb0 prefixlen 64 scopeid 0x1
        media: Ethernet autoselect (1000baseT <full-duplex>)
        status: active
        nd6 options=23<PERFORMNUD,ACCEPT_RTADV,AUTO_LINKLOCAL>

All jails (and the host) can see and ping each other and other computers on the network as well as the main router that's connected to my cable modem. Internet access is fine with all my other computers and a static IP test on a different freebsd instance (ghostbsd actually) was successful. However, this is the result I get when ping testing from my FreeBSD server:

Code:
#First the default router
russellh@sylvester:~> ping 192.168.50.1
PING 192.168.50.1 (192.168.50.1): 56 data bytes
64 bytes from 192.168.50.1: icmp_seq=0 ttl=64 time=9.040 ms
64 bytes from 192.168.50.1: icmp_seq=1 ttl=64 time=6.045 ms
64 bytes from 192.168.50.1: icmp_seq=2 ttl=64 time=3.753 ms
64 bytes from 192.168.50.1: icmp_seq=3 ttl=64 time=4.721 ms
^C
--- 192.168.50.1 ping statistics ---
4 packets transmitted, 4 packets received, 0.0% packet loss
round-trip min/avg/max/stddev = 3.753/5.890/9.040/1.992 ms
#Now the WAN
russellh@sylvester:~> ping freebsd.org
PING freebsd.org (96.47.72.84): 56 data bytes
ping: sendto: No route to host
ping: sendto: No route to host
ping: sendto: No route to host
ping: sendto: No route to host
ping: sendto: No route to host
ping: sendto: No route to host
ping: sendto: No route to host
^C
--- freebsd.org ping statistics ---
7 packets transmitted, 0 packets received, 100.0% packet loss
russellh@sylvester:~> cat /etc/r
rc               rc.conf          rc.d/            rc.initdiskless  rc.sendmail      rc.subr          regdomain.xml    resolv.conf      rmt@
rc.bsdextended   rc.conf.d/       rc.firewall      rc.resume*       rc.shutdown      rc.suspend*      remote           resolv.conf.bak  rpc
russellh@sylvester:~> cat /etc/resolv.conf
search uniserve.com
nameserver 192.168.50.1

I am baffled. Can anyone suggest what I have forgotten/done wrong/failed to consider or otherwise flubbed?

Hat in Hand,
dinsdale
 
netstat -rn

ps.
if the default route is not 192.168.50.1 then
route add -net 0.0.0.0/0 192.168.50.1
or
route add default 192.168.50.1
 
What jumps out at me is the igb0 addresses. You are only supposed to have one broadcast address (the /24), everything else should be /32.
For example on a machine I have:

Code:
igb0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
    options=403bb<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,JUMBO_MTU,VLAN_HWCSUM,TSO4,TSO6,VLAN_HWTSO>
    ether 0c:c4:7a:01:e3:9c
    inet 10.1.1.6 netmask 0xffffff00 broadcast 10.1.1.255 
    inet 10.1.1.3 netmask 0xffffffff broadcast 10.1.1.3 
    inet 10.1.1.7 netmask 0xffffffff broadcast 10.1.1.7 
    inet 10.1.1.8 netmask 0xffffffff broadcast 10.1.1.8 
    inet 10.1.1.25 netmask 0xffffffff broadcast 10.1.1.25 
    inet 10.1.1.246 netmask 0xffffffff broadcast 10.1.1.246 
    nd6 options=29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>
    media: Ethernet autoselect (1000baseT <full-duplex>)
    status: active

So I would expect your's to read like this instead:
Code:
inet 192.168.50.2 netmask 0xffffff00 broadcast 192.168.50.255
inet 192.168.50.6 netmask 0xffffffff broadcast 192.168.50.6
inet 192.168.50.8 netmask 0xffffffff broadcast 192.168.50.8

Could you share the routing table also:
Code:
netstat -nr
 
Code:
russellh@sylvester:~> netstat -nr
Routing tables

Internet:
Destination        Gateway            Flags     Netif Expire
127.0.0.1          link#3             UH          lo0
192.168.50.0/24    link#1             U          igb0
192.168.50.2       link#1             UHS         lo0
192.168.50.6       link#1             UHS         lo0
192.168.50.8       link#1             UHS         lo0

Internet6:
Destination                       Gateway                       Flags     Netif Expire
::/96                             ::1                           UGRS        lo0
::1                               link#3                        UH          lo0
::ffff:0.0.0.0/96                 ::1                           UGRS        lo0
fe80::/10                         ::1                           UGRS        lo0
fe80::%igb0/64                    link#1                        U          igb0
fe80::225:90ff:fe70:d370%igb0     link#1                        UHS         lo0
fe80::%lo0/64                     link#3                        U           lo0
fe80::1%lo0                       link#3                        UHS         lo0
ff02::/16                         ::1                           UGRS        lo0
 
netstat -rn

ps.
if the default route is not 192.168.50.1 then
route add -net 0.0.0.0/0 192.168.50.1
or
route add default 192.168.50.1

route add default 192.168.50.1 instantly fixed the problem and it persists across reboot. Thank you!

Code:
russellh@sylvester:~> netstat -nr
Routing tables

Internet:
Destination        Gateway            Flags     Netif Expire
default            192.168.50.1       UGS        igb0
127.0.0.1          link#3             UH          lo0
192.168.1.0/24     link#1             U          igb0
192.168.1.3        link#1             UHS         lo0
192.168.50.0/24    link#1             U          igb0
192.168.50.2       link#1             UHS         lo0
192.168.50.6       link#1             UHS         lo0

Internet6:
Destination                       Gateway                       Flags     Netif Expire
::/96                             ::1                           UGRS        lo0
::1                               link#3                        UH          lo0
::ffff:0.0.0.0/96                 ::1                           UGRS        lo0
fe80::/10                         ::1                           UGRS        lo0
fe80::%igb0/64                    link#1                        U          igb0
fe80::225:90ff:fe70:d370%igb0     link#1                        UHS         lo0
fe80::%lo0/64                     link#3                        U           lo0
fe80::1%lo0                       link#3                        UHS         lo0
ff02::/16                         ::1                           UGRS        lo0
 
What jumps out at me is the igb0 addresses. You are only supposed to have one broadcast address (the /24), everything else should be /32.
For example on a machine I have:

Code:
igb0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
    options=403bb<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,JUMBO_MTU,VLAN_HWCSUM,TSO4,TSO6,VLAN_HWTSO>
    ether 0c:c4:7a:01:e3:9c
    inet 10.1.1.6 netmask 0xffffff00 broadcast 10.1.1.255
    inet 10.1.1.3 netmask 0xffffffff broadcast 10.1.1.3
    inet 10.1.1.7 netmask 0xffffffff broadcast 10.1.1.7
    inet 10.1.1.8 netmask 0xffffffff broadcast 10.1.1.8
    inet 10.1.1.25 netmask 0xffffffff broadcast 10.1.1.25
    inet 10.1.1.246 netmask 0xffffffff broadcast 10.1.1.246
    nd6 options=29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>
    media: Ethernet autoselect (1000baseT <full-duplex>)
    status: active

So I would expect your's to read like this instead:
Code:
inet 192.168.50.2 netmask 0xffffff00 broadcast 192.168.50.255
inet 192.168.50.6 netmask 0xffffffff broadcast 192.168.50.6
inet 192.168.50.8 netmask 0xffffffff broadcast 192.168.50.8

Could you share the routing table also:
Code:
netstat -nr

I seem to remember something about the broadcast ID's changing when I swapped things over, but the memory is fuzzy. I created each jail and the ip address using iocell using the example provided on their networking page:


iocell set ip4_addr="em0|10.1.1.10/24" UUID| TAG

What is the consequence of multiple broadcast routes? Perhaps I'll try switching one of them to /32 and see what happens...
 
remember that changing the routing table will not persists after the reboot unless you specify it in /etc/rc.conf
 
Back
Top