Understanding Access and Trunk Links in VLAN

Understanding Access and Trunk Links in VLANs

Theory#

An access link is a link that is part of only one VLAN, and normally access links are for end devices. An access-link connection can understand only standard Ethernet frames. Switches remove any VLAN information from the frame before it is sent to an access-link device.

A Trunk link can carry multiple VLAN traffic and normally a trunk link is used to connect switches to other switches or to routers. A trunk link is not assigned to a specific VLAN. Multiple VLAN traffic can be transported between switches using a single physical trunk link.

Chart, diagram Description automatically
generated{width="5.052083333333333in" height="3.2708333333333335in"}

Figure 30‑1: Understanding Access and Trunk Links in VLANs

Access link

Access link connection is the connection where switch port is connected with a device that has a standardized Ethernet NIC. Standard NIC only understand IEEE 802.3 or Ethernet II frames. Access link connection can only be assigned with single VLAN. That means all devices connected to this port will be in same broadcast domain.

For example, twenty users are connected to a hub, and we connect that hub with an access link port on switch, then all of these users belong to same VLAN. If we want to keep ten users in another VLAN, then we need to plug in those ten users to another hub and then connect it with another access link port on switch.

Trunk link

Trunk link connection is the connection where switch port is connected with a device that is capable to understand multiple VLANs. Usually trunk link connection is used to connect two switches. A VLAN can span anywhere in network, and that can happen due to trunk link connection. Trunking allows us to send or receive VLAN information across the network. To support trunking, original Ethernet frame is modified to carry VLAN information.

Network Setup#

Open NetSim and click on Experiments> Advanced and Routing> Understanding Access and Trunk Links in VLANs then click on the tile in the middle panel to load the example as shown in below Figure 30‑2.

Graphical user interface, text, application Description automatically
generated{width="6.427083333333333in" height="3.4277777777777776in"}

Figure 30‑2: List of scenarios for the example of Understanding Access and Trunk Links in VLANs

NetSim UI displays the configuration file corresponding to this experiment as shown below Figure 30‑3.

Chart, line chart Description automatically
generated{width="4.572916666666667in" height="2.6458333333333335in"}

Figure 30‑3: Network set up for studying the L3 Switch Access and Trunk Links in VLANs

Procedure#

The following set of procedures were done to generate this sample:

Step 1: A network scenario is designed in NetSim GUI comprising of 4 Wired Nodes and 2 L3 Switches in the "Internetworks" Network Library.

Step 2: In the INTERFACE (ETHERNET) > NETWORK LAYER Properties, set the following Table 30‑1.


Node Wired Node 3 Wired Node 4 Wired Node 5 Wired Node 6


              I/f1_Ethernet   I/f1_Ethernet   I/f1_Ethernet   I/f1_Ethernet

IP Address 192.168.1.3 192.168.1.4 192.168.2.3 192.168.2.4

Default Gateway 192.168.1.1 192.168.1.2 192.168.2.1 192.168.2.2

Subnet Mask 255.255.255.0 255.255.255.0 255.255.255.0 255.255.255.0


Table 30‑1: Network Layer Properties

NOTE:* The subnet mask of all L3 Switch interfaces is set to 255.255.255.0***

Step 3: L3 Switch 1 and L3 Switch 2 properties are set as follows:


Switch I/f1_Ethernet I/f2_Ethernet I/f3_Ethernet


                IP Address        IP Address         IP Address

L3 Switch 1 192.168.1.1 192.168.3.1 192.168.2.1

L3 Switch 2 192.168.1.2 192.168.3.2 192.168.2.2


Table 30‑2: L3 Switch 1 and L3 Switch 2 properties

{width="6.489583333333333in" height="4.916666666666667in"}

Figure 30‑4: Datalink layer properties window


L3 Switch 1


Interface ID VLAN Status VLAN ID VLAN Port Type

Interface_1 TRUE 2 Access _Port

Interface_2 TRUE 1 Trunk _Port

Interface_3 TRUE 3 Access _Port


Table 30‑3: VLAN Properties for L3 Switch 1


L3 Switch 2


Interface ID VLAN Status VLAN ID VLAN Port Type

Interface_1 TRUE 2 Access _Port

Interface_2 TRUE 1 Trunk _Port

Interface_3 TRUE 3 Access _Port


Table 30‑4: VLAN Properties for L3 Switch 2

Step 4: In the INTERFACE (ETHERNET) > DATALINK LAYER Properties of L3 Switch 1, Click on "Configure VLAN" to view the properties for VLAN 2 set as per the screenshot shown below Figure 30‑5.

{width="6.5in" height="5.072916666666667in"}

Figure 30‑5: Configuring VLAN Properties in VLAN 2

Properties for VLAN 3 is set as per the below screenshot Figure 30‑6.

{width="6.135416666666667in" height="4.788378171478565in"}

Figure 30‑6: Configuring VLAN Properties in VLAN 3

After setting the properties of VLAN2 and VLAN3 click on OK.

Step 5: In the NETWORK LAYER Properties of L3 Switch 1, Enable - Static IP Route -> Click on "Configure Static Route IP" to set static route as per the screenshot shown below.

{width="5.822916666666667in" height="2.221846019247594in"}

Figure 30‑7: Select Configure Static Route IP

Set the properties in Static Route IP window as per the screenshot below and click on Add.

Click on OK

{width="6.5in" height="4.375in"}

Figure 30‑8: Configure Static route in Static Route IP window

NOTE:* Transport Protocol is set to UDP* in Application properties.

Step 6: Enable the plots and run simulation for 10 seconds and observe the throughput.

Output#


Throughput (Mbps)


Application 1 0.58

Application 2 0.58


Table 30‑5: Results Comparison

The above results conclude that trunking allows us to send or receive any VLAN information across the network.