[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:
> Subnet mask:
> Gateway:
>> IP Address is in a different subnet as the gateway
>> address

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 which means that your gateway *is* in your subnet.
You will loose connectivity to -
and - but these are just other cable
modem subscribers.
Depending on the ability to set static routes on your WRT
you might even be able to restore connectivity 
by adding static routes for and 
to, which means the longest prefix wins.

Another possibility is to add a static ARP entry for with the MAC address of the
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
what counts.
(I'm in a similar situation with my ADSL link, being
PPPoA inside, and being issued with
a net 10 address as default router so I'm using the
tricks mentioned above as well).


Geert Jan

More information about the afnog mailing list