0

I have 5 VLANs in a switch SF300 configured in Layer3. I Set the switch to general mode so I could connect all the vlans. After 2 weeks that connection has been lost. Now you can only communicate with your respective gateway.

This are the vlans.

interface vlan 2
 name "Linea Nueva" 
 ip address 10.0.0.150 255.255.255.0 
!
interface vlan 3
 name vlan_invitados 
 ip address 192.168.10.253 255.255.255.0 
!
interface vlan 4
 name "Red Administrativa" 
 ip address 10.178.5.150 255.255.255.0 
!
interface vlan 5
 name vlan_plc2 
 ip address 192.168.1.65 255.255.255.0 
!
interface vlan 6
 name vlan_plc3 
 ip address 192.168.0.150 255.255.255.0 

config-file-header
ciscoauto2
v1.3.5.58 / R750_NIK_1_35_647_358
CLI v1.0
set system mode router 

file SSD indicator encrypted
@
ssd-control-start 
ssd config 
ssd file passphrase control unrestricted 
no ssd file integrity control 
ssd-control-end cb0a3fdb1f3a1af4e4430033719968c0 
!
vlan database
vlan 2-6,700 
exit
voice vlan oui-table add 0001e3 Siemens_AG_phone________
voice vlan oui-table add 00036b Cisco_phone_____________
voice vlan oui-table add 00096e Avaya___________________
voice vlan oui-table add 000fe2 H3C_Aolynk______________
voice vlan oui-table add 0060b9 Philips_and_NEC_AG_phone
voice vlan oui-table add 00d01e Pingtel_phone___________
voice vlan oui-table add 00e075 Polycom/Veritel_phone___
voice vlan oui-table add 00e0bb 3Com_phone______________
bonjour interface range vlan 1
hostname ciscoauto2
username cisco password encrypted fc48b9daa3849fab289dd8919097ede3b9f2b3eb privilege 15 
clock timezone " " 0 minutes 0
ip telnet server
!
interface vlan 1
 no ip address dhcp 
!
interface vlan 2
 name "Linea Nueva" 
 ip address 10.0.0.150 255.255.255.0 
!
interface vlan 3
 name vlan_invitados 
 ip address 192.168.10.253 255.255.255.0 
!
interface vlan 4
 name "Red Administrativa" 
 ip address 10.178.5.150 255.255.255.0 
!
interface vlan 5
 name vlan_plc2 
 ip address 192.168.1.65 255.255.255.0 
!
interface vlan 6
 name vlan_plc3 
 ip address 192.168.0.150 255.255.255.0 
!
interface fastethernet1
 switchport default-vlan tagged 
!
interface fastethernet2
 spanning-tree link-type point-to-point 
 switchport mode general 
 macro description switch
 switchport default-vlan tagged 
 !next command is internal.
 macro auto smartport dynamic_type unknown 
!
interface fastethernet3
 spanning-tree link-type point-to-point 
 switchport mode general 
 macro description switch
 switchport default-vlan tagged 
 !next command is internal.
 macro auto smartport dynamic_type unknown 
!
interface fastethernet4
 spanning-tree link-type point-to-point 
 switchport mode general 
 switchport general allowed vlan add 700 tagged 
 macro description switch
 switchport default-vlan tagged 
 !next command is internal.
 macro auto smartport dynamic_type unknown 
!
interface fastethernet5
 switchport trunk allowed vlan add 4 
 switchport trunk native vlan 2 
 no macro auto smartport 
!
interface fastethernet6
 switchport trunk allowed vlan add 2 
 switchport trunk native vlan 4 
!
interface fastethernet7
 switchport trunk allowed vlan add 4 
 switchport trunk native vlan 2 
!
interface fastethernet8
 switchport trunk allowed vlan add 4 
 switchport trunk native vlan 2 
!
interface fastethernet9
 switchport trunk allowed vlan add 4 
 switchport trunk native vlan 2 
!
interface fastethernet10
 switchport trunk allowed vlan add 4 
 switchport trunk native vlan 2 
!
interface fastethernet11
 spanning-tree link-type point-to-point 
 switchport mode general 
 switchport general allowed vlan add 2-6 untagged 
 switchport general pvid 2 

interface fastethernet12
 spanning-tree link-type point-to-point 
 switchport mode general 
 switchport general allowed vlan add 2-6 untagged 
 switchport general pvid 6 
!
interface fastethernet13
 switchport trunk allowed vlan add 4 
 switchport trunk native vlan 2 
!
interface fastethernet14
 switchport trunk allowed vlan add 4 
 switchport trunk native vlan 2 
!
interface fastethernet15
 switchport trunk allowed vlan add 4 
 switchport trunk native vlan 2 
!
interface fastethernet16
 switchport trunk allowed vlan add 4 
 switchport trunk native vlan 2 
!
interface fastethernet17
 switchport trunk allowed vlan add 4 
 switchport trunk native vlan 2 
!
interface fastethernet18
 switchport trunk allowed vlan add 4 
 switchport trunk native vlan 2 
!
interface fastethernet19
 switchport trunk allowed vlan add 4 
 switchport trunk native vlan 2 
!
interface fastethernet20
 switchport trunk allowed vlan add 4 
 switchport trunk native vlan 2 
!
interface fastethernet21
 switchport trunk allowed vlan add 4 
 switchport trunk native vlan 2 
!
interface fastethernet22
 switchport trunk allowed vlan add 2 
 switchport trunk native vlan 4 
!
interface fastethernet23
 switchport trunk allowed vlan add 4 
 switchport trunk native vlan 2 
!
interface fastethernet24
 spanning-tree link-type point-to-point 
 switchport mode general 
 switchport general allowed vlan add 2-6 untagged 
 switchport general pvid 5 
!
interface gigabitethernet1
 spanning-tree link-type point-to-point 
 switchport mode general 
 switchport general allowed vlan add 3 tagged 
 switchport general allowed vlan add 2,4-5 untagged 
 switchport general pvid 4 
 macro description switch
 !next command is internal.
 macro auto smartport dynamic_type unknown 
!
interface gigabitethernet3
 switchport mode access 
 switchport access vlan 3 
!
exit



---------------------------------------------
C   10.0.0.0/24 is directly connected, vlan 2
C   10.178.5.0/24 is directly connected, vlan 4
C   192.168.0.0/24 is directly connected, vlan 6
C   192.168.1.0/24 is directly connected, vlan 5
C   192.168.10.0/24 is directly connected, vlan 3
5
  • Please edit your question to include the full switch configuration and routing table.
    – Ron Maupin
    Commented Apr 6, 2020 at 0:28
  • Thanks por answering, I edit the configuration and routing table. Commented Apr 6, 2020 at 0:50
  • On the interfaces where end-devices, e.g. PCs, are attached, there should be one VLAN, and it should not be tagged. You tag VLANs on trunk interfaces because trunk interfaces will have multiple VLANs, and the tags tell them apart. Interfaces to end-devices are access interfaces, and you only have a single, untagged VLAN.
    – Ron Maupin
    Commented Apr 6, 2020 at 1:00
  • Ok, but how can I connect to host with diferent vlan from the same switch. I configure mode general inferface but I don't know if this is correct. Commented Apr 6, 2020 at 3:11
  • Did any answer help you? If so, you should accept the answer so that the question doesn't keep popping up forever, looking for an answer. Alternatively, you can post and accept your own answer.
    – Ron Maupin
    Commented Dec 16, 2020 at 23:14

1 Answer 1

1

switchport mode general is obsolete - do not use. mode general allows using multiple untagged VLANs but that likely won't work with other ports as expected. It was intended for policy-driven VLANs that should be avoided for security reasons. Without policy, mode general simply doesn't work properly.

Instead, use switchport mode trunk between switches with multiple VLANs, and switchport mode access towards end nodes. With a server connecting multiple VLANs, you can use switchport mode trunk together with a single switchport trunk native VLAN x for the server's main VLAN (so you don't lose connectivity when the server's VLAN config fails or isn't up yet).

2
  • Thks, I change the configuration and use trunk in port gi4 like this interface gigabitethernet4 switchport trunk allowed vlan add 2-4,6 switchport trunk native vlan 5 then I enter command ping to another gw vlan and doesný work. Commented Apr 6, 2020 at 13:11
  • If you can ping the gateway but can't ping anywhere else, routing isn't set up properly. Have you made sure the end nodes have the switch set as (default) gateway?
    – Zac67
    Commented Apr 6, 2020 at 14:40

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.