Help with Linksys EA7500 v2

Hi All,

I realize this has been covered in multiple threads but in none of them can I find what I'm looking for.

I picked up a used EA7500 v2 and attempted to flash openwrt-23.05.2-ramips-mt7621-linksys_ea7500-v2-squashfs-factory.bin from the Linksys factory firmware.

Now let me just start by saying that this factory firmware is just about the most annoying factory firmware I have EVER had to deal with. I've flashed dozens of Broadcom-based Linksys EA series with dd-wrt and am well versed in the dual partition scheme, but all of those routers seem to have a CFE that allows for TFTP updates - and it is very easy to work around the factory's attempts to block you from flashing alternative router firmware.

But the EA7500 does not have CFE and nowhere could I find TFTP instructions for it so I had to use the factory webflash. So I started out doing that and here is what I ran into.

At first I powered up the router and attempted to login with the password "admin" it failed likely because the prior owner had set a password.

I held in reset button for 10 seconds with paperclip while router was powered up and it reset itself. So far so good.

Router rebooted it came up with factory firmware but immediately put me into the factory "Linksys Smart WiFI Setup" setup wizard and would not let me go out of it. Tried power-cycling and that did not work, same issue. Looked at Linksys support about manual configuration and they said you had to have the WAN port plugged in to get to the manual configuration so I did that.

I plugged wan port in to an ethernet network that was privately numbered and would hand out IPs via DHCP but blocks stuff with an unknown MAC from accessing the internet. This is standard practice with EA routers to prevent them from flash-updating themselves with newer factory firmware. Pressed reset button again and router rebooted.

The factory firmware absolutely did not like this at all.

PC obtained some weird private number from the router. However I used http://myrouter.local on PC webinterface per Linksys instructions and dynamic ip assignment on my PC and got to a login page that allowed me to select manual configuration, selected that.

Note that I had to wait at least 5 minutes in between each screen because the router was constantly attempting to login to the Internet

Finally was able to login with default password admin

Router took me to configuration page indicating firmware version 2.0.8.194281 was running. (this is the latest firmware from Linksys) Selected Connectivity and administration then attempted to update via webinterface.

Factory webinterface did permit updating to openwrt although it issued a warning. Router went through several reboot cycles it appeared to be flashing the firmware.

Surprisingly, factory interface did come back with firmware update completed successfully but then router was back at factory firmware. Power cycled still at factory firmware. Logged in and tried updating router from factory interface, router did not permit updating at all now, just issued an error. Tried power cycling and router still did not permit updating. There error was update in progress.

I then started all over again with a paperclip reset at a running state and ended up repeating the above about 6 times with different OpenWRT firmwares, several times. I even downloaded and flashed the Linksys factory firmware then attempted to follow with the OpenWRT firmware. All to no avail.

I read through the following threads:
[OpenWrt Wiki] Linksys EA7500 v2
OpenWrt installation on Linksys EA7500v2 - Installing and Using OpenWrt - OpenWrt Forum
Problem installing on Linksys EA7500v2 - Installing and Using OpenWrt - OpenWrt Forum
SSHD for Official Linksys EA7500v2 Firmware - Installing and Using OpenWrt - OpenWrt Forum

Much of the advice was useless as it applied to older Linksys firmwares with the versions not mentioned, or it boiled down to "just keep trying and you might get lucky" which I had already figured out.

There was a reference to:

Bad block makes ubi_auto_attach read from wrong offset, fail to mount ubi · Issue #12895 · openwrt/openwrt · GitHub

which who knows might apply. I don't know.

Finally I guess I got lucky because on literally the last attempt before I was going to scrap the device - the 23.05.2 firmware took and the router booted OpenWRT.

I then immediately sshed into the router and ran

/usr/sbin/fw_printenv -n boot_part

and I got a 1 back. So OK I had successfully installed the firmware on to partition 1. But no way was I going to ever go back to that Linksys firmware hell so I wanted to immediately flash partition 2.

And this is where I ran into a problem I need some help on.

I first tried the advice here:

and

which boiled down to "just flash from the OpenWRT interface and it will be smart enough to know to put your firmware on partition 2." Well OK that seemed effing stupid but what the heck I'll try it. So I ran the updater from OpenWRT and rebooted. So far so good but the real test is booting off the now allegedly-flashed partition 2. So at the ssh prompt I ran

/usr/sbin/fw_setenv boot_part 2

and rebooted and now I am back to Linksys hell. Worse, I cannot even now do a factory flash from this firmware because I keep getting "update in progress" errors. Not that I even know where the heck the factory firmware is putting anything. Maybe partition 2 maybe partition 2 who knows.

I tried "troubleshooting, revert to previous firmware" in the Linksys interface and THAT DID NOT WORK. Obviously Linksys installed checks in their current firmware to prevent this from working if OpenWRT was on the alternative partition.

Finally I tried the process in this document:

power off power on power off power on etc. and the boot code was finally obligated to switch back to partition 1 and I got my OpenWRT interface back.

Interestingly, the exact same process is used with Chrysler vehicles to get them to print out their diagnostic codes on the console (off/on/off/on multiple times) Gee I wonder where Linksys copied that idea from?

Anyway, could someone PLEASE tell me HOW to flash partition 2 FROM THE COMMAND LINE?!?!?

DD-WRT makes this process incredibly simple. Telnet/SSH into the router command line, cd /tmp, wget firmware to there, then "write [firmware] linux" or "write [firmware] linux2] depending on what partition you want.

Come on OpenWRT people - the recommendation of "set variable to boot into linksys factory firmware and flash from there" is duff, people. Baloney. Rubbish. Idiocy.

The entire point of putting OpenWRT on a device is to get a usable command line, IMHO. That's where the real power is. There must be a way I can clear that Linksys trash firmware that has (at this point) wasted 2 hours of my life while the firmware attempts to contact Linksys's mothership before it lets you do anything, from the real power behind the throne, here, the Unix prompt.

You guys gonna let dd-wrt one-up you on this???

What is possible -or not- depends more on the vendor's decisions, than on OpenWrt's - as at this point, you're interacting (almost exclusively) with the OEM firmware and the OEM bootloader (a modified u-boot).

What you should have done, is simply using sysupgrade to flash OpenWrt a second time - without manual boot_part changes (you had installed/ booted OpeNWrt from 1, which means it would flash to 2 - and toggle the setting to 2 on its own).

This device seems to follow Linksys' usual approach of toggling between partitions, follow the wrt1200ac/wrt1900ac/wrt1900acs/wrt3200acm/wrt32x information for this part, which basically boils down to cutting power early during a reboot three time in a row.

But that is exactly what I tried doing and it didn't work like you said. Didn't you read my post completely? What I said was:

"I first tried the advice here...which boiled down to "just flash from the OpenWRT interface and it will be smart enough to know to put your firmware on partition 2." Well OK that seemed effing stupid but what the heck I'll try it. So I ran the updater from OpenWRT and rebooted. So far so good but the real test is booting off the now allegedly-flashed partition 2"

EDIT UPDATE:

I just realized you must have meant run sysupgrade from the command line after finding this:

I can absolutely confirm that on this router, running the upgrade from the luci interface DID NOT WORK.

The manual boot_part changes I did were AFTER doing the second flash of OpenWRT from the luci sysupgrade button - and they were done as a TEST to make SURE that the flash to partition 2 actually happened.

Unfortunately I didn't think to run fw_printenv AFTER flashing a second time to see if OpenWRT would have manually toggled the boot setting on it's own. Maybe like you said it had toggled it and my fw_setenv boot_part was redundant.

If sysupgrade HAD flashed to the second partition then when I switched to booting from the second partition it should have booted into the "other" install of OpenWRT since at that time there would not have been any Linksys firmware left on the device.

So either 1 of 2 things happened. EIther sysupgrade merely flashed again right over the existing install on partition 1, or it attempted to flash over partition 2 and failed but did not report any error message back. Which is exactly why I want to flash from the command line, because the GUI webinterface covers up any errors.

Please note that the instructions here:

don't tell you how to specify the partition.

Also as a further edit and update - I installed the

package and it confirmed it - flashing from luci a second time still did not update the alternative partition. I will try it later from the command line and see if there's any error output

OK I did some more research on this.

I tried flashing multiple times both from from the command line using sysupgrade -v /tmp/xxxxx
where xxxxx was the 23.05.2, 22.03.5 and 21.02.07 and from the luci interface which to my understanding does exactly the same thing. I even tried the December snapshot but that caused Luci to crash so I reverted back to 23.05.2

IN ALL CASES the OpenWRT image ended up on partition 1.

IN THIS thread a user swears that they tested flashing and were able to flash to the alternative partition on an EA7300 v2:

even when asked point blank if they were able to do it on an EA7500 v2. But another user in that thread CLEARLY has the same problem I do - which is that THEY were unable to flash to the alternative partition, either on a EA7500 v2

Now the thread above was talking about a Linksys 8100v2 and one of the users said that for that device, the partition layout is hardcoded in the .dts and the second firmware partition is not used.

So, tentatively, what I have arrived at is that the EA7500 v2 is_not the same as the EA7300v2 even though the model numbers are close. For the 7500, OpenWRT will NOT flash an upgrade to the alternative partition. Possibly, the Linksys factory firmware won't either - or the factory firmware WILL in which case you have a trap-door situation where once you get OpenWRT on partition #1, you cannot get it on partition #2, because OpenWRT's sysupgrade will only flash the partition it's booted from and the Linksys factory firmware will NEVER flash the partition it's booted from.

And in my router, the one time I tried flashing from the Linksys firmware on the Alternative partition, I got an error that it could not flash because the upgrade was already in progress. So somthing got scotched there.

And on top of that - IF my router happens to have a bad NAND block on partition 2 - since the OpenWRT firmware has a bug in it (listed above) where it can't flash to a bad block on this device, then I'm screwed even more.

As for getting any sort of error back from the command line, I'm screwed on that because the very first thing that sysupgrade does before it unmounts the flash is it kills the networking and sshd sessions. This is really, really shortsighted because there is no way to see what the heck is going on. POSSIBLY if I tore the router apart and plugged in a serial level converter to it - I might get some more information.

But, it's absolutely not worth doing for a router I only paid $6.99USD for and only plan on using as a wireless access point.

The only value all of this has been is to churn out a list of bugs for this router and a design failure decision for sysupgrade, and, possibly an informed detailed analysis of what is going on for any dev who wants to dive into it.

The archives seem to have multiple postings and threads from people with the same problem as me - one guy mentioned he bought 6 of these and they worked fine and the 7th threw fits just like mine - so I am hopeful this thread will help the next guy to come along with one of these routers.

And that next guy might just be me.

Hope these hints help

  1. On stock firmware, use sysinfo.cgi to find out the current booting partition.

  2. Stock firmware can boot from either part 1 or 2. But OpenWrt can only boot from part 1.

  3. When flashing under the stock fw, the new fw always goes to the other partition. So if installing OpenWrt for the first time, make sure it's booted from part 2, so that the new OpenWrt can reside on part 1.

  4. If OpenWrt can't boot from part 1. The device may need a special fw build, see my post and try to make one. sshd-for-official-linksys-ea7500v2-firmware

Hi bism,

I just went through the procedure to update a Linksys WRT1200AC, this is - essentially - the "marketed to hobby users" variant of the "marketed to corporate types" EA7500v2

Like the EA this uses Linksys's dual-partition nonsense scheme.

This flashed the factory-to-openwrt firmware with no complaints then booted into openwrt. I then ran the openwrt sysupgrade version and it flashed with no complaints then rebooted. I then logged in and loaded luci-app-advanced-reboot which displayed that both partitions had OpenWRT loaded on them.

So, I AM familiar with the process to get OpenWRT on both partitions of a Linksys device that uses that dual partition scheme.

What I stated was that with the EA7500 v2 it's impossible to get openWRT on partition 2 from OpenWRT because UNLIKE the Linksys WRT1200AC, OpenWRT on the EA7500v2 ---NEVER--- flashes to partition 2 - the "alternate partition"

This is a bug. It's not something that hints from you are going to help me or anyone else. Only additional developer attention to the EA7500v2 firmware is going to fix this.

There are two major problems here:

First, leaving the Linksys EA7500 v2 with the Linksys firmware on partition 2 means leaving a "landmine" in the device. At any given time a power failure or other bug could cause the device to reboot itself into the factory firmware. In which case, the device immediately becomes remotely inaccessible. Furthermore it then becomes a serious problem to get it changed to boot back into openwrt on partition 1. You have to physically be at the device to fix it.

With the WRT1200AC, if a bug or power failure or whatever happens that causes the device to switch active partitions is triggered, the device is failureproof - it will merely boot into OpenWRT again - on the alternate partition.

Second, the documentation for the EA7500v2 does not mention this. The techdata for this device is here:

[OpenWrt Wiki] Techdata: Linksys EA7500 v2

It refers to this following thread for install instructions:

OpenWrt installation on Linksys EA7500v2 - Installing and Using OpenWrt - OpenWrt Forum

That thread is antique, it says the firmware is in beta, there's no luci for it, in the first post. All of that is wrong now.

The documentation for the WRT1200AC, located here:
[OpenWrt Wiki] Linksys WRT1200AC

is beautiful. It's clear, explains everything, and is accurate.

By contrast the EA7500v2 info is buried in hundreds of posts that are flat out wrong.

It took me 15 minutes to convert a WRT1200AC over to OpenWRT and get OpenWRT on both partitions.

It took me 4-5 hours to figure out that it was impossible to get OpenWRT on partition 2 of an EA7500v2 from OpenWRT. I read instructions. But that data was simply not there. And most of the posting on this are from people who have never actually done this and are just assuming the EA7500v2 works the same way as the WRT1200ACC because they assume just because it's a linksys device with 2 partitions all of those work the same way with openwrt.

Your response to me, here, point 2 is pretty much wrong because you don't specify this.

If you had said:

"On this EA7500v2 openwrt can only boot from part 1" it might have been accurate.

But what you said is wrong for the WRT1200AC. OpenWRT can boot from either partition on that device. It may also even be wrong for the EA7500v2 - if, that is, it was possible to install OpenWRT on partition 2. But it's not, so there's no way to check.

As for your point #3 - that is also, likely, accurate. But, a garden-variety stock EA7500v2 is going to come booting from partition 1. And the stock firmware has no way to show what partition the EA7500v2 is booted from. The implication is that you can do 2 successive installs from factory firmware and no matter what partition you are booted from it will work - except when I tried this - it failed. When I was booted from factory firmware on partition 1, the factory firmware refused to take the openwrt load giving a non-specific error. Of course, I did not know at the time what partition I was booted from, I did not know about all this requirement to have it be on partition 1 and so on - because that was not on the doc page for the device.

Hopefully you see how this is a problem. This post is an attempt to explain this. I've had probably just updated the techdata doc page for the EA7500v2 - except that the OpenWRT project doesn't seem to allow updating of doc pages.

It would be far better for the EA7500v2 developer to update dts or fix whatever this bug is that is making it not work like the majority of linksys dual partition devices.