Hi. I need help to understand how to work with dhcp relay (ip helper).
I need to set-up the net with two different DHCP servers. The first one is for the WiFi and is an AC controller (it gives the ip address to AP and STA connected), the second one is a PC with a linux system in a virtual machine (windows server 2012 the Host) that is also the gateway. So, how to use the ip helper command. I think I need to use the per vlan ip helper becouse I want the AC working on vlan 2. I wonder how the vlan 1 can give dhcp response to vlan 10. Thanks in advance.
The topology is:
+-----------------+ +--------------------+
|DHCP SERVER | |DHCP SERVER |
|192.168.0.75 | |192.168.2.254 |
| LINUX | |AC CONTROLLER|
+-----------------+ +-------------------+
| |
| |
+-----------------------------------+
|192.168.0.253 192.168.2.253|
| VLAN 1 VLAN 2 |
|OS 6450 |
| VLAN 10 |
| 192.168.10.1 |
+-----------------------------------+
|
|
+-----------------+
| DHCP CLIENT |
| 192.168.10.X |
+------------------+
I start with a configuration like this:
!========================================!
! File: /flash/working/boot.cfg !
!========================================!
! Stack Manager :
! Chassis :
system daylight savings time disable
! Configuration:
! VLAN :
vlan 1 enable name "VLAN 1"
vlan 2 enable name "VLAN 2"
vlan 2 port default 1/1
vlan 2 port default 1/2
vlan 2 port default 1/3
vlan 2 port default 1/4
vlan 2 port default 1/5
vlan 2 port default 1/6
vlan 2 port default 1/7
vlan 2 port default 1/8
vlan 2 port default 1/9
vlan 2 port default 1/10
vlan 2 port default 1/11
vlan 2 port default 1/12
vlan 2 port default 1/13
vlan 2 port default 1/14
vlan 2 port default 1/15
vlan 2 port default 1/16
vlan 2 port default 1/17
vlan 2 port default 1/18
vlan 2 port default 1/19
vlan 2 port default 1/20
vlan 2 port default 1/22
vlan 2 port default 1/24
! VLAN SL:
! IP :
ip service all
ip interface "VLAN 1" address 192.168.0.253 mask 255.255.255.0 vlan 1 ifindex 1
ip interface "vlan_2" address 192.168.2.253 mask 255.255.255.0 vlan 2 ifindex 2
! IPMS :
! AAA :
aaa authentication default "local"
aaa authentication console "local"
aaa authentication telnet "local"
aaa authentication ftp "local"
aaa authentication ssh "local"
! PARTM :
! 802.1x :
! QOS :
! Policy manager :
! Session manager :
session prompt default "SwitchAlcatel->"
! SNMP :
! RIP :
! OSPF :
! ISIS :
! IPv6 :
! IP multicast :
! IPRM :
ip static-route 0.0.0.0/0 gateway 192.168.0.75 metric 1
! RIPng :
! OSPF3 :
! BGP :
! Health monitor :
health threshold temperature 78
! Interface :
! Udld :
! Port Mapping :
! Link Aggregate :
! VLAN AGG:
! 802.1Q :
! Spanning tree :
bridge mode 1x1
! Bridging :
! Bridging :
! Port mirroring :
! UDP Relay :
! System service :
swlog console level info
! SSH :
! VRRP :
! Web :
! AMAP :
! Lan Power :
lanpower start 1
! NTP :
! RDP :
! VLAN STACKING:
! EFM-OAM :
! SAA :
! Loopback-detection :
! ERP :
! TEST-OAM :
! PPPOE-IA :
! DHL :
! LLDP :
! DHCP Server :
! Stack Split-Protection Helper :
! Openflow :
! DHCPv6 :
! TWAMP :
How to configure different DHCP Servers
Re: How to configure different DHCP Servers
correct - you need ip helper per vlan.
This means different vlans for dhcp clients. F.e. server 1 for clients in vlan 10 und server 2 for clients in vlan 11 and 12. The vlans of the servers are not important. The ip helper (your switch) has an ip interface in all client vlans. The ip helper adds this address to the dhcp discover/request (relay agent IP). So the server knows the correct dhcp range where the request was started and offers an appropriate ip address. But not all dhcp servers deal correct with this option. Microsoft server uses this relay info correctly.
regards
Silvio
This means different vlans for dhcp clients. F.e. server 1 for clients in vlan 10 und server 2 for clients in vlan 11 and 12. The vlans of the servers are not important. The ip helper (your switch) has an ip interface in all client vlans. The ip helper adds this address to the dhcp discover/request (relay agent IP). So the server knows the correct dhcp range where the request was started and offers an appropriate ip address. But not all dhcp servers deal correct with this option. Microsoft server uses this relay info correctly.
regards
Silvio
Re: How to configure different DHCP Servers
Thanks. Just to be sure. Is it correct to do:
ip helper per-vlan only
ip helper address 192.168.0.75 vlan 10
In the linux dhcp client I've to configure an ip address with 192.168.10.75. Could be the solution?
ip helper per-vlan only
ip helper address 192.168.0.75 vlan 10
In the linux dhcp client I've to configure an ip address with 192.168.10.75. Could be the solution?
Re: How to configure different DHCP Servers
yes - config okay. but no config at the dhcp client ....
In your example is 192.168.0.75 the dhcp server for all clients in vlan 10. The server itself has only ONE ip address (...0.75).
If the net for vlan 10 is 192.168.10.0/24 (your L3-switch knows this net for this vlan) you need at the dhcp server the range f.e. 192.168.10.10-250 (or static entries).
regards
Silvio
In your example is 192.168.0.75 the dhcp server for all clients in vlan 10. The server itself has only ONE ip address (...0.75).
If the net for vlan 10 is 192.168.10.0/24 (your L3-switch knows this net for this vlan) you need at the dhcp server the range f.e. 192.168.10.10-250 (or static entries).
regards
Silvio
Re: How to configure different DHCP Servers
I've changed my mind. Do you think is a good idea to use the internal DHCP server of OS? It doesn't seem to be difficult to set up.
I'm thinking to set up with this configuration file:
#IP subnet
subnet 192.168.10.0 netmask 255.255.255.0
{
#Dynamic scope and parameters that apply to this scope overriding global params.
dynamic-dhcp range 192.168.10.100 192.168.10.130
{
option routers 192.168.10.253;
option subnet-mask 255.255.255.0;
option domain-name “scope_example.com";
option domain-name-servers 8.8.8.8 8.8.4.4;
option dhcp-lease-time 30000;
}
#Static binding based on MAC address
manual-dhcp 00-01-02-03-04-05 192.168.10.140
{
option subnet-mask 255.255.255.0;
}
}
Also I need some static ip. Have I to repeat all the option for any static IP? I need to put at least 40 static IP.
Thanks.
I'm thinking to set up with this configuration file:
#IP subnet
subnet 192.168.10.0 netmask 255.255.255.0
{
#Dynamic scope and parameters that apply to this scope overriding global params.
dynamic-dhcp range 192.168.10.100 192.168.10.130
{
option routers 192.168.10.253;
option subnet-mask 255.255.255.0;
option domain-name “scope_example.com";
option domain-name-servers 8.8.8.8 8.8.4.4;
option dhcp-lease-time 30000;
}
#Static binding based on MAC address
manual-dhcp 00-01-02-03-04-05 192.168.10.140
{
option subnet-mask 255.255.255.0;
}
}
Also I need some static ip. Have I to repeat all the option for any static IP? I need to put at least 40 static IP.
Thanks.
Re: How to configure different DHCP Servers
this is possible. But you can't use the same switch as dhcp server and as ip helper.
regards
Silvio
regards
Silvio
Re: How to configure different DHCP Servers
In fact. I will use only as dhcp server. Thanks.
And what about the static ip options? Can I list all the manual-dhcp and one list op dhcp option?
Bye.
And what about the static ip options? Can I list all the manual-dhcp and one list op dhcp option?
Bye.
Re: How to configure different DHCP Servers
yes. you will find in network guide some examples.
regards
Silvio
regards
Silvio