Preface
The previous time in using the program to deal with the larger data, found that the original memory of their computer is not enough and often go to die, so think of the use of swap partition to expand the way memory. Now make a brief summary:
the concept of swap partitioning
The initial swap partition was when I entered the lab to install the Linux system, and was not aware of the partition at the time, just see the notes of Brother Siang to set it up. But what is the swap partition for? Is there no such partition in Windows? Is there a need for setup?
In general, the swap partition can improve the performance of the Linux system the swap partition is an area in the hard disk space that is used to store the memory overflow data. For example, think of memory as a cup, the data generated when the program runs as water into the cup, when we run too much, or the amount of data processed too large, the cup slowly become full, resulting in no more, at this time if there is a swap partition, it is like to pour too much water into the swap partition of the cup.
In the swap partition of Windows, we are more often called virtual memory. Although there are significant differences in the technical implementation of the two, we can assume that they have the same effect. In addition, the Linux system hibernation data is saved to the swap partition, in other words, if the system does not configure the swap partition, Linux can not hibernate! (This has not been verified personally)
Theoretically, the swap partition does increase the amount of memory available, but the data exchange rate in memory is very fast, while the swap partition tells the physical memory as the carrier of memory, the data exchange speed of the physical disk lags far behind the physical memory, so it inevitably brings down the running efficiency.
How to increase/create physical memory
Usually the swap partition is set when the system hard disk partition is installed, which mainly describes the method of the swap partition extension after the system has been completed. Generally speaking, there are two ways to choose.
Before that, use the instructions to see the swap partition usage. Use the free directive.
[Email protected]:build$ Free
Display as shown: The swap partition of the system is not empty.
Linux swap partition that thing.