cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
57128
Views
20
Helpful
6
Replies

Configure 3560 switch as DHCP Server

junshah22
Level 1
Level 1

Dear All,

I want to configure my Cisco Switch 3560 as DHCP server so that my users in different vlans (configured) can assign IPs automatically,

I am using this configuration,

ip dhcp pool Marketing

network 192.168.2.0 255.255.255.0

default-router 192.168.2.1

dns-server 192.168.1.17

what else i need to configure on my layer 3 switch to work properly..

In this case, when i connect a PC to a port assigned in Vlan 2, its not getting Ip address automatically,,

Please write Sample configuration...

Regards,

Junaid

6 Replies 6

Junaid,

That should work.

!

ip dhcp excluded-address 192.168.2.1

!

ip dhcp pool Marketing

network 192.168.2.0 255.255.255.0

default-router 192.168.2.1

dns-server 192.168.1.1

!

service dhcp

!

ip routing

!

int vla 2

ip address 192.168.2.1 255.255.255.0

!

Please let me know how things work out

Toshi

Dear Toshi,

I applied your configuration but it is not working,

Please check my configuration,

ip subnet-zero

ip routing

ip dhcp excluded-address 192.168.2.1

ip dhcp excluded-address 192.168.2.1 192.168.2.20

ip dhcp pool D_MKT

network 192.168.2.0 255.255.255.0

default-router 192.168.2.1

dns-server 192.168.1.17

domain-name 192.168.1.17

lease 8

ip dhcp-server 192.168.2.1

vlan 2

name MKT

interface FastEthernet0/8

switchport access vlan 2

switchport mode access

interface Vlan2

ip address 192.168.2.1 255.255.255.0

ip access-group 110 out

ip classless

access-list 110 permit ip 192.168.1.0 0.0.0.255 any

I applied ACL to permit different vlan users to get access on servers vlans...

Please HELP!

Regards,

Junaid

I applied ACL to permit different vlan users to get access on servers vlans... < --- And there's an explicit DENY ANY ANY at the end of the line.

Junaid ,

Let's modify things.

access-list 110 permit ip 192.168.1.0 0.0.0.255 any

access-list 110 permit udp any eq bootpc any

access-list 110 permit udp any eq bootps any

HTH,

Toshi

Dear Toshi,

Congratss!!

previous configuration started working,

Actually, the machine which i was using for testing, (its DHCP service was blocked),,

When i tried it with another Computer, it is getting Ip address and other information,

THANKS AGAIN..

Junaid

Junaid,

You're right. I got confused because the router generating traffic would not be blocked by outbound ACL.

Good job,

Toshi

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: