luci-base: tweak busybox top regex to accept 'm' in large VSZ
Tweak the lua regex string for process list, so that processes
with extremely large memory sizes (over 100 MB) are matched.
For those large processes busybox top shows a MB value like '234m'
instead of a normal kB value like 234000.
Fixes #4425
Reference to https://github.com/openwrt/luci/issues/4425#issuecomment-694073479
Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
(cherry picked from commit 4f2ecd88fd
)
This commit is contained in:
parent
dc51a2f845
commit
8401f59e03
1 changed files with 1 additions and 1 deletions
|
@ -387,7 +387,7 @@ function process.list()
|
|||
|
||||
for line in ps do
|
||||
local pid, ppid, user, stat, vsz, mem, cpu, cmd = line:match(
|
||||
"^ *(%d+) +(%d+) +(%S.-%S) +([RSDZTW][<NW ][<N ]) +(%d+) +(%d+%%) +(%d+%%) +(.+)"
|
||||
"^ *(%d+) +(%d+) +(%S.-%S) +([RSDZTW][<NW ][<N ]) +(%d+m?) +(%d+%%) +(%d+%%) +(.+)"
|
||||
)
|
||||
|
||||
local idx = tonumber(pid)
|
||||
|
|
Loading…
Reference in a new issue