• April 21, 2018, 03:58:31 AM
Welcome, Guest. Please login or register. Registration is free.
Did you miss your activation email?

Author Topic: DHCP Problem with VLAN  (Read 1550 times)

0 Members and 1 Guest are viewing this topic.

Offline create_share

  • Rookie
  • **
  • Posts: 2
DHCP Problem with VLAN
« on: May 30, 2016, 06:13:42 AM »
Hi!

I have tried everything on the internet to make my setup work but could not succeed. Here is my simple network:

1. Firewall Connected to Port 1 of HP Switch

LAN IP 172.16.22.1 (DHCP 172.16.22.101-172.16.22.254)

Sub Interface of LAN as Vlan 122 IP 172.16.122.1 (DHCP 172.16.122.101-172.16.122.254)



2. PC connected to port 7 of HP Switch



3. HP Procurve Switch Config

Running configuration:

; J9146A Configuration Editor; Created on release #W.14.38

hostname "HP"
module 1 type J9146A
ip default-gateway 172.16.22.1
ip routing
vlan 1
   name "DEFAULT_VLAN"
   untagged 1-24
   ip address 172.16.22.2 255.255.255.0
   exit
vlan 122
   name "VLAN122"
   ip helper-address 172.16.122.1
   ip address 172.16.122.2 255.255.255.0
   exit
gvrp
ip route 0.0.0.0 0.0.0.0 172.16.22.1
ip route 172.16.122.0 255.255.255.0 vlan 122
snmp-server community "public" unrestricted



The problem I am facing is with Vlan 122 dhcp which is not assigning ip address to the pc. I tried tagging untagging port 7 where the pc is connected but did not work.

Can anybody help?

Thanks.

Seems people have stopped logging in to this forum.



Offline jcoehoorn

  • Jr. Member
  • **
  • Posts: 39
Re: DHCP Problem with VLAN
« Reply #1 on: June 07, 2016, 05:08:42 PM »
Tell us about your dhcp server. Nothing in that config turns on any dhcp services. If dhcp is on a different device, you'll want to add helper address fields to the configs for both vlans. With only one port set for VLAN 122, this address should probably be a VLAN 1 address. Yes, dhcp traffic on vlan 1 will already reach your dhcp server, but using the helper addresses can help the dhcp server distinguish which scope to use.

Right now you have your switch doing routing between VLANS. If, say, your firewall is doing dhcp, it only sees the routed packets. It needs separate dhcp scopes for both vlans and route defined to reach VLAN 122.

Code: [Select]
; J9146A Configuration Editor; Created on release #W.14.38

hostname "HP"
module 1 type J9146A
ip default-gateway 172.16.22.1
ip routing
vlan 1
   name "DEFAULT_VLAN"
   untagged 1-6,8-24
   ip address 172.16.22.2 255.255.255.0
   ip helper-address <address of dhcp server>
   exit
vlan 122
   name "VLAN122"
   ip address 172.16.122.2 255.255.255.0
   untagged 7
   ip helper-address <address of dhcp server>
   exit
gvrp
ip route 0.0.0.0 0.0.0.0 172.16.22.1
ip route 172.16.122.0 255.255.255.0 vlan 122
snmp-server community "public" unrestricted
« Last Edit: June 07, 2016, 05:16:27 PM by jcoehoorn »

Offline create_share

  • Rookie
  • **
  • Posts: 2
Re: DHCP Problem with VLAN
« Reply #2 on: June 09, 2016, 04:06:11 AM »
Thanks for replying. It started working. The problem was with the firewall acting as dhcp server.