Dlink Dir-2640 cant install openwrt

The timeout comes up every once in a while in the forum, it is a known ugly bug on the emergency room implementation of several D Link devices (often dir 26x0 and 19x0 and previous releases), it is said to be an implementation bug in http 100 continue handling on the mini web server. Linux clients are for some reasons less forgiving on that bug since a certain release.
If you have a friend with a non-virtualized Windows installation - that usually works without issues.
According to the forum, curl on Linux as a workaround does work for some people and for some reasons not for others.

As per curl manual it waits 1000ms then continues dumping binary data specified. Im thinking of increasing wait time to few seconds explicitly may be server needs more time. Also will check source if recovery page for field “firmware” if it does exist there or it has different name.

We dont have anything but ubuntus and macos unfortunately.

I'm sorry to say there are pages and pages of people trying to get this work
there is something about Linux that won't let it work
this includes windows emulators on Linux

how ever if you can just fine a real native windows pc it should work
I have found sometimes you need incognito in Firefox "disables cache"
other have said IE mode in edge
I have used IE 9 in the passed as well

here is a decrypted firmware file if you need to go back
http://luckys.onmypc.net/openwrt/DIR-2640/DIR-2640_REVA_FIRMWARE_1.11B02.decrypt.BIN

It just doesnt work under linux. Dont have windows machine to try unfortunately.

maybe try an old version of curl seems V7.81.0 worked

FYI we can make encrypted factory firmware images like d-links
but we need the RSA private key to generate them
witch we don't have for this model

To upload it via non recovery mode i.e standard firmware update page?

I will go with kvm tomorrow will install windows 10 iot on my pc to try thru windows hope it will work.

1 Like

yes normal d-link firmware upgrade

I use Windows 10 IoT Enterprise LTSC 2021 my self
this works fine with Firefox only sometimes cache interferes but "incognito mode" fixes that

Ended up doing thru win10 its impossible to do from Ubuntu. Should be noted in instructions.

1 Like

Can confirm, DLink rescue firmware seems to have a conflict with Linux network stack. Must've been developed by a Windows user :(. Futzed around with MTU and txqueue settings for awhile under Linux and then just used a Windows OS (NOT a VM). Worked fine on the first try.

If someone has time to add "ONLY USE WINDOWS OS TO UPGRADE D-LINK FIRMWARE IN RESCUE MODE" to the wiki it will save people some time. Thanks

1 Like