
MES3000 Ethernet switch series
189
5.25
DHCP Relay mediation features
MES3000 switches support DHCP Relay agent function. DHCP Relay agent transfers DHCP packets
from the client to the server and back when the DHCP server and the client located in different networks.
Also, DHCP Relay agent adds extra options to the client DHCP requests (e.g. Option 82).
DHCP Relay agent operating principle for the switch:
the switch receives DHCP requests from the client, sends these requests to the server on behalf of
the client (also placing options into request with necessary parameters for the client and adding its own
options according to the configuration). When the switch receives the response from the server, it sends it
to the client.
Global configuration mode commands
Command line request in global configuration mode appears as follows:
console(config)#
Table 5.228 —Global configuration mode commands
Command
Value
Action
ip dhcp relay enable
The agent is disabled by
default.
Enable DHCP Relay agent for the switch.
no ip dhcp relay enable
Disable DHCP Relay agent for the switch.
ip dhcp relay address
ip_addr
You can configure up to 8
servers.
Specify available DHCP server IP address for DHCP Relay agent.
no ip dhcp relay address
[
ip_addr
]
Remove the IP address from DHCP server list for DHCP Relay
agent.
ip dhcp relay broadcast
enable
The mode is disabled by
default.
Enable DHCP server answers broadcasting
no ip dhcp relay broadcast
enable
Restore the default mode
ip dhcp relay information
policy {keep | replace |
drop}
The 'keep' mode is enabled
by default.
Define the processing mode for DHCP packets with Option 82.
- keep—forwarding packets without changing
- replace—replace Option 82 content
- drop—drop packets that contain Option 82
no ip dhcp relay
information policy
Restore the default mode.
ip dhcp relay information
option format-type option
format
[delimiter
delimiter
]
format: (sp, sv, pv, spv, bin,
user-defined);
delimiter: (.,;#)/space
DHCP option 82 format setting
Format:
-
sp
—slot and port number
-
sv
—slot and VLAN number
-
pv
—port and VLAN number
-
spv
—slot, port and VLAN number
-
bin
—binary format: VLAN, slot, port
-
user-defined
- format is definied by user.
Following samples is used for definition:
%h: hostname;
%p: short port name, e.g. gi1/0/1;
%P: long port name, e.g. gigabitethernet 1/0/1;
%t: port type (ifTable field value::ifType in hexadecimal numeral
system)
%m: MAC address of the port in H-H-H-H-H-H-H format;
%M: system MAC address in H-H-H-H-H-H-H format;
%u: unit number;
%s: slot number;
%n: port number (as it is shown on front panel);
%i: port ifindex;
%v: VLAN identifier;