cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
997
Views
0
Helpful
5
Replies

DHCP FO VLANS (Switch CISCO SF300-48PP)

mmalaoui
Level 1
Level 1

Hello,
I have a Cisco SF300-48PP Switch I created 3 VLANS (LAN, WIFI, SRV) I am in L2 Mode
I want every Vlan to be a DHCP server for example
IP address of Switch 192.168.1.254
I want the VLAN1 (LAN) to distribute IP addresses from: 192.168.1.10 to 192.168.1.100
VLAN2 from 192.168.101.to 192.168.1.151
VLAN3 from 192.168.1.152 to 192.168.1.230
Thank you

5 Replies 5

Seb Rupik
VIP Alumni
VIP Alumni

Hi there,
I'm affriad the DHCP ranges you want do not fit within netmask boundaries. So I have opted to use the following:
VLAN1 : 192.168.1.0/25
VLAN2 : 192.168.1.128/25
VLAN3 : 192.168.2.0/25

 

Firstly get the SG300 into L3 mode:

!
set system mode router
!

 

...reload the router. Then try this config:

!
int vlan1
ip address 192.168.1.1 255.255.255.128
int vlan2
ip address 192.168.1.129 255.255.255.128
int vlan3
ip address 192.168.2.1 255.255.255.128
!
ip dhcp server
ip dhcp pool network DHCP_VLAN1
address 192.168.1.0 /25
default-router 192.168.1.1
dns-server 8.8.8.8
!
ip dhcp pool network DHCP_VLAN2
address 192.168.1.128 /25
default-router 192.168.1.129
dns-server 8.8.8.8
!
ip dhcp pool network DHCP_VLAN3
address 192.168.2.0 /25
default-router 192.168.2.1
dns-server 8.8.8.8
!
ip dhcp excluded-address 192.168.1.1
ip dhcp excluded-address 192.168.1.129
ip dhcp excluded-address 192.168.2.1
!

 

Let us know how it works.

 

cheers,

Seb.

thank you,

can we do it from the GUI (Graphic Interface)

cordially

Of course. In which case I would suggest following the steps outlined in the configuration guides provided online by Cisco.

 

Personally speaking, taking this opportunity to apply the config via CLI will produce the solution quicker and begin to equip you with the knowledge for tackling a range of operations on the cisco family of products.

 

cheers,

Seb.

Thank you for your quick answers,

I am new to the Cisco family can you send me the link for access to his videos.

cordially

https://www.cisco.com/c/dam/en/us/td/docs/switches/lan/csbms/sf30x_sg30x/administration_guide/78-19308-01.pdf

 

Section 17 - IP Configuration, covers configuring the SVIs and also DHCP server.

 

cheers,

Seb.