DHCP Server on a Cisco 3640 Router

Hi,

I have a Cisco 3640 router with multiple subnets configured, Dot1 Q Tagged VLans. I have setup a DHCP server for VLAN 3, and it is working fine. My question is, can you have multiple DHCP services running on the same router, one for each subnet? If so, will each subnet get the correct IP Address asigned to it. Partial config listed below.

!
ip dhcp excluded-address 192.168.3.1 192.168.3.19
ip dhcp excluded-address 192.168.3.250 192.168.3.254
!
ip dhcp pool tcs192
   network 192.168.3.0 255.255.255.0
   domain-name tcs192
   dns-server 216.x.x.x 216.xx.x
   default-router 66.x.86.x
   lease 3
!
!
!
!
interface FastEthernet2/0
 description Connected to Cat 0/5
 no ip address
 no ip redirects
 no ip unreachables
 no ip proxy-arp
 ip nat inside
 no ip mroute-cache
 duplex auto
 speed auto
 no mop enabled
!
interface FastEthernet2/0.1
 description 172.31.x.x/24
 encapsulation dot1Q 1 native
 ip address 172.31.x.x 255.255.255.0
 ip access-group fa11_in in
 ip nat inside
 no cdp enable
!
interface FastEthernet2/0.2
 description 10.10.x.x/24
 encapsulation dot1Q 2
 ip address 10.10.x.x 255.255.255.0
 ip access-group fa12_in in
 ip nat inside
 no cdp enable
!
interface FastEthernet2/0.3
 description 192.168.3.x/24
 encapsulation dot1Q 3
 ip address 192.168.3.x 255.255.255.0
 ip access-group fa13_in in
 ip nat inside
 no cdp enable
!
interface FastEthernet2/0.4
 description 172.16.x.x/24
 encapsulation dot1Q 4
 ip address 172.16.x.x 255.255.255.0
 ip access-group fa14_in in
 ip nat inside
 no cdp enable
!
orbixAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

lrmooreCommented:
>My question is, can you have multiple DHCP services running on the same router, one for each subnet? If so, will each subnet get the correct IP Address asigned to it.

Yes, absolutely...

ip dhcp pool VLAN4
   network 172.16.x.0 255.255.255.0
   domain-name <tcs192>
   dns-server 216.x.x.x 216.xx.x
   default-router 172.16.x.x  <== use this router's interface IP for that VLAN
   lease 3

ip dhcp pool VLAN2
   network 10.10.x.0 255.255.255.0
   domain-name <tcs192>
   dns-server 216.x.x.x 216.xx.x
   default-router 10.10.x.x  <== use this router's interface IP for that VLAN
   lease 3
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
orbixAuthor Commented:
lrmoore, thanks for the information.  I see you have
default-router 172.16.x.x  <== use this router's interface IP for that VLAN
listing the IP for the routers int for the subnet.
In the config I posted, I have the default-router as
default-router 66.x.86.x <=== IP of default gateway/route to the outside/ISP.
If I understand this correctly, I should change that to the routers IP for the VLAN INT,
and the routers gateway of last resort will handle routeing to the outside world/ISP.
I do have NAT configured for both the public, and private IP's.

!
ip dhcp pool tcs192
   network 192.168.3.0 255.255.255.0
   domain-name tcs192
   dns-server 216.x.x.x 216.xx.x
   default-router 66.x.86.x
   lease 3
!
0
lrmooreCommented:

Absolutely, you should change the scope that you already have to reflect the vlan interface IP as the clients' gateway. The default gateway must be on the same subnet as the client.
Having the default gateway of the router itself pointing to the public ip 66.xx.86.x is all you need

0
orbixAuthor Commented:
Again, thanks for all your help.
One last question, with regard to excluded address, I take it you just add as many lines as needed for the differnet subnets?

!
ip dhcp excluded-address 192.168.3.1 192.168.3.19
ip dhcp excluded-address 192.168.3.250 192.168.3.254
!
ip dhcp excluded-address 172.31.3.1 172.31.3.19
ip dhcp excluded-address 172.31.3.250 172.31.3.254
!

etc...
0
lrmooreCommented:
You got it...

-Cheers!
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Routers

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.