The dhcp server sname command configures the name of the server where the DHCP client obtains the startup configuration file.
The undo dhcp server sname command deletes the configured name of the server where the DHCP client obtains the startup configuration file.
By default, the name of the server where the DHCP client obtains the startup configuration file is not configured.
Parameter |
Description |
Value |
---|---|---|
sname |
Specifies the name of the server where the DHCP client obtains the startup configuration file. |
The value is a string of 1 to 63 case-sensitive characters without spaces. |
Usage Scenario
Besides assigning IP addresses, a DHCP server can also provide the required network configuration parameters, such as the startup configuration file name for the DHCP clients. After the name of the server where the DHCP client obtains the startup configuration file is configured using the dhcp server sname command, the DHCP client obtains the startup configuration file from this server.
Prerequisites
IP addresses in the interface address pool have been configured using the ip address command.
The DHCP server function has been enabled on the interface using the dhcp select interface command.
The startup configuration file name has been configured for the DHCP client using the dhcp server bootfile.
Follow-up Procedures
Ensure that the route between the DHCP client and the file server where the DHCP client obtains the startup configuration file is reachable.
<HUAWEI> system-view [HUAWEI] dhcp enable [HUAWEI] vlan 100 [HUAWEI-vlan100] quit [HUAWEI] interface vlanif 100 [HUAWEI-Vlanif100] ip address 10.1.1.1 255.255.255.0 [HUAWEI-Vlanif100] dhcp select interface [HUAWEI-Vlanif100] dhcp server bootfile start.ini [HUAWEI-Vlanif100] dhcp server sname Huawei
<HUAWEI> system-view [HUAWEI] dhcp enable [HUAWEI] interface gigabitethernet 0/0/1 [HUAWEI-GigabitEthernet0/0/1] undo portswitch [HUAWEI-GigabitEthernet0/0/1] ip address 10.1.1.1 255.255.255.0 [HUAWEI-GigabitEthernet0/0/1] dhcp select interface [HUAWEI-GigabitEthernet0/0/1] dhcp server bootfile start.ini [HUAWEI-GigabitEthernet0/0/1] dhcp server sname Huawei