gogoWebsite

The reason why the ubuntu system is slow or very stuck

Updated to 2 days ago

1.   Involves small memory or virtual SWAP partition adjustment issues

You can view it through the system monitor

In the UBUNTU system, the system does not use the swap partition after all your physical memory is exhausted! The system's swappiness setting value has a great relationship with how to use swap partition.

When swappiness=0, it means that the physical memory is used to the maximum extent, and then the swap space is
When swappiness=100, it means actively using swap partition and transferring the data in memory to the swap space in time.

The above two settings are extreme settings. For the default calorific value of UBUNTU system, this value = 60. If you want to optimize it, you can modify it to about 10-20!

1. Click Application - Attachment - Terminal
2. Enter the following content to view the current parameters of swappiness (the default should be 60)

cat /proc/sys/vm/swappiness

3. Enter the following content and modify this parameter to 20 (executing this step is only a temporary modification, and if restarted, it will restore 60)

sudo sysctl =20

4. The following statement allows you to save the value you set, first enter:

sudo gedit /etc/

Then add the following at the bottom:

=20

Hehe, now your virtual memory usage method is completely modified according to the value you set! The default system 60 is actually 60%, which means protecting your memory to more than 60% to run larger programs. Using SWAP partition as a swap is definitely slow, so we usually make adjustments according to our needs! Of course, it is not that 10-20 is the best, because you must be very clear about the memory requirements you often use, so you can decide for yourself!