New VLAN with DHCP server

Post Reply
lanwifi
Member
Posts: 5
Joined: 24 Sep 2021 10:04

New VLAN with DHCP server

Post by lanwifi »

Hello,

I have a OS6350-P24 and I want to create a new VLAN and enable a DHCP server for this VLAN.

I create the new VLAN and VLAN interface this way:

Code: Select all

vlan 20 name "GUEST"
ip interface vlan-20 address 192.168.2.1/24 vlan 20
I didn't find any command to create a DHCP server for this VLAN, I try from web interface, but I have this error when try to enable:

Image

Is it possible to configure the DHCP server from command line?

I will appreciate your help, I am new with Alcatel switches.

Regards.
lanwifi
Member
Posts: 5
Joined: 24 Sep 2021 10:04

Re: New VLAN with DHCP server

Post by lanwifi »

Hello,

I got it!

I create two files:

Code: Select all

vi /flash/switch/dhcpd.conf

Code: Select all

server-identifier switch-1.example.com;
subnet 192.168.2.0 netmask 255.255.255.0
{
 dynamic-dhcp range 192.168.2.100 192.168.2.200
 {
  option subnet-mask 255.255.255.0;
  option routers 192.168.2.1;
  option domain-name-servers 8.8.8.8;
  option dhcp-lease-time 900;
 }
}

Code: Select all

vi /flash/switch/dhcpd.pcy
leave it empty

Then enable the service this way:

Code: Select all

dhcp-server restart
dhcp-server enable
Now I have a DHCP server in the new VLAN network.

Hope this will help someone else.

Regards.
Post Reply

Return to “OmniSwitch 6350”