How to free cached memory in Ubuntu Back

Note: Linux is NOT "eating" your RAM! Please take a look at Geirha's excellent answer below to understand why...

After the above note, if you still feel "cleaning" the cache could help, you can certainly try: it's a one-liner from the terminal:

sync && echo 3 | sudo tee /proc/sys/vm/drop_caches

Get real free ram without cached:

free -m | sed -n -e '3p' | grep -Po "\d+$"

results matching ""

    No results matching ""