Graphic tutorial on disk partitioning during Ubuntu Installation

Source: Internet
Author: User
For partitioning, if you just want to use Ubuntu, you can do this: 1) If you directly use the entire hard disk to install Ubuntu, there is no data to be saved on the machine, if you have already backed up the disk, you can directly select "Wizard-entire hard disk" during Ubuntu partitioning. 2) if you are using a dual system, A blank space has been poured out in Windows (a disk is deleted directly in disk management ). You can directly select "wizard -- use the maximum continuous free space" When partitioning Ubuntu.

About partitions

If you just want to use Ubuntu, you can do this:

1) if you directly use the entire hard disk to install Ubuntu, there is no data to be saved on the machine, or you have backed up the data, you can select "Wizard-entire hard disk" When partitioning Ubuntu"

2) if you are using a dual system and you have poured out a blank space in Windows (delete a disk directly in disk management ). You can directly select "wizard -- use the maximum continuous free space" When partitioning Ubuntu"

If you want to better understand the partition and implement self-customization, take a look at the following content to learn about the concept of the file system and mount point and then based on your actual needs.

I. File System

What is a file system? Please see http://www.linuxidc.com/Linux/2012-07/64900.htm.

The mainstream file systems are ReiseFS and ext3. For more information about the two, see

Ext3 introduction (http://www.linuxidc.com/Linux/2012-07/64901.htm)

ReiserFS File System (http://www.linuxidc.com/Linux/2012-07/64902.htm)

Comparison of ReiserFS and ext3 (http://www.linuxidc.com/Linux/2012-07/64903.htm)

You can select a file system as needed during partitioning.

Ii. mount point

In Linux, partitions must be mounted to the mount point in the form of a file system, just as partitions in Windows must also be formatted as drive letters in Fat32 or NTFS format. At least one/partition is required for Linux (you must enable the startup option. It seems that no prompt is prompted during the direct partitioning during the installation process, so you don't have to worry about it ), generally, there will be a SWAP partition (this is similar to the virtual memory in Windows, but it is more professional than that, and it is directly made into a partition form, in addition, there are SWAP files in Linux .), Of course, if your memory is large enough, you can avoid SWAP partitioning.

In Linux, the file system is organized in the/File System (root file system) tree.

Iii. How to partition

Are these file systems mounted as independent partitions? It's not all about it. It depends on your situation and needs.

Common partitioning methods include:/file system and a SWAP partition;/file system,/home file system, and a SWAP partition, multiple Linux directory trees, such as the/boot System and/var file system, and the/back that does not belong to the Linux directory tree (the name can be set by yourself, or the/file can also be, this is where you store backup data)

Splitting one/and swap only has the advantage of maximizing the use of hard disk space (users can ignore hard disk space issues as long as/is not used up ), however, you need to back up/home before reinstalling the system. Otherwise, reinstalling the system will be troublesome. If the disk space you infringe on Ubuntu is relatively small, such as 8 GB and 10 Gb, it is better to use this method, although after the default system is installed, the/file system only has about 3 GB, however, as you install more software, the/file system will become larger and larger. I have allocated 6 GB to/file systems, and nearly 5 GB has been occupied.

However, it is dangerous to divide only one/partition, which means that all data will be stored in the only/file system, this is not safe for the actual production system (just as we won't divide only one C disk when using Windows ). If the space allocated to Ubuntu is larger, you can mount/home independently or independently Mount others, such as/boot AND/var, based on your own needs. This has some advantages:

Reference:

/Boot partition, which contains the kernel of the operating system and the files to be used during system startup. It is necessary to create this partition, because most PCs are subject to BIOS restrictions, moreover, if you have a separate/boot partition, the computer can still start even if the primary root partition has a problem. The partition size is about 60 mb-120mb.

/Usr partition is the place where the software is stored in Linux. If possible, the maximum space should be allocated to it.

/Home partition is the location of your home directory. The size of this partition depends on the number of users. If multiple users use a computer together, this partition is completely necessary. Moreover, root users can well control the use of computers by common users, such as using hard disks for users or user groups, restrict common users to which files to access.

/Var/log partition is the System log Record Partition. If this independent partition is set up, even if the system log file has a problem, they also do not affect the primary partitions of the operating system.

/Tmp partition, used to store temporary files. This is necessary for multi-user systems or network servers. In this way, even if a large number of temporary files are generated during the running of the program, or the user has performed wrong operations on the system, other parts of the file system are still safe. Because this part of the file system is still subject to read/write operations, it usually occurs faster than other parts.

/Bin partition, which stores standard system utilities.

(Separate/boot partitions) 1. Several different operating systems can share the same kernel for convenient management.

2. The boot directory has less I/O access and is placed in a single partition to prevent inode corruption caused by reading and writing of other directories.

3. The old motherboard has 1024 cylinders. You can avoid this problem by dividing the first 1024 cylinders into one boot partition.

4 If RAID or LVM is used, the boot manager may not support it, and the kernel cannot be found. Therefore, the independent boot partition makes sense.

5. convenient use of tools such as dd for backup

6. You can mount the boot partition in read-only mode to increase security.

Ps: If you like tossing systems and often reinstalling them, it is really useless to separate them.

If/boot is partitioned separately,/boot is the primary partition, And/partition does not have to be the primary partition.

Safe partitioning scheme principle: system data and common user data are separated and placed in different partitions (that is, separate home partitions ); the infrequently changed system data and frequently changed system data are separated and placed in different partitions (that is, separate usr partitions and var partitions ).

Generally, at least a separate home partition must be created in an actual system.

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.