Creates a set of DHCP options for your VPC. After creating the new set, you must then associate it with the VPC, causing all existing and new instances that you launch in the VPC to use the new set of DHCP options. The following table lists the individual DHCP options you can specify. For more information about the options, go to RFC 2132.
| DHCP Option Name | Description |
|---|---|
|
domain-name |
A domain name of your choice (e.g., example.com). |
|
domain-name-servers |
The IP address of a domain name server. You can specify up to four addresses. |
|
ntp-servers |
The IP address of a Network Time Protocol (NTP) server. You can specify up to four addresses. |
|
netbios-name-servers |
The IP address of a NetBIOS name server. You can specify up to four addresses. |
|
netbios-node-type |
Value indicating the NetBIOS node type (1, 2, 4, or 8). For more information about the values, go to RFC 2132. We recommend you only use 2 at this time (broadcast and multicast are currently not supported). |
![]() | Important |
|---|---|
Your VPC automatically starts out with a set of DHCP options that includes
only a DNS server that we provide (169.254.169.253). If you create a new set of
options, and if your VPC has an Internet gateway, make sure to set the
|
For more information about Amazon Virtual Private Cloud and DHCP options, go to Using DHCP Options in Your VPC in the Amazon Virtual Private Cloud User Guide.
| Name | Description | Required |
|---|---|---|
|
|
The name of a DHCP option. Type: String Default: None |
Yes |
|
|
A value for the DHCP option. Type: String Default: None |
Yes |
The elements in the following table are wrapped in an
CreateDhcpOptionsResponse structure.
| Name | Description |
|---|---|
|
|
The ID of the request. Type: xsd:string |
|
|
Set of DHCP options. Type: DhcpOptionsType |
This example creates a new set of DHCP options with a domain name mydomain.com and two DNS servers (10.2.5.1 and 10.2.5.2).
https://ec2.amazonaws.com/?Action=CreateDhcpOptions &DhcpConfiguration.1.Key=domain-name &DhcpConfiguration.1.Value.1=mydomain.com &DhcpConfiguration.2.Key=domain-name-servers &DhcpConfiguration.2.Value.1=10.2.5.1 &DhcpConfiguration.2.Value.2=10.2.5.2 &AUTHPARAMS
<CreateDhcpOptionsResponse xmlns="http://ec2.amazonaws.com/doc/2011-01-01/">
<requestId>7a62c49f-347e-4fc4-9331-6e8eEXAMPLE</requestId>
<dhcpOptions>
<dhcpOptionsId>dopt-7a8b9c2d</dhcpOptionsId>
<dhcpConfigurationSet>
<item>
<key>domain-name</key>
<valueSet>
<item>
<value>mydomain.com</value>
</item>
</valueSet>
</item>
<item>
<key>domain-name-servers</key>
<valueSet>
<item>
<value>10.2.5.1</value>
</item>
<item>
<value>10.2.5.2</value>
</item>
</valueSet>
</item>
</dhcpConfigurationSet>
<tagSet/>
</dhcpOptions>
</CreateDhcpOptionsResponse>