cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
670
Views
4
Helpful
6
Replies

switport access and trunking

mguzman4158
Level 1
Level 1

Hi all, I came accross a configuration in one of the ports of a 6509 switch running ios (s72033_rp-JK9SV-M), Version 12.2(18)SXD3. I thought you can have a port configured either switchport access or switchport trunk but not both.

interface FastEthernet2/21

no ip address

speed 100

duplex full

switchport

switchport access vlan 130

switchport trunk encapsulation dot1q

switchport mode trunk

rmon collection stats 6068 owner monitor

spanning-tree portfast

end

Any input would be appreciate it.

Cheers!

2 Accepted Solutions

Accepted Solutions

Edison Ortiz
Hall of Fame
Hall of Fame

The mode is what counts, in your case the switchport is set to trunk.

The switchport access is there just in case the remote device does not negotiate the trunk connection.

You can verify the operational state in the interface with the command show interface fa2/21 switchport

HTH,

__

Edison.

View solution in original post

If a server is connecting to this switchport, more than likely is using Vlan 1 as the native/access Vlan.

As Glen pointed out, the mode is set to trunk unconditionally, so regardless the remote connection, the operational state will remain as trunk.

If Vlan 130 is the Vlan for 10.10.10.30/26, then you either need to change the native Vlan in the trunk from Vlan 1 to Vlan 130 with the command, switchport trunk native vlan 130 or change the mode from trunk to access with the command switchport mode access

Again, the command I gave you before should've informed you about the native Vlan.

HTH,

__

Edison.

View solution in original post

6 Replies 6

glen.grant
VIP Alumni
VIP Alumni

In that case the access statement means nothing because the trunk command is forced on , so it will uncondtionally try to trunk , it cannot be access port unless you remove the switchport mode trunk command.

Edison Ortiz
Hall of Fame
Hall of Fame

The mode is what counts, in your case the switchport is set to trunk.

The switchport access is there just in case the remote device does not negotiate the trunk connection.

You can verify the operational state in the interface with the command show interface fa2/21 switchport

HTH,

__

Edison.

Thank you all for replying, one last questions, will the switchport access vlan statement create any anomalies? like routing issues or things like that?

Thank you again!!!

Cheers!

No, it shouldn't create any problems.

Are you experiencing any?

__

Edison.

yes I am, there is a server plugged in to that port, the server has an ip of (example) 10.10.10.30/26 the vlan hrsp vip is 10.10.10.60/26 - folks from another branch can ping the vip accross the wan, but can not ping the device 10.10.10.30

If a server is connecting to this switchport, more than likely is using Vlan 1 as the native/access Vlan.

As Glen pointed out, the mode is set to trunk unconditionally, so regardless the remote connection, the operational state will remain as trunk.

If Vlan 130 is the Vlan for 10.10.10.30/26, then you either need to change the native Vlan in the trunk from Vlan 1 to Vlan 130 with the command, switchport trunk native vlan 130 or change the mode from trunk to access with the command switchport mode access

Again, the command I gave you before should've informed you about the native Vlan.

HTH,

__

Edison.

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Review Cisco Networking products for a $25 gift card