OpenWRT Router: One ethernet port does not work - Page 1
Forum section: electronics / general

author: soldar
author_rank: Super Contributor
timestamp: November 03, 2019, 10:11:42 pm
content: In an earlier thread I flashed a router with OpenWRT so I now have a (TP-Link TL-WR841N/ND v9, Firmware Version OpenWrt Chaos Calmer 15.05.1 / LuCI 15.05-149) router running OpenWRT.For some unknown reason one of the four LAN ports (#1) does not work. I keep forgetting and each time I plug something there it takes me a while to realize the problem is with the router port.Is there anything I can do? Any tests? Any configuration? I do not know the first thing about the router or about OPENWRT but it seems to me all four LAN ports should behave the same way. Maybe it is a hardware problem. How can I know?

author: Whales
author_rank: Super Contributor
timestamp: November 03, 2019, 10:55:24 pm
content: I was going to say "it's the WAN port", but your switching table says otherwise.Have not encountered this. I would suspect either hardware fault or firmware fault.1. Have you actually applied the settings you screenshot?2. Did the issue exist with the factory (non-OpenWRT) firmware?3. Do you even get a link light to come on when you plug another device in? Make sure it's a full desktop computer, some portable devices with RJ45's (including printers &someusb-ethernet devices) are lazy with their link detect & don't send pulses out.4. Run wireshark on a computer plugged into that port and reboot the router. See if the port gets enabled by the bootloader for a few seconds at the start of boot. If so then it's probably an OpenWRT issue.Obligatory: it would be better to ask on the LEDE/Openwrt forums

author: amspire
author_rank: Super Contributor
timestamp: November 03, 2019, 10:58:50 pm
content: I am not sure why LAN1 is not working, but I see plenty of older routers with a lan port damaged by some lightening strike-type incident. It is a 5 year old router, so it has probably been through a few storms. You can always check the LAN transformer windings work - there should be one between the green/green-white wires on the ethernet cable and one between the orange/orange-white wires. Should look like a short.Are there any LEDS on the LAN1 port connector, and if so, do they respond at all?The easiest way to check if the port works may be to revert to the TP-Link firmware.Otherwise, just put a bit of tape over LAN1 and live with 3 ports.

author: soldar
author_rank: Super Contributor
timestamp: November 03, 2019, 11:19:33 pm
content: >> Have not encountered this. I would suspect either hardware fault or firmware fault.>> 1. Have you actually applied the settings you screenshot?That is what I found by default. I have not made any changes. I was hoping it would provide some useful info.>> 2. Did the issue exist with the factory (non-OpenWRT) firmware?I do not know. It was a router I picked up from the junk. It had a proprietary firmware which I could not use and that is why I flashed it. It is all in another thread.>> 3. Do you even get a link light to come on when you plug another device in? Make sure it's a full desktop computer, some portable devices with RJ45's (including printers &someusb-ethernet devices) are lazy with their link detect & don't send pulses out.I did some tests right now. The router light flashes which means it detects the connection. The computer also detects the connection. And, what do you know? Now it's working! I get response to Ping and can access the LAN.Well, I don't know what happened. It has been not working for all this time. I wonder if it may be a bad HW connection which will happen again. I will have to keep an eye on it.I will post again if it happens again. Thanks for your help.

author: NiHaoMike
author_rank: Super Contributor
timestamp: November 04, 2019, 01:24:05 pm
content: Quote from: soldar on November 03, 2019, 11:19:33 pmBad solder joints or dirty connector.

author: Syntax Error
author_rank: Frequent Contributor
timestamp: November 06, 2019, 08:51:00 pm
content: One observation about your Luci Switch page, should the CPU(eth0) be 'tagged' as you've enabled VLAN functionality?The LAN interface will need to be hooked to the physical connection of (Switch VLAN) eth0.1I had a look at the .dtsi files on the Github repo ( ...openwrt/target/linux/ath79/dts/qca9533_tplink_tl-wr841-v9.dts etc ) and there's nothing to suggest LAN1 is configured as anything other than a LAN port.Edit > set CPU(eth0) to Tagged

author: madires
author_rank: Super Contributor
timestamp: November 06, 2019, 09:03:10 pm
content: BTW, v15 is quite old. The current release is 18.06.4.

author: Black Phoenix
author_rank: Super Contributor
timestamp: November 07, 2019, 09:27:19 am
content: Quote from: madires on November 06, 2019, 09:03:10 pmHis router is one of the 4/32 ones:https://openwrt.org/toh/hwdata/tp-link/tp-link_tl-wr841n_v9Yes it will support 18.06.4 and the new future 19.07 but nothing more after that.

author: soldar
author_rank: Super Contributor
timestamp: November 11, 2019, 01:19:39 pm
content: Quote from: madires on November 06, 2019, 09:03:10 pmSorry, I copied that from the other thread where I installed OpenWRT. Later in that thread I upgraded to what I now have: OpenWrt 18.06.4 r7808-ef686b7292 / LuCI openwrt-18.06 branch (git-19.170.32094-4d6d8bc)

author: soldar
author_rank: Super Contributor
timestamp: November 11, 2019, 01:28:27 pm
content: Quote from: Syntax Error on November 06, 2019, 08:51:00 pmI have no clue what any of this means. That's how little I know.For now the router (being used as a switch) is working OK and I am inclined not to touch it until there is some good reason to do it.

author: Syntax Error
author_rank: Frequent Contributor
timestamp: November 11, 2019, 05:33:01 pm
content: @soldar : Simply, in LuCI go to the Switch page and change the dropdown option under CPU(eth0) fromuntaggedtotagged, then save and apply < you might need to reboot. This associates the LAN ports with ethernet-zero (eth0), which is the "CPU" process running OpenWRT.You can also ask on the OpenWRT Forumhttps://forum.openwrt.org/FYI the Github repositryhttps://github.com/openwrtis thestablemirror of the development repo git.openwrt.org/openwrt and is always a good place to start hunting for answers.

author: Monkeh
author_rank: Super Contributor
timestamp: November 11, 2019, 05:50:38 pm
content: Quote from: Syntax Error on November 11, 2019, 05:33:01 pmThat would tag traffic from all ports so it appears on eth0.1, and probably lock him out. Untagged is totally fine, all traffic is on eth0. You'll note all the other ports are working just fine..The configuration is fine, and the port is faulty.

author: soldar
author_rank: Super Contributor
timestamp: November 11, 2019, 06:23:04 pm
content: Yes, as long as the thing is working I would rather not touch it.Regarding the port, it is working OK but I have not touched the cable. I am afraid it may fail again if I so much as unplug the cable. Maybe there is a bad solder or loose connection.

author: soldar
author_rank: Super Contributor
timestamp: November 11, 2019, 09:34:45 pm
content: Well, whaddayaknow, I spoke too soon. I unplugged the cable and now the port only works marginally. I guess, as has been said, it is probably a bad connection somewhere. For now I will just not use that port. When I decide to look into it I will look for the obvious and easy (bad solder, etc). If that does not fix it I might try just holding the RJ45 jack pushed in and if that works (it sometimes has worked in other cases) I will glue the jack in place.And if it still doesn't work reliably I will just block it because I keep forgetting about the problem and keep plugging things in.

author: Monkeh
author_rank: Super Contributor
timestamp: November 12, 2019, 01:22:54 am
content: And while I remember..Quote from: Syntax Error on November 11, 2019, 05:33:01 pmNo, it isn't the 'stable' mirror - it's a mirror. With all branches. Master being very much not stable.

author: soldar
author_rank: Super Contributor
timestamp: November 12, 2019, 09:58:17 am
content: This problem with the bad port is looking stranger every time I look at it.Using the Linux box, if the network cable is not connected when doing Ping the computer gives message "Network is unreachable" but when the cable is plugged into the bad port the computer says "From 192.168.10.101 Destination host unreachable". That IP address is the computer itself. So, somehow it seems the physical layer is connected but the software connection is not. Both the router and the computer show the physical cable as connected. So it is looking less like a HW problem and more like a SW problem.Just unplugging the Ethernet cable from the bad port and plugging it into another port solves the problem so it is certainly a problem with that port and not with the cable or computer.Any ideas of what kind of test I could do next?E.T.A.: Ha! After a few times testing, plugging and unplugging, one time it started working correctly and now it seems to be working continuously and reliably, like it was doing before I touched it.This reminds me of problems like an oscillator which will not start oscillating and you have to plug/unplug the device several times but once it starts it will continue to oscillate indefinitely.

author: soldar
author_rank: Super Contributor
timestamp: November 12, 2019, 01:39:34 pm
content: Jiggling the Ethernet cable at the router has no effect. If the connection is working it continues to work and if it is not working it will still not work.If it is working and I disconnect the other end, at the computer, and plug in again, then it stops working.It seems restarting the router several times will sometimes get it to work.Once it is working it will continue to work.Only happens with LAN port #1. All others work correctly.At this point it looks to me more and more like a glitch with OpenWRT.

author: Monkeh
author_rank: Super Contributor
timestamp: November 12, 2019, 01:49:13 pm
content: It's a hardware switch. It's almost without doubt a hardware problem.

author: soldar
author_rank: Super Contributor
timestamp: November 12, 2019, 02:32:04 pm
content: If I disable the computer Ethernet port and re-enable it then the connection continues OK but if I physically unplug the cable from the computer and plug it in again then it breaks the connection.It seems now that if the computer's port is up and running when I start the router then the connection succeeds but if the router is started before the computer then the connection fails.I do not know much about the hardware so I have no idea what would explain this behavior.It is not a serious problem for me because I can just avoid using this port. The main problem is that I tend to forget and in a few weeks I will plug something in there and scratch my head for a while not realizing that there is a note right there by the router saying port #1 is iffy.I am mainly just curious. Sometimes glitches like this happen with marginal supply voltage, temperature, etc.E.T.A.: I tried changing the PSU but that made no difference. I tried raising the voltage a bit above the nominal 9 Vdc but the problem remains.I guess the good thing after these tests is that I know I can get it to work and once it is working it will remain stable.

author: PA0PBZ
author_rank: Super Contributor
timestamp: November 12, 2019, 03:16:45 pm
content: Quote from: soldar on November 12, 2019, 02:32:04 pmhttps://es.aliexpress.com/item/32810931193.html

author: soldar
author_rank: Super Contributor
timestamp: November 12, 2019, 03:20:15 pm
content: Quote from: PA0PBZ on November 12, 2019, 03:16:45 pmMy first thought was a blob of epoxi.

author: madires
author_rank: Super Contributor
timestamp: November 12, 2019, 05:47:59 pm
content: Quote from: soldar on November 12, 2019, 02:32:04 pmTypically a problem with auto negotiation or a bad patch cable.

author: soldar
author_rank: Super Contributor
timestamp: November 12, 2019, 07:18:43 pm
content: Quote from: madires on November 12, 2019, 05:47:59 pmDefinitely not cable or computer related because it happens with different cables and computers. Definitely related to that specific port on the router.I know nothing about how they negotiate though. You think the port is asking too much?

author: Black Phoenix
author_rank: Super Contributor
timestamp: November 13, 2019, 07:26:40 am
content: Quote from: soldar on November 12, 2019, 07:18:43 pmI don't think is software, for me its physical, something related with the port itself connector or the transformer module of the port itself. Although OpenWRT released a new version of the firmware, the OpenWrt 19.07.0-rc1, Current Stable Release Candidate. Just give it a go and tell what happen. Backup everything before, just in case.

author: soldar
author_rank: Super Contributor
timestamp: November 13, 2019, 08:35:46 am
content: Quote from: Black Phoenix on November 13, 2019, 07:26:40 amWell, I don't know if it is physical or psychological but after so much testing I have a pretty good handle on how to get around it. Just plug/unplug the cable until the port starts working and then leave it and it will work indefinitely.I don't think it is worth the risk of trying the new OpenWRT 19 because I figure the chances of fixing the problem are lower than the chances of creating new and bigger problems.

author: Syntax Error
author_rank: Frequent Contributor
timestamp: November 13, 2019, 01:05:24 pm
content: Hola @Soldar : Are there any clues to your LAN failure in the system log?Luci > Status > System Logor in SSHlogreadlogread -e LANlogread -e DHCP

author: soldar
author_rank: Super Contributor
timestamp: November 13, 2019, 07:01:51 pm
content: Quote from: Syntax Error on November 13, 2019, 01:05:24 pmI looked around and did not see anything obvious BUT playing around it seems if I go to Network -> Interfaces and restart LAN then it resolves the problem.So, port is working, unplug cable and plug in again and now it is not working, restart LAN in OpenWRT and port works again.So, it seems that either restarting the entire router with power recycle or just the LAN within the Lucy menu resolves the problem.

author: Syntax Error
author_rank: Frequent Contributor
timestamp: November 13, 2019, 08:43:54 pm
content: By restarting the LAN, this forces Dnsmasq to restart, and hence the DHCP leases are renewed. You can view your current client DHCP leases in/tmp/dhcp.leasesI found some rather 'fuzzy' discussion surrounding issues like yours on the Openwrt forum. One suggestion was to ensure that in the Firewall, theLAN Zoneis set to 'Accept' on Input, OutputandForward. Why? A disconnected client device would not rebind with the DHCP server as it could not forward it's requests to the DHCP server on port 68. Sorry if that makes no sense < 'fuzzy'.

author: soldar
author_rank: Super Contributor
timestamp: November 13, 2019, 10:19:03 pm
content: Quote from: Syntax Error on November 13, 2019, 08:43:54 pmYes, LAN zone is set to accept by default. And why would it only happen on port #1?No DHCP. Everything has fixed IP address. Also, why would it only happen on port #1?I am still not clear if the blame may lie with OpenWRT or with the HW or with the combination of both.At any rate, I have spent on this more time than it is worth. I have the relatively easy workaround of restarting the LAN from my computer so that is what I will do for now.

author: Syntax Error
author_rank: Frequent Contributor
timestamp: November 14, 2019, 05:33:52 pm
content: Hola @Soldar : That is odd. With your fixed IP configuration I might suspect the HW device is the trouble. On the HW device, is the TCP/IP set to 'static address' or 'obtain address from gateway/dhcp'?

author: Monkeh
author_rank: Super Contributor
timestamp: November 14, 2019, 06:14:34 pm
content: Uhm, if he's not using DHCP, then it wouldn't be set to use DHCP, would it?

author: Syntax Error
author_rank: Frequent Contributor
timestamp: November 14, 2019, 06:35:08 pm
content: Depends if it's a Static IP or a preassigned Fixed IP.

author: Monkeh
author_rank: Super Contributor
timestamp: November 14, 2019, 06:37:51 pm
content: Quote from: Syntax Error on November 14, 2019, 06:35:08 pm...Quote from: soldar on November 13, 2019, 10:19:03 pm

author: soldar
author_rank: Super Contributor
timestamp: November 14, 2019, 07:10:32 pm
content: Yeah, I like to set all my devices on my networks to static IP because it usually makes things easier.And generally I know the IP address of each device by heart which helps with troubleshooting.Generally I have DHCP disabled which has caused me some trouble in the past when someone says "my phone cannot connect to your network" and I totally forget I have DHCP disabled and I start looking at all sorts of things except at the cause. After a while I slap myself in the forehead and remember it is the nth time this happens. I hate it when that happens.I now remember having trouble with the computer generally connected to that router port. Now, if it happens again, I know to try restarting the ports within OpenWRT.