[afnog] IP Address is in a different subnet as the gateway
Geert Jan de Groot
GeertJan.deGroot at xs4all.nl
Thu Jul 3 07:28:48 UTC 2008
On Wed, 2 Jul 2008 15:26:12 -0700 (PDT) Hylante Tabiou-Malkaye wrote:
> I am trying a Linksys WRT50G wireless router at my home. My cable guy has
> given the IP address, Subnet mask and gateway as follows:
> IP Address: 10.249.10.26
> Subnet mask: 255.255.255.0
> Gateway: 10.249.8.1
>> IP Address 10.249.10.26 is in a different subnet as the gateway
>> address 10.249.8.1
As others suggested, your best bet is to have your ISP fix this by giving
you an IP inside your subnet. This gives the least chance of
problems in the future and should be the way forward.
The non-advised way to do this is to change your subnet mask to
255.255.252.0 which means that your gateway *is* in your subnet.
You will loose connectivity to 10.249.8.0 - 10.249.9.255
and 10.249.11.0 - 10.249.11.255 but these are just other cable
Depending on the ability to set static routes on your WRT
you might even be able to restore connectivity
by adding static routes for 10.249.8.0/23 and 10.249.11.0/24
to 10.249.8.1, which means the longest prefix wins.
Another possibility is to add a static ARP entry for
10.249.10.1 with the MAC address of the 10.249.8.1
cable modem MAC address. I suspect this will be the
cablemodem address since DOCSIS uses ATM inside
and your cable modem is playing ugly ARP spoof tricks
to make things work anyway. Mind you, if modem MAC address changes,
you'll need to redo this config.
Keep in mind that the only thing that matters is
to have *an* IP for the next hop, and a MAC address
matching that IP so that packets make it to the next hop,
after which they are no longer ethernet anyway.
I should stress that none of these solutions scale,
all of them will give maintenance issues and heartburn,
but if it's what you need to get out, then that's
(I'm in a similar situation with my ADSL link, being
PPPoA inside, and being issued 126.96.36.199/32 with
a net 10 address as default router so I'm using the
tricks mentioned above as well).
More information about the afnog