This is a simple script that removes the "buff/cache" from RAM. There nothing different
But there are some features =)
One line. One command. And everything is ready!
curl -fsSL https://raw.githubusercontent.com/medowic/simple-memory-cleaner/master/install.sh | sudo bash
curl -fsSL https://raw.githubusercontent.com/medowic/simple-memory-cleaner/master/uninstall.sh | sudo bash
You can use the clmem
command for fast memory cleaning
Note
To use clmem
, you must be a root or use sudo
$ sudo clmem
# Cleaned: ... MiB
Also, clmem
works as a daemon to clean up memory periodically
To start and stop it, use systemctl
systemctl start clmem # start service
systemctl stop clmem # stop service
Usually, clmem
cleans up memory every 30 minutes, but this value can be changed in /etc/clmem.conf
:
# This is configuration file for simple-memory-cleaner (clmem)
# How often will the memory be cleared (in minutes)?
CLEAN_TIME=30
Cleaning is set to every 30 minutes (CLEAN_TIME=30
). You can change this value to whatever you want but it must be not less than 1
.
CLEAN_TIME=60 # now, the daemon will clean memory every 60 minutes
If you set this value to less than 1
, the daemon will not start
CLEAN_TIME=0 # daemon will be stopped with exit-code 1
After changing the value, restart the daemon by running systemctl restart clmem
This is project is under the MIT License