Ubuntu Partitioning Strategy

Source: Internet
Author: User
Keywords OK swap partitions kernel
Tags aliyun data disk disk space file files hard help

Modern computers use virtual memory to have more memory. Virtual memory can also help to accomplish more things. Part of the disk space can be used as an extended http://www.aliyun.com/zixun/aggregation/17967.html "> memory space, that is, a swap area." In a Linux system, it is possible to swap files, swap partitions, or join the two or no swap partitions. Swap partitions are a little faster than swapping files, which is a common use for Linux systems. The advantage of swapping files is that they can be created dynamically. The swap partition size can be as large as the experience setting and memory. If you need more memory, you'd better buy a large-capacity memory, the swap area is much slower than memory. Although slow, the swap area is very important, the system kernel can put some of the data in memory into the swap area, so that memory can do other things, like the hard disk cache. The speed of reading and writing in different areas of the hard disk is not the same, and the speed of reading and writing at the edge of the cylinder is faster than that of the axis, but how to judge the physical location of a given hard disk storage space is a problem. My experience is that the hard disk start sector corresponds to the outer edge of the hard disk's physical space. So it's best to put the swap partition at the start sector. However, the argument that it is possible to reduce the time to seek by placing swap partitions in the middle sector is somewhat controversial. The only way to do this is to put the swap partition in a different location and do some benchmark testing. The best result is that at the end of the day, you may not find the difference in speed between them, and don't waste a lot of time on such things. If you have several hard drives, you can create swap partitions on each hard drive, and the system kernel can automatically use each swap partition in parallel. This will lead to a linear improvement in the overall performance of the system.

Simplest partitioning strategy

This is the simplest partitioning strategy, dividing only one swap partition and one partition.

Name partition size swap partition (swap) and memory the remaining capacity of a large root partition (/) hard disk

Separate the "filesystem" into one area.

It is prudent to divide "filesystem" into a separate area. This will ensure your personal data is secure, and your personal data will not be lost even after a reload system or system is upgraded. If you also have Windows operating system, you can format "filesystem" as a VFAT partition so that two systems can share data, but if the root partition is best not VFAT format. But it's best to format the "filesystem" partition as a Linux file system, because the Vfat file format is prone to error when manipulating large files, and you can share "filesystem" partitions if you install other Linux systems.

Name partition size swap partition (swap) and memory as large root partition ("/") at least 5G, maximum 15G "filesystem" hard disk's remaining capacity

Separate the boot partition ("boot")

If you've installed several Linux distributions, you can separate the boot partitions. A kernel requires a separate partition for the boot file, which can be handy when starting the selection kernel. For a 7.04 kernel, a kernel has 15-20 MB, and your kernel partition ("boot") will have three times times the capacity to accommodate the old, current, and new kernels.

Name partition size swap partition (swap) and memory the same large root partition at least 5G, maximum can 15g/boot at least 100M, the maximum can 250m/home the rest of the disk capacity

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.