New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
FS#3879 - Incorrect switch config for TP-Link Archer C2 AC750 #8871
Comments
cybermaus: I retract my "manual remove switch0 makes it work" It does make the Luci work. And the device continues to work. Until you reboot, all connections lost. Even using IPv6 link-local fe80 address. All I could do is 10 second reset. Tried several times and variants. So maybe this is a bit more urgent. Still not very urgent, but not low-low. So: My current workaround: leave switch0 in network, manually edit config for switch1 Thanks |
luja: Thank you for your solution. I have the same problem with TP-Link Archer C2 AC750 on OpenWrt 21.02.1 here. So this should be investigated and the lua for luci shall be fixed. Removing the switch0 section in /etc/config/network helped me to get proper operation! But I need to try to reboot, but do I want to reboot :-) Priority should be high as it is a show stopper if you can not access your network via the internal vlan switch Cheers ludwig |
luja: So I played around with it and found that one needs to remove the switch0 config and to disable vlan on switch0. I hacked it in an ugly way as I modified /etc/init.d/network to configure switch0: here in init_switch() I added: Please look at the attached files they also contain some "history" of looking around. To get a quick and dirty solution, upload my config The root password is "toor" the wifi password is "rattensommer" Have fun with this cheap router. |
I can confirm that...
This is the situation in
...and how it looks like in LuCI: This is the situation in
...and how it looks like in LuCI: At least for me, simply removing the offending configuration section for |
openwrt/target/linux/ramips/mt7620/base-files/etc/board.d/02_network Lines 144 to 145 in 7bf5233
@znark delete these two lines can solve the problem. |
@DragonBluep Thanks for the suggestion. I tried a custom build with those two lines removed from I believe this is because removing those two lines in So, my current takeaway is the definition of Is this actually a LuCI issue? Should LuCI be able to interpret the |
@znark I'm sorry that my misunderstanding caused you trouble. But one thing I can confirm is that lb-link,bl-w1200 (MT7530 switch) can fix the problem by this way. openwrt/target/linux/ramips/mt7620/base-files/etc/board.d/02_network Lines 142 to 145 in 7bf5233
I think you're right, it must be a problem with LuCI, switch0 configuration doesn't seem redundant. |
@DragonBluep wrote:
I think the terminology here is also a bit confusing. What does “disabling a switch” (or setting its |
I am running openwrt 22.0.3.0 at the moment. I need to update ... root@sw4:/etc/config# cat /proc/cpuinfo cat /proc/version BusyBox v1.35.0 (2022-09-03 02:55:34 UTC) built-in shell (ash) OpenWrt 22.03.0, r19685-512e76967f what did I change?you need to modify /etc/init.d/network in order to make it work! root@sw4:/etc/init.d# cat network START=20 USE_PROCD=1 init_switch() {
} start_service() {
} reload_service() {
} stop_service() { validate_atm_bridge_section() validate_route_section() validate_route6_section() validate_rule_section() validate_rule6_section() validate_switch_section() validate_switch_vlan() service_triggers()
} shutdown() { It is important to modify /etc/init.d/network in the way I did it, as switch0 needs to have vlan switched off, in order to pass the RGMII lan to the external gbit vlan switch called switch 1. look into a part of my /etc/config/network and see how VLAN is to be done on the C2: less /etc/config/network config interface 'loopback' [...] config interface 'lan' config device config interface 'wan' config interface 'wan6' config switch config switch_vlan config switch_vlan config switch_vlan config switch_vlan config switch_vlan config switch_vlan config switch_vlan config switch_vlan config switch_vlan |
edit /etc/sysupgrade.conf #modified files to make ARCHER C2 WORK #my openwrt stuff iu.sh and ui.sh are shell scripts to derive the installed packets and to reinstall them after update. you find the scripts here: here is my stuff for the archer C2: |
success: updating the TP-Link C2 to 22.03.2 └─$ ssh root@10.0.101.14 BusyBox v1.35.0 (2022-10-14 22:44:41 UTC) built-in shell (ash) | |.-----.-----.-----.| | | |.----.| |_
|
cybermaus:
Model TP-Link Archer C2 v1
Architecture MediaTek MT7620A ver:2 eco:5
Firmware Version OpenWrt 21.02.0-rc2 r16122-c2139eef27 / LuCI openwrt-21.02 branch git-21.148.49484-14511e5
The Archer C2 has a little unusual switch setup, in that the SoC itself only has an unused 100Mb switch and instead there is an extra RTL8367B chip. We can only assume TP-Link wanted to make this a 1Gb device, despite using a 100Mb SoC. (and indeed, the 1Gb ports is why I got this particular cheap device)
OpenWRT 19.07.7 handled this beautifully, as it simply did not show the switch0, neither in UCI nor in Luci, though the RTL8367B chip is labeled switch1 in stead of the more usual switch0
When clean upgrading (so removing and rebuilding all config) to 21.02.0-rc2 I noticed that the internal switch was now populated in UCI and displayed in Luci
The Archer C2 does work, switch1 is configured as expected, but the presence of switch0 seems to cause Luci to display an error "Switch switch0 has an unknown topology - the VLAN settings might not be accurate." and further prevents Luci from updating switch1 settings.
So the presence of switch0 in UCI is confusing and unneeded, and also prevents Luci from working.
Manually removing the switch0 section from /etc/config/network makes it all work again.
/etc/config/network as generated on 19.07.7 (only the switch section)
config switch
option name 'switch1'
option reset '1'
option enable_vlan '1'
option max_length '3'
config switch_vlan
option device 'switch1'
option vlan '1'
option ports '6t 1 2 3 4'
config switch_vlan
option device 'switch1'
option vlan '2'
option ports '6t 0'
/etc/config/network as generated on 21.02.0-rc2 (only the switch section)
config switch
option name 'switch0'
option reset '1'
option enable_vlan '0'
config switch
option name 'switch1'
option reset '1'
option enable_vlan '1'
option enable_vlan4k '1'
option max_length '3'
config switch_vlan
option device 'switch1'
option vlan '1'
option ports '6t 1 2 3 4'
config switch_vlan
option device 'switch1'
option vlan '2'
option ports '6t 0'
so to restate, after manually removing the extra switch0 from rc2, it all was normal again
The text was updated successfully, but these errors were encountered: