Skip to content

Switch Routing Interfaces DHCP Configuration

Dashboard Location: Switching > Configure > Routing and DHCP

DHCP Service Management for Layer 3 Interfaces

Switch routing interfaces DHCP configuration in Meraki networks provides administrators with the capability to implement comprehensive DHCP services directly on Layer 3 switch interfaces, enabling distributed IP address management, network boot services, and advanced DHCP options. This functionality supports automated IP allocation, DNS configuration, DHCP relay services, PXE boot environments, custom DHCP options, and centralized address reservation management. Switch interface DHCP services are essential for distributed network architectures, reducing DHCP server dependencies, providing network redundancy, and supporting specialized network services like VoIP and network boot scenarios.

Diagram

Diagram

Classes

switch_routing_interfaces (meraki.domains.organizations.networks.devices)

NameTypeConstraintMandatoryDefault Value
dhcpClass[dhcp]No

dhcp (meraki.domains.organizations.networks.devices.switch_routing_interfaces)

NameTypeConstraintMandatoryDefault Value
dhcp_modeChoicedhcpDisabled, dhcpRelay, dhcpServerNo
dhcp_relay_server_ipsListIPNo
dhcp_lease_timeChoice1 day, 1 hour, 1 week, 12 hours, 30 minutes, 4 hoursNo
dns_nameservers_optionChoicecustom, googlePublicDns, openDnsNo
dns_custom_nameserversListIPNo
boot_next_serverIPNo
boot_file_nameStringmin: 1, max: 127No
dhcp_optionsList[dhcp_options]No
reserved_ip_rangesList[reserved_ip_ranges]No
fixed_ip_assignmentsList[fixed_ip_assignments]No
boot_optionsBooleantrue, falseNo

dhcp_options (meraki.domains.organizations.networks.devices.switch_routing_interfaces.dhcp)

NameTypeConstraintMandatoryDefault Value
codeStringRegex: ^([2-9]|1[0-9][0-9]?|2[0-9]|2[0-5][0-4]|[3-9][0-9])$Yes
typeChoicehex, integer, ip, textYes
valueStringmin: 1, max: 127Yes

reserved_ip_ranges (meraki.domains.organizations.networks.devices.switch_routing_interfaces.dhcp)

NameTypeConstraintMandatoryDefault Value
startIPYes
endIPYes
commentStringmin: 1, max: 127No

fixed_ip_assignments (meraki.domains.organizations.networks.devices.switch_routing_interfaces.dhcp)

NameTypeConstraintMandatoryDefault Value
nameStringmin: 1, max: 127Yes
macMACYes
ipIPYes

Examples

Example-1: The example below demonstrates switch routing interface DHCP configuration using tested YAML configuration from pipeline fixtures.

meraki:
domains:
- name: "!env domain"
administrator:
name: "!env org_admin"
organizations:
- name: "!env org"
networks:
- name: "!env network_name"
product_types:
- appliance
- switch
- wireless
- camera
- sensor
- cellularGateway
devices:
- name: "!env dmz_switch_02"
switch_routing_interfaces:
- name: VLAN 10
dhcp:
dhcp_mode: "dhcpServer"
dhcp_lease_time: "1 day"
dns_nameservers_option: "custom"
dns_custom_nameservers:
- 8.8.8.8
boot_options: true
boot_next_server: "1.1.1.65"
boot_file_name: "test"
dhcp_options:
- code: "150"
type: "ip"
value: "1.1.1.60"
reserved_ip_ranges:
- start: "1.1.1.200"
end: "1.1.1.205"
comment: "test"
fixed_ip_assignments:
- name: "test"
mac: "00:11:22:33:44:55"
ip: "1.1.1.25"
comment: "Network Infrastructure"

Configuration Parameters

ParameterTypeRequiredDescription
dhcpObjectNoDHCP configuration for routing interface
dhcp.dhcp_modeStringYesDHCP mode: “dhcpServer”, “dhcpRelay”, “dhcpDisabled”
dhcp.dhcp_relay_server_ipsArrayConditionalDHCP relay server IPs (required for relay mode)
dhcp.dhcp_lease_timeStringNoLease time: “30 minutes”, “1 hour”, “4 hours”, “8 hours”, “1 day”, “1 week”
dhcp.dns_nameservers_optionStringNoDNS option: “googlePublicDns”, “openDns”, “custom”
dhcp.dns_custom_nameserversArrayConditionalCustom DNS servers (required for custom DNS)
dhcp.boot_optionsBooleanNoEnable PXE/network boot options
dhcp.boot_next_serverStringConditionalNext server for PXE boot (required if boot_options enabled)
dhcp.boot_file_nameStringConditionalBoot filename for PXE (required if boot_options enabled)
dhcp.dhcp_optionsArrayNoCustom DHCP options
dhcp.dhcp_options[n].codeStringYesDHCP option code (1-254)
dhcp.dhcp_options[n].typeStringYesOption type: “text”, “ip”, “hex”
dhcp.dhcp_options[n].valueStringYesOption value based on type
dhcp.reserved_ip_rangesArrayNoIP ranges to exclude from DHCP pool
dhcp.reserved_ip_ranges[n].startStringYesStart IP of reserved range
dhcp.reserved_ip_ranges[n].endStringYesEnd IP of reserved range
dhcp.reserved_ip_ranges[n].commentStringNoDescription for reserved range
dhcp.fixed_ip_assignmentsArrayNoStatic IP assignments
dhcp.fixed_ip_assignments[n].nameStringYesName for fixed assignment
dhcp.fixed_ip_assignments[n].macStringYesMAC address for assignment
dhcp.fixed_ip_assignments[n].ipStringYesIP address to assign

DHCP Operating Modes

ModeDescriptionUse CaseConfiguration Requirements
dhcpServerLocal DHCP serviceDistributed DHCPSubnet configuration
dhcpRelayForward to external serverCentralized DHCPServer IP addresses
dhcpDisabledNo DHCP serviceStatic addressingManual IP configuration

DHCP Lease Time Options

Lease TimeDurationUse CaseRenewal Behavior
30 minutes0.5 hoursHigh-mobility devicesFrequent renewal
1 hour1 hourGuest networksRegular renewal
4 hours4 hoursStandard workstationsBalanced approach
8 hours8 hoursBusiness hours alignmentDaily renewal
1 day24 hoursStable devicesWeekly renewal
1 week168 hoursServers, printersInfrequent renewal

DNS Configuration Options

DNS OptionDescriptionServersUse Case
googlePublicDnsGoogle Public DNS8.8.8.8, 8.8.4.4General internet access
openDnsOpenDNS Service208.67.222.222, 208.67.220.220Content filtering
customCustom DNS serversUser-specifiedCorporate DNS, AD integration

Common DHCP Options

Option CodeNameTypePurposeExample Value
1Subnet MaskIPNetwork mask”255.255.255.0”
3RouterIPDefault gateway”192.168.1.1”
6DNS ServerIPName resolution”8.8.8.8”
15Domain NameTextDNS domain”company.com”
42NTP ServerIPTime synchronization”pool.ntp.org”
66TFTP ServerTextBoot server”pxe.company.com”
67Boot FilenameTextBoot file”pxelinux.0”
150Cisco IP PhoneIPVoIP controller”10.1.1.100”

PXE Boot Configuration

PXE ComponentConfigurationPurposeRequirements
Next ServerTFTP server IPBoot server locationTFTP service
Boot FilenameBoot file pathInitial boot filePXE boot loader
DHCP Option 66TFTP server nameAlternative server specificationDNS resolution
DHCP Option 67Boot filenameAlternative filenameBoot file availability

VoIP Integration

VoIP FeatureDHCP ImplementationConfigurationPhone Support
Call Manager DiscoveryOption 150IP address listCisco phones
VLAN AssignmentOption 132VLAN ID802.1Q capable phones
NTP ConfigurationOption 42Time serverTime synchronization
Domain AssignmentOption 15DNS domainSIP registration