Folks,
I am trying to implement a DHCP server so that it can lease out IP address to the client in two subnets.
First subnet is 192.168.20.x
Second subnet is 192.168.30.x
Both these subnets are connected to Gig interfaces of a router, DHCP server is on 192.168.30.x network. DHCP works fine on 192.168.30.x as there are no vlans.
192.168.20.x is an issue, DHCP traffic doesn't seem to pass through the switch1.
Here I have a vlan created on a switch1 which doesn't seem to be able to pass the DHCP traffic which results in the clients behind the switch1 unable to acquire an IP address.
Router Config:
Building configuration...
Current configuration : 1648 bytes
!
version 15.1
service timestamps log datetime msec
service timestamps debug datetime msec
service password-encryption
!
hostname dhcprelay
!
login on-failure trap
login on-success log
!
!
enable password 7 0829454A0D1C0B464058
!
ip dhcp relay information trust-all
!
!
!
ip dhcp pool new
ip dhcp pool 123
!
!
!
ip cef
no ipv6 cef
!
!
!
!
license udi pid CISCO2911/K9 sn FTX15242S4X
!
!
!
lldp run
!
!
!
!
!
!
!
ip ftp username cisco
ip ftp password router
!
!
spanning-tree mode pvst
!
!
!
!
!
!
interface GigabitEthernet0/0
no ip address
duplex auto
speed auto
!
interface GigabitEthernet0/0.1000
encapsulation dot1Q 1000 native
ip address 192.168.20.254 255.255.255.0
ip helper-address 192.168.30.1
!
interface GigabitEthernet0/1
description "DHCP_Pool_Side"
ip address 192.168.30.254 255.255.255.0
ip helper-address 192.168.30.1
duplex auto
speed auto
!
interface GigabitEthernet0/2
no ip address
duplex auto
speed auto
shutdown
!
interface Vlan1
no ip address
shutdown
!
ip classless
!
ip flow-export version 9
!
!
!
banner login ^C THIS IS THE DHCP RELAY ROUTER $ PLEASE BE CAUTIOUS WHEN CHANGING ANY CONFIG ^C
banner motd ^C WELCOME TO THE DHCP RELAY ROUTER, DO NOT CHANGE ANY CONFIGS ^C
!
!
!
snmp-server community ROUTERCOM RW
snmp-server community router RW
!
logging trap debugging
logging 192.168.30.1
line con 0
!
line aux 0
!
line vty 0 4
session-limit 7
password 7 0829454A0D1C0B464058
logging synchronous
login
line vty 5 15
session-limit 7
password 7 0829454A0D1C0B464058
logging synchronous
login
!
!
ntp authentication-key 741852 md5 0876181F514C57 7
ntp server 192.168.30.1 key 0
ntp update-calendar
!
end
******************************************************************
Switch 1 Config
Building configuration...
Current configuration : 3864 bytes
!
version 12.2
service timestamps log datetime msec
service timestamps debug datetime msec
service password-encryption
!
hostname LANswitch
!
enable password 7 0829454A0D1C0B464058
!
ip dhcp relay information trust-all
!
!
!
ip ssh version 1
ip domain-name route.com
ip name-server 192.168.30.1
!
ip dhcp snooping
!
lldp run
!
spanning-tree mode pvst
!
interface FastEthernet0/1
switchport access vlan 1000
switchport trunk native vlan 1000
switchport mode access
switchport port-security maximum 2
switchport port-security mac-address sticky
!
interface FastEthernet0/2
switchport access vlan 1000
switchport trunk native vlan 1000
switchport mode access
!
interface FastEthernet0/3
switchport access vlan 1000
switchport trunk native vlan 1000
switchport mode access
!
interface FastEthernet0/4
switchport access vlan 1000
switchport trunk native vlan 1000
switchport mode access
!
interface FastEthernet0/5
switchport access vlan 1000
switchport trunk native vlan 1000
switchport mode access
!
interface FastEthernet0/6
switchport access vlan 1000
switchport trunk native vlan 1000
switchport mode access
!
interface FastEthernet0/7
switchport access vlan 1000
switchport trunk native vlan 1000
switchport mode access
!
interface FastEthernet0/8
switchport access vlan 1000
switchport trunk native vlan 1000
switchport mode access
!
interface FastEthernet0/9
switchport access vlan 1000
switchport trunk native vlan 1000
switchport mode access
!
interface FastEthernet0/10
switchport access vlan 1000
switchport trunk native vlan 1000
switchport mode access
!
interface FastEthernet0/11
switchport access vlan 1000
switchport trunk native vlan 1000
switchport mode access
!
interface FastEthernet0/12
switchport access vlan 1000
switchport trunk native vlan 1000
switchport mode access
!
interface FastEthernet0/13
switchport access vlan 1000
switchport trunk native vlan 1000
switchport mode access
!
interface FastEthernet0/14
switchport access vlan 1000
switchport trunk native vlan 1000
switchport mode access
!
interface FastEthernet0/15
switchport access vlan 1000
switchport trunk native vlan 1000
switchport mode access
!
interface FastEthernet0/16
switchport access vlan 1000
switchport trunk native vlan 1000
switchport mode access
!
interface FastEthernet0/17
switchport access vlan 1000
switchport trunk native vlan 1000
switchport mode access
!
interface FastEthernet0/18
switchport access vlan 1000
switchport trunk native vlan 1000
switchport mode access
!
interface FastEthernet0/19
switchport access vlan 1000
switchport trunk native vlan 1000
switchport mode access
!
interface FastEthernet0/20
switchport access vlan 1000
switchport trunk native vlan 1000
switchport mode access
!
interface FastEthernet0/21
switchport trunk native vlan 1000
!
interface FastEthernet0/22
switchport trunk native vlan 1000
!
interface FastEthernet0/23
switchport trunk native vlan 1000
!
interface FastEthernet0/24
switchport trunk native vlan 1000
!
interface GigabitEthernet0/1
switchport trunk native vlan 1000
switchport trunk allowed vlan 1000
switchport mode trunk
!
interface GigabitEthernet0/2
!
interface Vlan1
no ip address
shutdown
!
interface Vlan1000
description Native
mac-address 0060.5c5a.de01
ip address 192.168.20.2 255.255.255.0
ip helper-address 192.168.30.1
!
ip default-gateway 192.168.20.254
!
banner motd ^C THIS IS THE LAN SWITCH, DO NOT CHANGE ANY CONFIGURATION ON THIS SWITCH AS IT MAY CAUSE OUTAGES. CHANGES TO CONFIGURATION ARE ALLOWED AFTER AN APPROVAL IS OBTAINED^C
logging trap debugging
logging 192.168.30.1
!
!
snmp-server community switches RW
!
line con 0
!
line vty 0 4
exec-timeout 0 0
password 7 0829454A0D1C0B464058
login
privilege level 0
line vty 5 15
exec-timeout 0 0
password 7 0829454A0D1C0B464058
login
privilege level 0
!
!
!
end
Attached DHCP server config and architecture.