View previous topic :: View next topic |
Author |
Message |
Adel Ahmed Veteran
Joined: 21 Sep 2012 Posts: 1602
|
Posted: Wed Jan 29, 2025 9:46 am Post subject: understanding available memory |
|
|
I am benchmarking gentoo vs alpine linux regarding memory usage
I have installed a pretty close installation for both OS:
gentoo: busybox ash as default shell, openrc, idw for wireless, kernel config: https://p.defau.lt/?H_zb7pvXZP2olicQWTJ6Xw
alpine: same as above but using the default alpine kernel
when i look at memory usage in alpine I see less used memory, but less available memory
Code: | cherry:~# free -m
total used free shared buff/cache available
Mem: 1922 59 1817 0 46 1710
Swap: 3844 0 3844 |
gentoo:
Code: | root@cherry $ free -m
total used free shared buff/cache available
Mem: 1920 91 1840 0 46 1828
Swap: 0 0 0
alpine: |
i wanted to understand if the available memory is almost identical, and the used value is lower, shouldn't the available memory be higher?
where is this memory going? and how can I get reporting on it? |
|
Back to top |
|
|
pietinger Moderator
Joined: 17 Oct 2006 Posts: 5352 Location: Bavaria
|
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54794 Location: 56N 3W
|
Posted: Wed Jan 29, 2025 5:47 pm Post subject: |
|
|
Adel Ahmed,
Perhaps you need to look at /proc/meminfo
In theory, all memory can be reused except
Code: | Unevictable: 10344 kB
Mlocked: 10480 kB | plus things belonging to the kernel.
I say in theory because when the kernel is forced to drop code that it would like to execute and reload it tater, things get intolerably slow.
You need to decide what counts as free and apply that metric consistently. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
|