OpenWrt Forum Archive

Topic: linksys wrt1900acs switch configuration

The content of this topic has been archived on 1 May 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

Hello,

I'm trying to configure my new linksys router to connect to internet which is provided on a vlan. I have another openwrt router which connect very well, but I was not able to configure this one. I have the following switch configuration:

config interface 'lan'
    option type 'bridge'
    option proto 'static'
    option netmask '255.255.255.0'
    option ip6assign '60'
    option ipaddr '192.168.2.1'
    option _orig_ifname 'eth1 radio0.network1 wlan1'
    option _orig_bridge 'true'
    option ifname 'eth1.2 wlan1'

config interface 'wan'
    option proto 'dhcp'
    option _orig_ifname 'eth0'
    option _orig_bridge 'true'
    option delegate '0'
    option ifname 'eth0.34'
    option type 'bridge'

config switch
    option name 'switch0'
    option reset '1'
    option enable_vlan '1'
    option enable_vlan4k '1'

config switch_vlan
    option device 'switch0'
    option vlan '2'
    option ports '0 1 2 3 6t'

config switch_vlan
    option device 'switch0'
    option vlan '34'
    option ports '4t 5t'

34 is the id of the VLAN i need to connect to. swconfig dev switch0 show shows that even though the cable is connected, the link is still down:

...
Port 4:
    mask: 0x0000: (4)
    qmode: 3
    pvid: 0
    link: port:4 link:down
Port 5:
    mask: 0x0000: (5)
    qmode: 3
    pvid: 0
    link: port:5 link:up speed:1000baseT full-duplex
Port 6:
    mask: 0x0000: (6)
    qmode: 3
    pvid: 0
    link: port:6 link:up speed:1000baseT full-duplex
VLAN 2:
    port_based: 0
    vid: 2
    ports: 0 1 2 3 6t
VLAN 34:
    port_based: 0
    vid: 34
    ports: 4t 5t

Can anyone point me to what is going wrong with this configuration?

The 'swconfig' tools shows the physical status of the link. If it states that port #4's link is down, it means there's no physical connection from port #4 to whatever device you are connecting it to.

Check your cables and the connectors. If your cables and connectors are fine, then you have a configuration issue.

remme wrote:

Can anyone point me to what is going wrong with this configuration?

Your 'swconfig' output shows ports 5 and 6 are connected. I'd say you need to change the '4t' to '6t' in VLAN 34 so that the uplink terminates at your router instead of being redirected out of port 4. It seems port 5 maps to the physical "WAN" port on your router from where you want to receive the uplink, and port 6 is the CPU-facing port where you want to lead it to.

The image at https://wiki.openwrt.org/doc/uci/network/switch will probably give you an insight on what the port numbers mean.

(Last edited by Antek on 19 Jul 2017, 09:44)

Thanks for the answer. I'm pretty sure that port 4 is the "WAN" port. when I connect it to other devices except for my fiber 'modem' it says connected. port 5 and 6 are connected to the cpu, being eth0 and eth1.
See: the linksys/wrt_ac_series openwrt wiki page.

Now I think the problem lies in the fact it says the link is down and it doesn't make a physical connection. With any other device the connection light on my fiber modem is on. With this router it just blinks every two seconds or so.

Remme wrote:

Thanks for the answer. I'm pretty sure that port 4 is the "WAN" port. when I connect it to other devices except for my fiber 'modem' it says connected. port 5 and 6 are connected to the cpu, being eth0 and eth1.
See: the linksys/wrt_ac_series openwrt wiki page.

Thanks for the link. I didn't know about the internal wiring of the router, so I just made an informed guess about the port numbers. Sorry for mixing things up smile

It looks like that the switch is not compatible with specific other hardware. I found this thread:  community.linksys.com/t5/Wireless-Routers/WRT1900AC-VLAN-Problem/td-p/925683. It happens that I also try to connect the router to a Genexis fiber modem and it describes exactly the problem I have.

Is there anyone else who has trouble connecting this router to certain specific hardware?

I'm going for the solution to connect an extra managed switch in between the router and modem.

The discussion might have continued from here.