Archer C7 is not accessible over LAN after OpenWrt installation

Hello, here are the quick facts:

Router: Archer AC1750 v5
In use since: 2019
OpenWrt Version used: 18.06

Everything was working fine till yesterday. I then wrote a cron script to turn off both WiFi radios at certain points in time. (something like uci set wireless ... uci commit; wifi;)

Tried it a couple of times manually and it was working as expected. Over night it should turn off WiFi. The C7 router is used as WiFi client to another router (for connecting wired devices via the other router's uplink). The next morning after switching off wifi for 8 hours, then automatically turning it on again, LAN ports weren't working anymore. Wifi was connected between the 2 routers as expected, but no LAN access to the Archer C7.

I found out that when I rebooted the C7 or did a /etc/init.d/network restart LAN would work for ~1-2 minutes, sometimes less.
Nothing in the logs.

Even resetting didn't help. I did a reset keeping the reset button pressed for 10 secs. WiFi was not configured, just a normal router. And again: LAN would disappear after a minute or two.

All tests were performed with ping by the way, from a linux machine connected via ethernet (also tried a windows laptop).

Next step: I installed the original firmware using TFTP. Everything seems to work OK. DHCP is working, ping is working via ethernet, so LAN seems ok. Even after 5-10 minutes. So it is not a hardware failure.

It must be software related, something to do with OpenWRT.
I flashed OpenWRT 21, the LEDs on the router are blinking, but I don't get a DHCP lease. And if I set the IP manually to 192.168.1.29 or anything, I still cannot ping 192.168.1.1
I tried it with OpenWRT 19, and 18, to no avail.
I always flash the original firmware first. Then use the WebGUI to switch to OpenWRT.

Does anybody have a clue what the problem is?

According to the hardware data for the C7 V5, use TFTP to install the OpenWrt firmware.

If you are going from stock to OpenWrt, you'll want to use the squashfs-factory.bin image.

Rename it to ArcherC7v5_tp_recovery.bin

Thanks for the reply.

Today I installed stock firmware, then openwrt 19.07 (ath79/generic/squashfs-factory ... both firmware updates via TFTP this time) and everything seemed to work (did a 6 minute ping test).
Then I reloaded my configuration from my archive, and LAN was not responding within a minute.

Since then I did a reset (via the button), a reflash of openwrt 19.07, and now a reflash of latest stock firmware. I cannot access LAN ports. DHCP not working either. Not even with stock firmware now.
Then LAN port LEDs are up, but no DHCP, and no ping with manual IP is going through.

p.s. after powering off the router for a while (and removing the power supply), then reflashing it with the stock firmware, LAN ports were working again. for 3 minutes.
After 187 pings no ping is going through now. I just let the pings run, tried no DHCP, did not login into web GUI...

Did a 3rd flash. First OpenWrt, then stock. This time stock took quite some time for flashing, then I know it really works.
But still. After 184 pings LAN stopped working.

Do you have static IP for the C7?

My best guess is that the wireless connection between the routers fails, and then there is no valid IP (for the C7 and/or the client).

First thing I would try is to make sure that both C7 and the LAN client have static IP.

No, I have not configured a static IP.

With the stock firmware I was able to get it running today.
I just installed OpenWRT via TFTP after having a working router for 1 hour now (with stock firmware) but with OpenWRT there is no LAN. WiFi is not configured either, because I have no possibility of accessing the admin interface.

I think you misunderstood the situation. This is not a config issue, where things aren't running with a specific config.
I cannot even install OpenWRT and access the router in any way. Sometimes I get a 3 minute access, sometimes not.

There is nothing configured between this router and any other router. I have reset the device many times, and installed stock firmware/openWRT. All settings should be set to default.
WAN is not connected.
3 ports on LAN are.

My actual question is:

How can I reset OpenWRT? Should flashing new image not reset all settings?
How can I bring it back to the state that it was in a week ago?

Does nobody else have problems accessing the LAN ports with OpenWRT 19 on Archer C7?

p.s.
to sum it up:
OpenWRT 18.06.1: only power LED on, LAN LEDs not even blinking
OpenWRT 19.07.8: LAN LEDs blinking but unable to connect

I have an assumption that LAN problems could have to do with IPv6.
On my test machine IPv6 is enabled and it is connected to port 1 of the router.
Before that IPv6 for the connection to the TP-Link router was disabled on my test machine.

I got a default install of OpenWRT 19.07.8 working after I disabled IPv6 on my client PC but I'm not sure whether this is the reason for the connectivity issues.

After some simple config changes (changed LAN network) LAN again not working. I reset to defaults, and again the problem that I had @ start: LAN only working for 1-2 minutes.
Then I disconnected the TV LAN cable from the router (@ port 4). And the PC could ping the router (no reboot, no config change). So it seems that the TV (in standby mode) being connected causes troubles with the other LAN devices being connected. Very strange.