cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Announcements

CISCO SWITCHES FOR SMALL and MEDIUM BUSINESS

Introducing the next generation of Cisco Small and Medium Business Switches. Cisco is refreshing its SMB Switch portfolio. Click here  to learn more.


111955
Views
5
Helpful
6
Replies
Beginner

Configure DHCP on VLAN

Do anyone knows if DHCP can be configure on VLAN?

6 REPLIES 6
Beginner

Re: Configure DHCP on VLAN

I may need more detail to accurately answer your question but I believe you are asking whether or not you can configure a specific DHCP pool for each VLAN and the answer is yes...but, it depends on the devices involved in your network.

Is there a specific device you are curious about or were you wanting to know if it is even possible in the first place?

Beginner

Re: Configure DHCP on VLAN

Thanks for the reply. I will be working Cisco 2960 & 3560 switches. The 3560 will be the core switches and the 2960 will hang off it. I will also configure the 3560 switches with HSRP for redundancy. I would like to configure specific DHCP pool for the created VLAN's. Do you knows the commands for creating DHCP pool for VLAN's. I have the commands for creating DHCP pool but not for VLAN's. Thanks in advance.

Enthusiast

Re: Configure DHCP on VLAN

Hello and good evening,

You create a DHCP scope on a 3560 just like any other IOS DHCP configs ...here is a sample config:

interface vlan 1

ip add 1.1.1.1 255.255.255.0

interface vlan 2

ip address  2.2.2.1 255.255.255.0

ip dhcp excluded-address 1.1.1.1 1.1.1.10

ip dhcp excluded-address 2.2.2.1 2.2.2.10
!
ip dhcp pool vlan1
   network 1.1.1.0 255.255.255.0
   domain-name cisco.com
   dns-server 4.4.4.2 4.4.4.1
   default-router 1.1.1.1

   lease 3

!

ip dhcp pool vlan2
    network 2.2.2.0 255.255.255.0
    domain-name cisco.com
    dns-server 4.4.4.2 4.4.4.1
    default-router 2.2.2.1

   lease 3

!

Here is the link for configuring IOS DHCP services:

http://www.cisco.com/en/US/docs/ios/ipaddr/configuration/guide/iad_dhcp_svr_cfg_ps6441_TSD_Products_Configuration_Guide_Chapter.html

Your proposed design is a good one, and you have obviously done your homework!  A nice design!

I would say however, that this community is really more for Cisco Small Business products and your question is in reference to a Cisco traditional products.  I believe you will have a better experience by posting your question in the Cisco NetPro forums located here: http://forums.cisco.com/eforum/servlet/NetProf?page=main 

That forum has subject matter experts on Cisco traditional products that may be able to answer your question. 

HTH,

Andrew Lee Lissitz

Highlighted
Beginner

Re: Configure DHCP on VLAN

That is a great information.  However, I still want to "make sure" I am not configuring the switch (3560) incorrectly.

My scenario is this - a 3560 switch is connected to a router and a local cable modem provider.

We have configure Vlan1 and 2 to access our router and network.  However, we want to configure the Vlan10 to utilize the local cable modem for internet access.  I have the cable modem IP address (network/subnet).  The cable modem will not hand out DHCP.  I would like to setup the switch (3560) to hand out ip address using /16 subnet.

 

Thank you all for your input and suggestions.

 

Gil

 

Everyone's tags (3)
Beginner

Re: Configure DHCP on VLAN

Well, i just want to know the easy steps to configure the dhcp pool on different vlans, using the dhcp server.

Contributor

Re: Configure DHCP on VLAN

First

u have to creat the required VLAN(s)

then for each VLAN u have to Creat a DHCP config the relate to that vlan and havs the right ip subnet

lets say u have vlan 10

make the vlan on ur access layer switch

with command

vlan 10 [enter]

name vlan_10

then assign this vlan to the required ports

and make sure the switch port no shutdown anslo the is Important thing which is the spanning tree PORTFAST this otion if u dont put it on access port for client need DHCP u gonna loss the DHCP

for example

interface range fa0/1 - 24

switchport mode access

switchport access vlan 10

spanning-tree portfast

no shut

these ports ready to connect the PCs

now next step for distribution layer and DHCP

make the connection between the access switches and the Dist switches trunk to pass VLAN tags

then on the Dist switches creat the same vlans numbers

and creat for each vlan a switched virtual interface SVI which will be the defaul gateway for client in the corspoding VLAN

example Dist switch

vlan 10

vlan name vlan_10

interface vlan 10

ip address 10.1.1.1 255.255.255.0

no shut

10.1.1.1 will be the default gateway for vlan 10 users

then go to configure the dhcp on the switch

note: if u have the dhcp on other router, switch or server u have to add th ip hlper command on the SVI interface poiting to that dhcp server

in our example the Dist switch will be the dhcp so we dont need that command

ip dhcp pool vlan10

network 10.1.1.0

default-router 10.1.1.1

exculded-address 10.1.1.1

about option 150 this option used when u have IP telphoney and voice vlan to point to the TFTP server

if u dont have u dont need it

and repeat the same config for each vlan but with deffrent ip address

for example dhcp for vlan 20

shoud like

ip dhcp pool vlan20

network 20.1.1.0

default-router 20..1.1.1

and so on

dont for get the SVI

and the access port config with portfast

being enable

also check the dhcp service if enabled or not(by default yes)

this link also helpful

http://www.cisco.com/en/US/tech/tk648/tk361/technologies_tech_note09186a00800f0804.shtml
please, Rate if helpful