Attach a VLAN to a Linode
Within Cloud Manager, VLANs are created and managed only by attaching them to Linodes. They are not managed independently. You can attach a VLAN when creating a new Linode or when editing an existing Linode.
This guide covers implementing both of these methods using Cloud Manager.
Attaching a VLAN when creating a Linode
-
On the top left of Cloud Manager, click Create and select Linode.
-
Fill out all desired configuration options in the form that appears, until reaching the Networking section. See the Creating a Linode guide for more information.
VLANs are not available in all regions. If the Attach a VLAN section isn't visible, see the Availability section on the VLANs Overview page.
-
Within the Network Connection section, select VLAN.
-
If the VLAN already exists, it can be selected from the drop down list. If the VLAN doesn't yet exist,enter a label, and the VLAN will be created automatically when you create the Linode.
-
Optionally enter the IPv4 address you wish to assign to the VLAN's network interface on this machine. The IP address should be unique to avoid conflicts in the case other machines share the same address. If this field is left blank, the Linode will not be able to communicate with other Linodes on that VLAN until one of the following is true:
- An IPAM address is added to the
eth1interface within the Linode's Configuration Profile - An IP address is manually assigned to the network interface within the Linode's internal configuration files.
See the Assigning an IPAM Address section on the Get Started guide for more information about IPAM and examples of valid IPAM addresses.
- An IPAM address is added to the
-
Complete the create form with any additional add-ons and settings you'd like to use. Then click the Create Linode button.
By default, the public IP address (and, if added, the private IP address) of the Linode is configured on the eth0 network interface. The VLAN, if one was attached, is configured on the eth1 network interface. Configuration profile network interfaces can be removed or modified by editing the Configuration Profile. You can delete or add Linode interfaces, but you can't modify them. Learn more.
Attaching a VLAN to an existing Linode
-
Within Cloud Manager, click the Linodes link in the sidebar and select a Linode.
-
Follow the steps in the table based on whether your Linode uses configuration profile interfaces or Linode interfaces.
| Configuration Profile Interfaces | Linode Interfaces | |
|---|---|---|
| 3. | Navigate to the Configurations tab for that Linode. | Power Off the Linode and select the Network tab for that Linode. |
| 4. | Select the Edit option next to the configuration profile you'd like to modify. An Edit Configuration screen will appear. Scroll down to the Networking section. | Click the Add Network Interface button. An Add Network Interface drawer appears. |
| 5. | Click the dropdown menu under the desired network interface and select VLAN. Typically eth1 or eth2 would be used when adding the first or second VLAN to a Linode, respectively, since the Linode's eth0 network interface is typically configured to access the public internet. | Select VLAN. |
-
Enter the Label of the VLAN or select an existing VLAN from the drop down menu. If a custom label is entered and the VLAN does not yet exist, it is automatically created.
-
Optionally enter an IP (IPAM) Address. If this field is left blank, the Linode will not be able to communicate with other Linodes on that VLAN until an IP address is manually assigned to the network interface within the Linode's internal configuration files.
See the Assigning an IPAM Address section of the Get Started guide for more information about IPAM and examples of valid IPAM addresses.
-
Follow the steps in the table based on whether your Linode uses configuration profile interfaces or Linode interfaces.
| Configuration Profile Interfaces | Linode Interfaces | |
|---|---|---|
| 9. | Click on the Save Changes button. | Click on the Add Network Interfaces button. |
| 10. | Once the configuration profile has been updated, select the Boot or Reboot button next to the edited configuration profile on the following page. This will reboot using the edited configuration profile and apply the new VLAN configuration to the Linode. | Once the Linode interface is added, Power On the Linode to apply the new VLAN interface to the Linode. |
Testing connectivity
Once a VLAN has been attached to more than one Linode, verify that you can communicate between those Linodes over the VLAN's private network.
-
If the Linode has a public network configured, connect to it via SSH. See Setting Up and Securing a Linode > Connect to the Linode.
ssh username@192.0.2.1If the Linode does not have a public network configured, connect to it via Lish by following the steps in the Using the Lish Console guide.
-
Ping another Linode within the VLAN's private network using the IPAM address assigned to it.
ping 10.0.0.1The output should display ICMP packets successfully transmitted and received from this Linode to the secondary Linode in the private network.
PING 10.0.0.1 (10.0.0.1) 56(84) bytes of data. 64 bytes from 10.0.0.1: icmp_seq=1 ttl=64 time=0.733 ms 64 bytes from 10.0.0.1: icmp_seq=2 ttl=64 time=0.294 ms ^C --- 10.0.0.1 ping statistics --- 2 packets transmitted, 2 received, 0% packet loss, time 18ms rtt min/avg/max/mdev = 0.294/0.513/0.733/0.220 ms
Updated about 9 hours ago
