Options

Native vlan and Vlan 1

aljuganaljugan Member Posts: 36 ■■□□□□□□□□
Hellow friends
i cant understand the native vlan concept can anybody explain me that why native vlan is by default vlan1 and if we change native vlan to another vlan what will happen???is it true that native vlan consist of all trunk ports???.....Thanks a lot for all the peoples who respond our threads and the management of this informative forum..

Comments

  • Options
    powmiapowmia Users Awaiting Email Confirmation Posts: 322
    By default, the native vlan is vlan 1, because that's the way Cisco codes it into their switches. I'm assuming when they first came up with that, it's merely because vlan 1 is the first vlan on the list :) Not to get side-tracked, but maybe a comparison will explain "why" they bothered; Juniper doesn't have the concept of native vlans. It's either a standard tagged vlan, or no vlan (the default vlan). So that's two completely different approaches that Cisco and Juniper took. Juniper switches come with a physical out-of-band management interface, while Cisco switches do not. So, in order to manage a Cisco switch out of the box, you need an interface to be able to put an IP address on it.... interface vlan 1, which can't be deleted. They couldn't do that with Junipers approach of the default vlan not really being a vlan.... since you can't configure "interface vlan default." So they picked a vlan (1st on the list) and said anything coming into a new switch out of the box, without any vlan tagging, belongs to this vlan... and you just need to put an IP on its interface to be able to log into the device.

    Anyways, the term "native" just means that it's a vlan without a tag on it. Again, not all vendors support this concept either. By default, all trunks have a native vlan... and that happens to be vlan 1, but can (and should) be changed on each trunk port. If you change it, another switch that you're connected to will just begin receiving frames for that vlan with an 802.1q tag, instead of without. Or, you can tell the switch to not use the native vlan concept (tag all vlans, even the native vlan), by issuing the global command "vlan dot1q tag native."

    Keep in mind that if you change the vlan on one side of a trunk, but not the other side (on a neighboring switch) you will have issues. This is because if you send an untagged vlan from one switch that thinks anything untagged on that link belongs to vlan 1, while the receiving switch thinks anything untagged belongs to, say, vlan 2... your frames will be changing vlan membership midstream. If you do something like this on a Cisco network, you have the wonderful proprietary protocols of CDP and DTP that will spit out informational warnings and disable forwarding, respectively, in order to keep spanning-tree consistent.
  • Options
    docricedocrice Member Posts: 1,706 ■■■■■■■■■■
    powmia wrote: »
    Juniper switches come with a physical out-of-band management interface, while Cisco switches do not.

    Even with access switches like a 2360? Isn't the rear-port interface considered an out-of-band management port that's not part of the general switch fabric?
    Hopefully-useful stuff I've written: http://kimiushida.com/bitsandpieces/articles/
  • Options
    powmiapowmia Users Awaiting Email Confirmation Posts: 322
    Yeah, I was referring to why their switches are like that... as in, why they did that to begin with (or at least my impression of why). Some of the newer switches do have oob mgmt ports... the Nexus line does, and some of the newer catalysts. Thanks for pointing that out.
  • Options
    aljuganaljugan Member Posts: 36 ■■□□□□□□□□
    Thanks a lot for your answer very well explained........
  • Options
    edmasseyedmassey Registered Users Posts: 1 ■□□□□□□□□□
    Hi All, completely new to forums and am learning ICND 1, CCENT. I have a fundamental question I think, I have PT. I have a switch with the vlan int allocated an ip address. I have a port assigned as a trunk. It is connected to a router and the vlan ip address is assigned. comms is green on PT. I cannot ping between them. (both ip's in same network, both assigned to vlan1 int on respective devices). I tried to configure the port on the router for encapsulation dot1q but this is not possible without sub-interfacing. WHen I sub interface I have to give it a different network ip address otherwise it overlaps with the vlan int ip address. Without creating multiple vlans, I'm just trying to get the default to work but falling at the first hurdle it seems?many thanks Ed
  • Options
    powmiapowmia Users Awaiting Email Confirmation Posts: 322
    Either:

    On the router, remove the IP address from the physical interface and move it to a subint using dot1q that matches your switch vlan.

    Or:

    On your switch, change the native vlan of the trunk port to the vlan that you have your IP configured on.

    Or:

    On your switch, change the trunk port to an access port... accessing the vlan that you have your IP configured on.

    Next time you should start a new thread with brief description of your post, instead of reusing another thread.
  • Options
    WilyOneWilyOne Member Posts: 131
    powmia wrote: »
    maybe a comparison will explain "why" they bothered; Juniper doesn't have the concept of native vlans. It's either a standard tagged vlan, or no vlan (the default vlan). So that's two completely different approaches that Cisco and Juniper took. Juniper switches come with a physical out-of-band management interface, while Cisco switches do not. So, in order to manage a Cisco switch out of the box, you need an interface to be able to put an IP address on it.... interface vlan 1, which can't be deleted. They couldn't do that with Junipers approach of the default vlan not really being a vlan....
    Thanks powmia, very informative, especially since I want to learn Juniper next.
Sign In or Register to comment.