How to free up RAM in Ubuntu using the console

Sometimes the system does not release RAM which is no longer being used and although it is released on demand – so to speak – when we open a new program, it can also be released manually by entering a simple command on our console.

First of all, per know how much memory is in use, How much is free and how much is of the cache we execute the command:

free -m

To see the use in real time we use:

watch -n 1 free -m

Either command will return something similar to this:

             total   used   free  shared  buffers  cached
Mem:          3990   3784    206       0       56    2443
-/+ buffers/cache:   1284   2705
Swap:         1027      0   1026

As you can see there is a lot of memory in the cache, about half of which is being used by open applications. per free cached pages, inodes, and directory entries just run the command:

sudo sync

Followed by:

sudo sysctl -w vm.drop_caches=3

It is important not to forget to run

sudo sync

since otherwise we could lose information present in the RAM that has not yet been saved to disk carry.

More information – Check the temperature of your computer with the ‘sensors’ command
font – UpUbuntu

Related Posts

Next Post

Leave a Reply

Your email address will not be published. Required fields are marked *

You might also like

Welcome Back!

Login to your account below

Create New Account!

Fill the forms below to register

Retrieve your password

Please enter your username or email address to reset your password.