How to configure auto-ip, configuration examples for auto-ip.
Your software release may not support all the features documented in this module. For the latest caveats and feature information, see Bug Search Tool and the release notes for your platform and software release. To find information about the features documented in this module, and to see a list of the releases in which each feature is supported, see the feature information table at the end of this module.
Use Cisco Feature Navigator to find information about platform support and Cisco software image support. To access Cisco Feature Navigator, go to www.cisco.com/go/cfn . An account on Cisco.com is not required.
Auto-IP on an EtherChannel
The auto-IP feature is an enhancement of Link Layer Discovery Protocol (LLDP). LLDP uses a set of attributes to discover neighbor devices. This attribute set is called Type Length Value (TLV) as it contains type, length, and value descriptions.
In a ring topology, two network-to-network interfaces (NNIs or node interfaces) of a device are used to be part of the ring. For a ring to function as an auto-IP ring, you must configure the auto-IP feature on all the node interfaces within the ring. One node interface of a device is designated as the owner-interface and the other interface as the non-owner-interface. In an auto-IP ring, the owner-interface of a device is connected to a non-owner-interface of the neighbor device. A sample topology is given below:
When a new device is inserted into an auto-IP ring, owner and non-owner-interfaces of the inserted device are identified. The node interface of the inserted device that is connected to an owner-interface is designated as the non-owner-interface, and it automatically receives an IP address from the connected neighbor device. The IP address is automatically configured on the interface. Since the non-owner-interface is identified, the other node interface of the inserted device is designated as the owner-interface, and the device assigns a pre configured auto-IP address to its designated owner-interface.
An auto-IP address is a preconfigured address configured on a node interface to make the interface capable of automatically assigning an IP address to a new neighbor interface that is detected in the auto-IP ring. The configured auto-IP address is used for allocation purposes.
You must configure the same auto-IP address on the two node interfaces that are designated to be part of an auto-IP ring, and the auto-IP address must contain an odd number in the last octet. The auto-IP address is assigned to the owner-interface when the device is introduced into an auto-IP ring. Since each auto-IP address contains an odd number in the last octet, the IP address derived by subtracting 1 from the last octet is an even number, and is not used for designating auto-IP addresses. This IP address is allocated to a newly detected neighbor, non-owner-interface.
For example, if we assume that the device R3 is inserted between the devices R1 and R2 in the above topology, and the auto-IP address 10.1.1.3 is configured on e0/1 and e0/0, the two node interfaces on device R3, then R1 assigns an IP address to the non-owner-interface of R3, e0/1. The IP address 10.1.1.3 is assigned to the owner-interface of R3, e0/0. The IP address derived by subtracting 1 from the last octet of the auto-IP address is 10.1.1.2. 10.1.1.2 is assigned to the neighbor non-owner-interface of the connected neighbor device R2.
Before insertion, the node interfaces are not designated as owner and non-owner. After insertion, the auto-IP TLV is exchanged between the neighbor devices. During this initial negotiation with the adjacent device interfaces, owner and non-owner-interfaces are determined automatically.
After a device is inserted into a ring, the auto-IP address configured for the device (such as 10.1.1.3) is assigned to the owner-interface for the /31 subnet. An owner-interface has a priority 2 in the auto-IP TLV, and a non-owner-interface has priority 0 in the auto-IP TLV. If there is no assigned IP address on the node interface (before the node is inserted into a ring), then the ring interface has priority 1 in the auto-IP TLV.
The IP address negotiation is based on priority; the higher value of priority wins the negotiation. If the priority is equal, then IP negotiation fails. This scenario usually occurs when there is an incorrect configuration or wiring. In such a scenario, you must ensure that the configuration and wiring is proper.
Some points on auto-IP configuration on virtual routing and forwarding instance (VRF) interfaces are noted below:
Some points on auto-IP configuration for an EtherChannel interface are noted below:
Some points on auto-IP configuration on a Switch Virtual Interface (SVI) are noted below:
Seed devices are the devices used to initiate network discovery. To initiate auto-IP capability in a ring, at least one device must be configured as a seed device in the ring. To configure a device as a seed device in an auto-IP ring, you must manually configure the IP address configured on one of its node interfaces with the auto-IP address of the interface, with the mask /31 (or 255.255.255.254).
A sample topology is given below. In this scenario, device R1 is being configured as the seed device.
The e0/0 interface on device R1 is configured with the auto-IP address 10.1.1.1 and the e0/1 interface on device R2 is configured with the auto-IP address 10.1.1.3.
To configure R1 as the seed device, 10.1.1.1 must be configured as the IP address of the interface e0/0. By configuring the IP address of e0/0 interface of R1 to its auto-IP address, R1 is configured as the seed device and the interface e0/0 becomes the owner of the subnet.
The process of configuring the device R1 as the seed device is given below:
After a connection is established between the devices R1 and R2, R1 sends a Link Layer Discovery Protocol(LLDP) packet which contains an auto-IP Type Length Value (TLV) with priority 2.
10.1.1.1 | 10.1.1.1 | 2 |
On receiving the auto-IP TLV from R1, R2 derives the IP address for the interface e0/1 (by subtracting 1 from the last octet of R1's auto-IP address), and assigns the IP address 10.1.1.0/31 to R2's e0/1 interface. The interface e0/1 on R2 becomes the non-owner interface on this subnet.
The IP address allocation is displayed in the illustration given below:
The device and node interface details for the subnet are given below:
R1 | e0/0 | 10.1.1.1/31 | Owner |
R2 | e0/1 | 10.1.1.0/31 | Non-owner |
To insert a device into an existing auto-IP ring, the node interfaces of the device must be configured with the auto-IP address.
The topology in the illustration below shows a sample scenario.
Device R1 is configured as the seed device. Interface e0/0 on R1 is configured with the IP address 10.1.1.1/31, and is the owner of the subnet connecting R1 and R2. Interface e0/1 on device R2 has the IP address 10.1.1.0/31, and is the non-owner interface of the subnet.
Device R3 is inserted between R1 and R2. The two designated node interfaces e0/0 and e0/1 of R3 are configured with the auto-IP address 10.1.1.5. After insertion of the device, the ring topology appears as shown in the illustration below:
R1 sends an auto-IP Type Length Value (TLV) with priority 2 to the e0/0 interface of R3.
After receiving the auto-IP TLV from R1, R3 sends an auto-IP TLV with priority 0 to the e0/0 interface of R1.
R1 wins the election process and the interface e0/0 of R1 is designated as the owner interface on the subnet connecting R1 and R3.
The e0/0 interface on R3 becomes the non-owner interface and the IP address 10.1.1.0 is assigned to it.
The other node interface on R3 is designated as an owner interface and its auto-IP address (10.1.1.5) is assigned as the IP address of the interface.
R3 sends an auto-IP TLV with priority 2 to the e0/1 interface of R2.
After receiving the auto-IP TLV from R3, R2 sends an auto-IP TLV with priority 0 to the e0/1 interface of R3.
R3 wins the election process and its interface e0/1 is designated as the owner interface on the subnet connecting R3 and R2.
The e0/1 interface on R2 is designated as the non-owner interface, and the IP address 10.1.1.4 is assigned to it.
The other node interface on R2 is designated as the owner interface and its auto-IP address is assigned as the IP address.
The IP addresses that are configured for the owner and non-owner interfaces on the devices R1, R2, and R3 are given below:
R1 | e0/0 | 10.1.1.1/31 | Owner |
R3 | e0/0 | 10.1.1.0/31 | Non-owner |
R3 | e0/1 | 10.1.1.5/31 | Owner |
R2 | e0/1 | 10.1.1.4/31 | Non-owner |
The topology in the illustration below shows a sample scenario:
In the topology, device R3 is removed from the auto-IP ring and device R1 is connected to R2. As a result, auto-IP Type Length Value (TLVs) are exchanged between R1 and R2. Since the e0/0 interface of R1 sends an auto-IP TLV with priority 2 and the e0/1 interface of R2 sends an auto-IP TLV with priority 0 to the e0/0 interface on R1, the e0/0 interface of R1 is designated as the owner interface on the subnet connecting R1 and R2. R1 assigns the IP address to the e0/1 interface on R2, and it becomes the non-owner interface on this subnet.
After the removal of R3 from the auto-IP ring, the ring topology looks like this:
The IP address of the owner and non-owner interfaces on the subnet are given below:
R1 | e0/0 | Owner |
R2 | e0/1 | Non-owner |
The auto-swap technique automatically resolves conflicts due to incorrect insertion of a device into an auto-IP ring.
If you remove a device from an auto-IP ring, the owner and non-owner auto-IP configuration on the node interfaces is retained. You can insert the device back into an auto-IP ring.
If you incorrectly insert a device into a ring with its interfaces swapped (due to which two owner interfaces and two non-owner interfaces are connected to each other, rather than a connection between an owner and a non-owner interface), then identical priority values are exchanged between interfaces during the auto-IP Type Length Value (TLV) transmission. This leads to a tie in the priority value that is exchanged between the node interfaces of the inserted device, and a conflict is detected.
The auto-swap technique resolves conflicts on both the node interfaces of the inserted device and allows allocation of IP addresses for the interfaces.
In this topology, device R3 is incorrectly inserted between the devices R1 and R2, with its interfaces swapped. The conflict arises due to incorrect insertion, as given below:
The auto-IP TLV exchange details between R1 and R3 are given below:
Since the same priority value of 2 is sent in both instances, there is a tie during the election process, leading to a conflict.
Similarly, the same priority value of 0 is exchanged between the e0/0 interface of R3 and the e0/1 interface of R2 since they are non-owner interfaces, leading to a conflict.
The auto-IP feature uses the auto-swap technique to resolve conflicts on both the node interfaces of the inserted device.
The priority and the interface IP address of the e0/1 interface on R3 is swapped with the priority and the interface IP address of the e0/0 interface on R3, respectively.
After swapping, the following auto-IP TLV information is exchanged between R1 and R3:
Since the priority sent by R1 to R3 is higher than the priority sent by the interface e0/1 on R3, R3 derives the IP address 10.1.1.0 for the e0/1 interface from the auto-IP address of R1 (10.1.1.1).
The following auto-IP TLV information is exchanged between R3 and R2:
R2 detects the priority sent by R3 to be higher than the priority sent by its interface e0/1 and derives the IP address 10.1.1.4 from the auto-IP address of R3 (10.1.1.5).
After conflict resolution, the topology looks like this:
The e0/1 interface on R3 is designated as a non-owner interface and the e0/0 interface on R3 is designated as the owner interface.
You must configure at least one seed device in an auto-IP ring. To configure a seed device, you must configure the auto-IP address on the two node interfaces of the device (for a specific ring), and use the same IP address to configure the IP address on one of the two node interfaces.
Understand these concepts before configuring auto-IP on virtual routing and forwarding instance (VRF) interfaces, Switch Virtual Interfaces (SVIs), and EtherChannels:
1. enable
2. configure terminal
3. lldp run
4. interface type number
5. auto-ip-ring ring-id ipv4-address auto-ip-address
6. exit
7. interface type number
8. auto-ip-ring ring-id ipv4-address auto-ip-address
9. ip address interface-ip-address subnet-mask
10. end
11. show auto-ip-ring [ ring-id ][ detail ]
Command or Action | Purpose | enable | Enables privileged EXEC mode. Enter your password if prompted.
|
---|---|---|---|
configure terminal | Enters global configuration mode. | ||
lldp run | Enables Link Layer Discovery Protocol (LLDP) for the device. | ||
interface type number | Specifies an interface type and number, and enters interface configuration mode. | ||
auto-ip-ring ring-id ipv4-address auto-ip-address | Configures the auto-IP address on the specified interface. | ||
exit | Exits interface configuration mode and enters global configuration mode. | ||
interface type number | Specifies an interface type and number, and enters interface configuration mode. | ||
auto-ip-ring ring-id ipv4-address auto-ip-address | Configures the auto-IP address on the specified interface. | ||
ip address interface-ip-address subnet-mask | The specified interface is designated as the owner interface of the seed device. |
Returns to privileged EXEC mode.
Displays auto-IP information.
To insert a device into an auto-IP ring or to enable node interfaces in an existing ring, you must configure the auto-IP address on the 2 designated node interfaces of the device.
This task is applicable for a non-seed device in an auto-IP ring. Ensure that a seed device is configured for the auto-IP ring before performing this task.
Perform the steps given below to configure the auto-IP functionality on the two node interfaces of a device:
10. show auto-ip-ring [ ring-id ][ detail ]
Command or Action | Purpose | enable | Enables privileged EXEC mode. Enter your password if prompted.
|
---|---|---|
configure terminal | Enters global configuration mode. | |
lldp run | Enables Link Layer Discovery Protocol (LLDP) for the device. | |
interface type number | Specifies an interface type and number, and enters interface configuration mode. | |
auto-ip-ring ring-id ipv4-address auto-ip-address | Configures the auto-IP address on the specified interface. | |
exit | Exits interface configuration mode and enters global configuration mode. | |
interface type number | Specifies an interface type and number, and enters interface configuration mode. | |
auto-ip-ring ring-id ipv4-address auto-ip-address | Configures the auto-IP address on the specified interface. | |
end | Returns to privileged EXEC mode. | |
show auto-ip-ring [ring-id][detail] | Displays auto-IP information. |
Perform this task to verify auto-IP functions.
auto-ip-ring command is presented twice. One of the examples displays auto-IP ring information for virtual routing and forwarding instance (VRF) interfaces, and the other example displays auto-IP ring information for non-VRF interfaces. |
2. show auto-ip-ring [ ring-id ][ detail ]
3. show auto-ip-ring [ ring-id ][ detail ]
4. debug auto-ip-ring { ring-id { errors | events } | errors | events }
IMAGES
VIDEO
COMMENTS
The " Obtain an IP address automatically " option basically boiled down to attempting DHCP, and if that failed, using the Alternate Configuration tab (which was usually unconfigured, resulting in APIPA assigning an IPv4 (169.254.*) link-local address. The " Use the following address " option resulted in a static IP, not causing DHCP or Link ...
The public IP can be received in two ways: Allocate an Elastic IP address and manually attach it to the instance; Enable auto-assign public IPv4 address option and receive a public IP address from the Amazon pool. If you enable auto-assign public IPv4 address, your instance will automatically receive a public IP address at launch.
The IPv6 address is assigned from the IPv6 address range of the subnet, and is assigned to the network interface with the device index of eth0. To assign an IPv6 address during instance launch Follow the procedure to launch an instance , and when you configure Network Settings , choose the option to Auto-assign IPv6 IP .
Click Start , click Run , type "winipcfg" (without the quotation marks), and then click OK . Click More Info . If the IP Autoconfiguration Address box contains an IP address within the 169.254.x.x range, Automatic Private IP Addressing is enabled. If the IP Address box exists, automatic private IP addressing is not currently enabled.
APIPA (Automatic Private IP Addressing): APIPA is a feature available in some operating systems that enables automatic IP address assignment without the need for a DHCP server. When a device is unable to obtain an IP address from a DHCP server, it automatically assigns itself an IP address from the reserved range of 169.254../16.
This option pulls an IP address from Amazon's public IP address pool and assigns it to your instance. The auto-assign option is set via the launch wizard's auto-assign Public IP setting, as shown in the image below. There are three values to choose from, "Use subnet setting", "enable", or "disable". The "enable" and "disable" values do exactly ...
Private IPv4 addresses. Private IPv4 addresses (also referred to as private IP addresses in this topic) are not reachable over the internet, and can be used for communication between the instances in your VPC. When you launch an instance into a VPC, a primary private IP address from the IPv4 address range of the subnet is assigned to the default network interface (eth0) of the instance.
Select EC2 instance> Actions>Networking> Manage Ip Addresses. Then use option "To add or edit an IPv4 public IP Allocate an Elastic IP to this instance or network interface". Create an elastic IP. Navigate to Elastic IP address link> click Associate IP. Select the instance to associate IP and save.
Under Auto-assign IP settings, deselect the Enable auto-assign public IPv4 address checkbox to disable the auto-assign IP feature for public IPv4 addresses or the Enable auto-assign public IPv6 address checkbox to disable the feature for IPv6 addresses. Choose Save to apply the configuration changes.
In this tutorial, we studied the Automatic Private IP Address. APIPA is a mechanism to enable local networked communication even without manual configuration of IP addresses and without a DHCP server. We explored the technical characteristics of APIPA and how it executes the process of IP address self-assignment.
The rule is NON_COMPLIANT if Amazon VPC has subnets that are assigned a public IP address. Identifier: SUBNET_AUTO_ASSIGN_PUBLIC_IP_DISABLED. Resource Types: AWS::EC2::Subnet. Trigger type: Configuration changes. AWS Region: All supported AWS regions.
Step 3: Enable Allocation of Public IP Addresses. Finally, check Enable auto-assign public IPv4 address, and select Save . Any EC2 instance provisioned in this subnet will now be assigned a public IP address.
The auto-IP address is assigned to the owner-interface when the device is introduced into an auto-IP ring. Since each auto-IP address contains an odd number in the last octet, the IP address derived by subtracting 1 from the last octet is an even number, and is not used for designating auto-IP addresses. ... VRF—If you intend to enable auto ...
The configuration. In many scenarios, including this one, the Ipv4NetworkConfigurator module can properly configure the network using just the default settings. Thus, the configuration in omnetpp.ini for this step is basically empty: [Config Step1] sim-time-limit = 500s network = ConfiguratorA description = "Fully automatic IP address ...
Select the subnet to enable auto-assign public IP . Click on the Actions button and select Modify auto-assign IP settings . Check the Enable auto-assign public IPv4 address checkBox to enable the auto-assign public IPv4 address and click on the Save button. Using AWS CLI: To change a subnet's public IPv4 addressing behavior
a specific IP address; full control over the address assignment; Since the Dynamic Host Configuration Protocol (DHCP) can take the Media Access Control (MAC) address into account when assigning the network-layer address, we might still automatically receive the same IP on each connection with that protocol.
Sounds easy, simply just set the subnet not automatically to assign a public IP. But here's the catch, the subnet previously had IP auto-assignment enabled, and current servers don't play nice ...
This helps our maintainers find and focus on the active issues. If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further. Successfully merging a pull request may close this issue. This option is visible in the subnet status ...
@Ichimokuzero, could you check if your public subnets have the 'Auto-assign public IPv4 address' property set to 'Yes'? And double check that you put your instance in the proper subnet. Normally it should assign a public IP address if we place the instance in the public network. -
(B) IP addresses are assigned only to servers that host Web sites; user devices do not require an IP address. (C) New devices are connected to the Internet without an IP address, but are eventually assigned an IP addressonce they can be verified by a certificate authority. (D) New devices are connected to the Internet without an IP address; IP ...
One or more Amazon EC2 Subnets of [] for node group does not automatically assign public IP addresses to instances launched into it. If you want your instances to be assigned a public IP address, then you need to enable auto-assign public IP address for the subnet. See IP addressing in VPC guide: