classing gateway
Simon Hobson
dhcp1 at thehobsons.co.uk
Thu Dec 16 12:39:00 UTC 2010
marco perugini wrote:
>i've my pool [10.0.0.0/24] and there are two different gw that forward
>dhcpdiscover to my server:
>DHCPDISCOVER from XX:XX:XX:XX:XX:XX: via 192.168.2.101
>DHCPDISCOVER from XX:XX:XX:XX:XX:XY: via 192.168.98.201
>so i want to split my pool to assign range 10.0.0.1 - 10.0.0.127 to
>192.168.2.101's requests and the other half to 192.168.98.201's; how can
>i class the gateways in dhcpd.conf? does anyone know what i have to match?
What are you trying to achieve ? What is your network topology ?
Neither of those IPs is a valid address in the 10.0.0.0/24 subnet, so
nethier is actually valid as a gateway in 10.0.0.0/14, 10.0.0.0/25,
or 10.0.0.128/25.
But if you mean you have two gateways, each of which serves a
separate network, and :
192.168.2.w/x is to be a shared network with 10.0.0.0/25
and
192.168.98.y/z is to be a shared network with 10.0.0.128/25
then all you need to do is declare the shared networks properly and
the rest is automagic.
So why the shared networks ?
Just to be sure we understand each other. A shared network is where
one collision domain (a physical network where devices can talk
directly to each other without a router) has more than one IP subnet
assigned on it.
The config option for this is shared-network and is used like this :
shared-network "x" {
... <shared-network specific options>
subnet 192.168.2.0 ... {
... <subnet specific options>
}
subnet 10.0.0.0 subnet mask 255.255.255.128 {
...
}
}
Also note that you cannot use 10.0.0.1 to 10.0.0.127 in a range in a
/25 subnet. .127 is the broadcast address and so is not usable, and
you MUST have a router in the subnet so that will require an IP
address.
So you might put the router on 10.0.0.1 and use 10.0.0.2 to
10.0.0.126 for your pool.
--
Simon Hobson
Visit http://www.magpiesnestpublishing.co.uk/ for books by acclaimed
author Gladys Hobson. Novels - poetry - short stories - ideal as
Christmas stocking fillers. Some available as e-books.
More information about the dhcp-users
mailing list