dangowrt / owrt-ubi-installer

OpenWrt firmware installer for the Linksys E8450 aka. Belkin RT3200
GNU General Public License v2.0
393 stars 50 forks source link

The image file is incorrect #116

Closed zwwuu closed 1 year ago

zwwuu commented 1 year ago

On a Linksys E8450 with firmware version 1.2.00.273012, and uploading openwrt-22.03.0-mediatek-mt7622-linksys_e8450-ubi-initramfs-recovery_signed.itb results in popup sating "The image file is incorrect".

dangowrt commented 1 year ago

That's odd. I've tried using the installer after flasing FW_E8450_1.2.00.273012_PROD_signed.img and that worked for me. I did not try flashing the recovery image from the stock loader though... Does using openwrt-22.03-snapshot-r19338-ae64d0624c-mediatek-mt7622-linksys_e8450-ubi-initramfs-recovery_signed.itb just for the backup step work?

zwwuu commented 1 year ago

No, same popup "The image file is incorrect".

dangowrt commented 1 year ago

Which browser are you using? Can you post a screenshot of the firmware version information showing in the web-ui?

zwwuu commented 1 year ago

Firefox 104.0.2 on Windows 10. I also tried on Chrome and Edge, same popup for all browsers. screenshot

dangowrt commented 1 year ago

Very strange indeed. Maybe just try if the installer itself works (no need for those very complete backups: the installer will also do a backup of the previous bootchain just missing the firmware file itself which can easily be downloaded from Linksys/Belkin).

dangowrt commented 1 year ago

Ha! I have vague memories of there being a problem if the complete path (something like C:\....\openwrt-foo-bar.itb on Windows) is too long/complex. Try storing the file in a very simple path, like the root directory of a drive.

zwwuu commented 1 year ago

I renamed installer image to installer.itb and placed at the root of C drive. Same popup again.

dangowrt commented 1 year ago

Please confirm you are exactly on 1.2.00.273012 vendor firmware version.

zwwuu commented 1 year ago

Yes image

dangowrt commented 1 year ago

I've retried with my device, went all the way back to stock firmware 1.00, did the two automatic updates on the way to 1.2.00.273012. When ahead and downloaded the installer file from github, uploaded to router and all works. I'm really a bit puzzled about what the cause of your difficulties may be.

wallrik commented 1 year ago

Were you able to solve this issue @zwwuu?

I renamed installer image to installer.itb and placed at the root of C drive. Same popup again.

Even though the message does not appear to be filename related, maybe try renaming the filename extension from .itb (image tree blob) to .img that Linksys uses for their firmware downloads.

If you're still getting an error, can you check your browser developer console (F12) to see if it's the server returning an error, or if the check is done inside the browser?

zwwuu commented 1 year ago

@wallrik No, even with .img extension i still get error. image

dangowrt commented 1 year ago

Does flashing the original vendor firmware work?

wallrik commented 1 year ago

Okay, long shot - What if, just what if... Have you been using the same downloaded file for every attempt? What if it was corrupted for some weird reason...

PS C:\Users\wallrik\Downloads> Get-FileHash "openwrt-22.03.1-mediatek-mt7622-linksys_e8450-ubi-initramfs-recovery-installer_signed.itb"

Algorithm       Hash                                                                   Path
---------       ----                                                                   ----
SHA256          8392F88DA4A50441DA1642C9D22445099787E810890CA148D56109AE2FE0FBDD       C:\Users\wallrik\Downloads\openwrt-22.03.1-me...
zwwuu commented 1 year ago

@dangowrt No, same error with original firmware FW_E8450_1.2.00.273012_PROD_signed.img.

dangowrt commented 1 year ago

In case you haven't done that yet, try doing a factory reset to erase all settings before flashing. If that also doesn't help and you can't even flash the original firmware, then there is most likely another problem with the device and you will have to decide at this point if you just want to return it (in case you got warranty) or open it, connect the serial port and find out what's actually happening (which implies loosing the warranty).

rthomas67 commented 1 year ago

Summary

Encountered the same "The image file is incorrect" issue trying to flash the recovery image (not installer) starting from stock firmware 1.1.00.180912

TLDR

Context

(This is a summary of some of the "wheel-spinning" caused by the slightly incorrect statement about stock firmware version 1.1 in the README.)

fiveangle commented 1 year ago

Regarding above issue of successfully upgrading 1.1.x with unsigned image, according to Linksys release notes, support for signed FW was introduced in 1.1.01.272918:

---------------------------------------------------------------------------
Firmware version:   1.1.01.272918
Release date:       April 13, 2022

- Supported future signed image for next firmware release. 
---------------------------------------------------------------------------

but not enforced until 1.2.00.273012:

---------------------------------------------------------------------------
Firmware version:   1.2.00.273012
Release date:       April 13, 2022

- Add support for signed firmware image only. Once firmware is updated, you can no longer rollback to a previous unsigned firmware image. 
…
---------------------------------------------------------------------------

So instructions everywhere should be changed to using signed FW image only for versions >=1.2.00.273012

dangowrt commented 1 year ago

So instructions everywhere should be changed to using signed FW image only for versions >=1.2.00.273012

Can you make a pull-request for README.md for the change you are suggesting?

fiveangle commented 1 year ago

So instructions everywhere should be changed to using signed FW image only for versions >=1.2.00.273012

Can you make a pull-request for README.md for the change you are suggesting?

130