Only 11 MB free of 128 MB - Netgear R7500 v1

Good morning everyone.
I installed OpenWrt on a Netgear R7500 v1 following the guide https://openwrt.org/toh/netgear/r7500, but I was surprised because of the router's 128 MB of free space, I only had 11 MB left to install additional packages. Is this normal? Is it possible to recover space without using a USB flash drive? I tried searching for a tiny firmware version, but I couldn't find anything. Can anyone give me some pointers or point me to a guide?

Hi.
What is the result of cat /proc/mtd ?

According to the wiki, the bootlog shows

[    1.480883] Creating 8 MTD partitions on “qcom_nand.0”:
[    1.487749] 0x000000000000-0x000000c80000 : “qcadata”
[    1.498414] random: fast init done
[    1.516799] 0x000000c80000-0x000001180000 : “APPSBL”
[    1.527412] 0x000001180000-0x000001200000 : “APPSBLENV”
[    1.529849] 0x000001200000-0x000001340000 : “art”
[    1.535347] 0x000001340000-0x000001740000 : “kernel”
[    1.545111] 0x000001740000-0x000002d40000 : “ubi”
[    1.586235] 0x000002d40000-0x000003940000 : “netgear”
[    1.609401] 0x000003940000-0x000008000000 : “reserve”

Latest partition is not used and sizes 70MB. So yes you may have short memory available.

Read the last paragraph on top of https://openwrt.org/toh/start.

Here is the output of cat /proc/mtd :

dev:    size   erasesize  name
mtd0: 00c80000 00020000 "qcadata"
mtd1: 00500000 00020000 "APPSBL"
mtd2: 00080000 00020000 "APPSBLENV"
mtd3: 00140000 00020000 "art"
mtd4: 00400000 00020000 "kernel"
mtd5: 01600000 00020000 "ubi"
mtd6: 00c00000 00020000 "netgear"
mtd7: 046c0000 00020000 "reserve"

Thanks for the tip. The most similar guide is the R7800 one, but the partitions are different.

These infos (size) correspond to what I posted in the first message (start/end memory adress).
So yes it is normal to have only few MB left. OpenWrt sticks to the vendor memory scheme.
Other possibility is to redefine the scheme, such as shown by the example of the R7800 link.

I've been using Linux for years, but only for home use and not very advanced. Unfortunately, I don't have the in-depth knowledge to identify the relevant information from that post and adapt it to the R7500.
Then there's talk of installing LELE, which is stuck at version 17.01.
Do you have any patience for more specific suggestions?

Redefining the partition scheme is a delicate operation. It implies changing the dts and compiling a new version. Despite I understand the meaning of this, I don't have the knowledge to do so.

If you use the firmware selector to make a build with the packages you want included then a lot will fit into your space

A snippet from the NetBird guided, of course this mentions NetBird but the same applies to the packages you want:

NetBird is a rather large package around 12 MB written in Go so make sure your storage is sufficient, if you install it as a package it will take up double this storage, if your storage is not sufficient then make a new build using e.g. the firmware selector and customize installed packages adding netbird.

If you already have a running build then a very hand tool to make a list for the firmware selector is owut (owut list).

You can even use it for upgrading and adding a package like netbird (owut upgrade --add netbird).

I could not install NetBird as a package on my EA8500 which has comparable storage but making a build with NetBird included and it fits "easily" still have space left

1 Like

You could try using the unused partition as extroot, shouldn't require any Openwrt image modification.

If you succeed, report back and we'll add it to the device wiki page.

1 Like

Interesting idea. This partition may be in read-only mode. OP may have to unlock it.

There is a good chance that using the equivalent approach as for the r7800 will work, but the details will have to be confirmed (including safe returning to a functional OEM firmware) by someone with that hardware on their desk, before they can suggest a PR containing the changes. If possible, this will always be less pain than extroot.