Question about DHCP

Discussion in 'Server Operation' started by paulley, Aug 25, 2010.

  1. paulley

    paulley New Member

    Hi everyone,


    I am setting up a dhcp server with 2 nics and having 2 dhcp scopes for 2 vlans i have got. My question is when setting this up with the following code:

    Code:
    subnet 192.168.1.0 netmask 255.255.255.0
    {
    range;
    option subnet-mask ;
    option broadcast-address ;
    option domain-name ;
    option domain-name-servers ;
    option routers ;
    
    #Binding IP to individual hosts so that they get fixed IP 
    host test01
    {
    option host-name ;
    hardware ethernet ;
    fixed-address ;
    }
    
    host test02
    {
    hardware ethernet ;
    fixed-address ;
    }
    }
    
    subnet 10.10.1.0 netmask 255.0.0.0
    {
    range 10.10.1.10 10.10.1.20;
    
    option subnet-mask;
    option broadcast-address ;
    option domain-name ;
    option domain-name-servers ;
    option routers ;
    
    }
    
    

    how does the dhcp server know what nic to use for each subnet above, as there is no mention about what nic eg. eth0 eth1 each scope will use. Just a guess is it because each nic will be assigned with a static ip etc so the dhcp server sees the ip per nic eg. eth0 is 192.168.1.2 and the subnet dhcp scope is say 192.168.1.0 so the dhcp server know the static ip on eth0 is on the 192.168.1.x subnet so thats the nic it uses. Is this correct!!!!!



    Many thanks for any info about this
     

Share This Page