New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
FS#1144 - Opkg fails with Out of memory on a TP-Link RE450 #5631
Comments
Markinus: https://forum.lede-project.org/t/tp-link-re450-64m-128m-two-version/3448/15 Some devices seems to have 60 and some 125 MB RAM... my has 60. |
ibex-are-goats: Edit: Replied to wrong bug. |
TDFKAOlli: Same problem on TP-Link TL-WR1043N/ND v1: BusyBox v1.25.1 () built-in shell (ash)
/ LE / \ | | | | | | root@LEDE:~# opkg list
Update of packages still works. When I stop one of the tasks in the Startup list, then listing the packages works. Seems that okpg has a memory requirement which makes it difficult to run on a low mem router. If would be great if it could be tuned for low memory consumption. Shutting down processes to install packages is a workaround but dangerous and not handy. BTW: sysctl -w vm.min_free_kbytes=0 doesn't help in my case. |
jow-: Opkg in LEDE already is heavily tuned for low memory consumption. Compared to the original version it requires 80% less RAM for processing package lists but even that is not enough for certain low memory devices. Your only choice on such devices is to not use opkg at all or to reduce the number of package feed entries. |
BUG-reporter:
TP-Link TL-WR1043N/ND v1 The same issue I'm expiriencing all the time since 17.01 or even earlier |
fedorinoff: TP-Link wr842nd v2.
|
ynezz: Please can you try new 18.06.2 release and provide output of |
ckujau: This happens here on a [[https://openwrt.org/toh/tp-link/archer-c5-c7-wdr7500|External LinkTP-Link Archer C7 v2]] (16 MB Flash, 128 MB RAM) with 19.07.1 (ath79/generic) installed:
# opkg update
Downloading http://downloads.openwrt.org/releases/19.07.1/targets/ath79/generic/packages/Packages.gz
*** Failed to download the package list from http://downloads.openwrt.org/releases/19.07.1/targets/ath79/generic/packages/Packages.gz
[...]
Collected errors:
* xsystem: wget: vfork: Out of memory.
* opkg_download: Failed to download http://downloads.openwrt.org/releases/19.07.1/targets/ath79/generic/packages/Packages.gz, wget returned -1.
[...]
Setting "vm.min_free_kbytes=0" helps indeed. The default appears to be 16384 (16 MB). However, according to "free" it has 33 MB of "free" memory, that should be enough to complete the task. But then it also prints 37 MB "shared" and 45 MB cached, which should all count as "available" memory, so this 17 MB "available" memory looks kinda confusing. On a "normal" desktop system free+shared+buff/cache usually equals "available", but not on an embedded system? In any case, this did not happen with 18.06 and earlier releases for my device (then with "ar71xx/generic" installed). |
Markinus:
Hi!
I a problem on my TPLINK RE450 on upgrading of packages. I'm restarting the system and the upgrade is still not possible, console output:
BusyBox v1.25.1 () built-in shell (ash)
/ LE / \ | | | | | |
/ DE / \ | || _|| |) | _|
/_/ LE \ |||/|| lede-project.org
\ \ DE /
\ LE \ / -----------------------------------------------------------
\ DE \ / Reboot (17.01.4, r3560-79f57e422d)
________/ -----------------------------------------------------------
root@LEDE:
# df# freeFilesystem 1K-blocks Used Available Use% Mounted on
/dev/root 2560 2560 0 100% /rom
tmpfs 30332 80 30252 0% /tmp
/dev/mtdblock3 2176 236 1940 11% /overlay
overlayfs:/overlay 2176 236 1940 11% /
tmpfs 512 0 512 0% /dev
root@LEDE:
total used free shared buffers cached
Mem: 60664 43600 17064 80 2320 6048
-/+ buffers/cache: 35232 25432
Swap: 0 0 0
root@LEDE:
# opkg update# dfDownloading http://downloads.lede-project.org/releases/17.01.4/targets/ar71xx/generic/packages/Packages.gz
Updated list of available packages in /var/opkg-lists/reboot_core
Downloading http://downloads.lede-project.org/releases/17.01.4/targets/ar71xx/generic/packages/Packages.sig
Signature check passed.
Downloading http://downloads.lede-project.org/releases/17.01.4/packages/mips_24kc/base/Packages.gz
Updated list of available packages in /var/opkg-lists/reboot_base
Downloading http://downloads.lede-project.org/releases/17.01.4/packages/mips_24kc/base/Packages.sig
Signature check passed.
Downloading http://downloads.lede-project.org/releases/17.01.4/packages/mips_24kc/luci/Packages.gz
Updated list of available packages in /var/opkg-lists/reboot_luci
Downloading http://downloads.lede-project.org/releases/17.01.4/packages/mips_24kc/luci/Packages.sig
Signature check passed.
Downloading http://downloads.lede-project.org/releases/17.01.4/packages/mips_24kc/packages/Packages.gz
Updated list of available packages in /var/opkg-lists/reboot_packages
Downloading http://downloads.lede-project.org/releases/17.01.4/packages/mips_24kc/packages/Packages.sig
Signature check passed.
Downloading http://downloads.lede-project.org/releases/17.01.4/packages/mips_24kc/routing/Packages.gz
Updated list of available packages in /var/opkg-lists/reboot_routing
Downloading http://downloads.lede-project.org/releases/17.01.4/packages/mips_24kc/routing/Packages.sig
Signature check passed.
Downloading http://downloads.lede-project.org/releases/17.01.4/packages/mips_24kc/telephony/Packages.gz
Updated list of available packages in /var/opkg-lists/reboot_telephony
Downloading http://downloads.lede-project.org/releases/17.01.4/packages/mips_24kc/telephony/Packages.sig
Signature check passed.
root@LEDE:
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/root 2560 2560 0 100% /rom
tmpfs 30332 568 29764 2% /tmp
/dev/mtdblock3 2176 236 1940 11% /overlay
overlayfs:/overlay 2176 236 1940 11% /
tmpfs 512 0 512 0% /dev
root@LEDE:
# free# opkg list upgradabletotal used free shared buffers cached
Mem: 60664 44804 15860 568 2320 6756
-/+ buffers/cache: 35728 24936
Swap: 0 0 0
root@LEDE:
root@LEDE:
# opkg list-upgradable# opkg upgrade luci-baseluci-lib-ip - git-17.290.79498-d3f0685-1 - git-17.298.45605-07e7ff0-1
luci-theme-bootstrap - git-17.290.79498-d3f0685-1 - git-17.298.45605-07e7ff0-1
dnsmasq - 2.78-1 - 2.78-2
luci-app-firewall - git-17.290.79498-d3f0685-1 - git-17.298.45605-07e7ff0-1
luci-proto-ppp - git-17.290.79498-d3f0685-1 - git-17.298.45605-07e7ff0-1
luci-mod-admin-full - git-17.290.79498-d3f0685-1 - git-17.298.45605-07e7ff0-1
luci-base - git-17.290.79498-d3f0685-1 - git-17.298.45605-07e7ff0-1
luci-proto-ipv6 - git-17.290.79498-d3f0685-1 - git-17.298.45605-07e7ff0-1
luci-lib-nixio - git-17.290.79498-d3f0685-1 - git-17.298.45605-07e7ff0-1
luci-lib-jsonc - git-17.290.79498-d3f0685-1 - git-17.298.45605-07e7ff0-1
luci - git-17.290.79498-d3f0685-1 - git-17.298.45605-07e7ff0-1
root@LEDE:
Upgrading luci-base on root from git-17.290.79498-d3f0685-1 to git-17.298.45605-07e7ff0-1...
Downloading http://downloads.lede-project.org/releases/17.01.4/packages/mips_24kc/luci/luci-base_git-17.298.45605-07e7ff0-1_mips_24kc.ipk
Collected errors:
root@LEDE:~#
It looks like there is enough memory availible, where is the problem? Can someone explain it? With a sysctl -w vm.min_free_kbytes=0 the upgrade is possible.
The text was updated successfully, but these errors were encountered: