cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
789
Views
6
Helpful
10
Replies

Does the end server (linux) understand VLAN tags?

royavi5302
Level 1
Level 1

Linux1 [eth1.20] --------[F1/1](SW1)[F1/2] --------[F1/2](SW2)[F1/1] ----------[eth1.20] Linux2

When we configure VLAN on any NIC in Linux does the server tags the packet with the VLAN?
Linux1 & Linux2 part of VLAN 20. They are configured as eth1.20. What should be the VLAN mode Trunk/Access for F1/1 & F1/2 of both switches? Considering VLAN 20 is not native on both switches?

Similar scenario when VLAN 20 is NATIVE. 

As per my understanding the end server does not understand the VLAN taging , so why do we configure VLAN on server , where we can just assign an IP that is part of that VLAN? Or my understanding is wrong?

 

2 Accepted Solutions

Accepted Solutions

Yes, this means that the ethernet frame contained in the IP packet will have a tag attached to it identifying the vlan. In this case the switch port to which the Linux is connected should be configured as a trunk.

Also the links between switches should be configured as a trunk if you want to carry multiple vlans in your network.

Regards, LG
*** Please Rate All Helpful Responses ***

View solution in original post

SW-access-Server 

No need subinterface or vlan

SW-trunk-server (multi vlan)

Here we need subinterface IP or VLAN SVI for each vlan allow in trunk between SW and Server.

MHM

View solution in original post

10 Replies 10

marce1000
VIP
VIP

 

  - In  a first approach the linux server does not need to know  about VLAN tags; it can be connected to a port being in a particular vlan. The switch takes care   of adding the vlan-tag when receiving traffic 'by default' 

 M.



-- Each morning when I wake up and look into the mirror I always say ' Why am I so brilliant ? '
    When the mirror will then always repond to me with ' The only thing that exceeds your brilliance is your beauty! '

royavi5302
Level 1
Level 1

Correct .. The question remains the same why do we configure the NICs as eth1.20 or similar? What is the purpose .. 

Also will F1/1 of both switches be access or trunk?

 

 

  >Correct .. The question remains the same why do we configure the NICs as eth1.20 or similar? What is the purpose .. 
                   Would only be needed if the server would have to bridge multiple vlans itself.

                                  >Also will F1/1 of both switches be access or trunk?
                    You only need trunk if the 'whole link' needs to carry multiple vlans

 M.



-- Each morning when I wake up and look into the mirror I always say ' Why am I so brilliant ? '
    When the mirror will then always repond to me with ' The only thing that exceeds your brilliance is your beauty! '

liviu.gheorghe
Spotlight
Spotlight

Hello @royavi5302 ,

like @marce1000 mentioned in 90% of use cases, a Linux server doesn't need to know Vlan tagging on his interfaces. Your network topology is one of this cases - just configure the switch ports in the necessary vlan, assign the servers IP addresses from the correct subnet and you are ready to go.

There are some use cases in which the server needs to send tagged traffic on his interfaces and in this case you can configure a Linux server to do that. Here is an example on how to configure this in Ubuntu: https://wiki.ubuntu.com/vlan

Hope this helps.

Regards, LG
*** Please Rate All Helpful Responses ***

Thanks for the link. I am aware of how to configure it.

---> There are some use cases in which the server needs to send tagged traffic on his interfaces: That means a server can also tag the packet before sending to switch ? A packet while leaving eth1.20 , will it have any tagging or just pacacket ?

Yes, this means that the ethernet frame contained in the IP packet will have a tag attached to it identifying the vlan. In this case the switch port to which the Linux is connected should be configured as a trunk.

Also the links between switches should be configured as a trunk if you want to carry multiple vlans in your network.

Regards, LG
*** Please Rate All Helpful Responses ***

If ther server need to connect to SW via more than one vlan the  this step need

Otherwise it not need

MHM

If I understand correctly if the port where the server is connected is configured with Multiple VLans then only we need to configure eth1.20 with IP otherwise we need not to configure VLAN on the ethernet. 

In other words if the switch port (F1/1) is a trunk one ? Correct?

SW-access-Server 

No need subinterface or vlan

SW-trunk-server (multi vlan)

Here we need subinterface IP or VLAN SVI for each vlan allow in trunk between SW and Server.

MHM

royavi5302
Level 1
Level 1

Thank you everyone. All doubts are clear. Keep rocking!

Review Cisco Networking for a $25 gift card