Analysis on the creation of CentOS file system

Source: Internet
Author: User

Centos File system creation, modification and detection

Everyone knows the Linux system is all files, then I will give you a detailed explanation of the file system knowledge

(Note: The following operations are performed on the centos6.5 system)

before we mount the partition, we should first look at the type of file system supported by the system, and we can see the types of file systems supported by this system include:iso9660,ext4, etc.

650) this.width=650; "Width=" 553 "height=" 388 "src="/e/u261/themes/default/images/spacer.gif "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "/>

Next, you can use #:fdisk–l Query partition information, query results such as, you can see that I was hanging three hard drives

SDA, SDB, SDC, and SDA devices are already system file partitions and SDB and SDC devices are not partitions,

in the following experiment, I will use the SDB hard drive to do the operation,

650) this.width=650; "Width=" 553 "height=" 388 "src="/e/u261/themes/default/images/spacer.gif "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "/>

then we partition the file system, using the fdisk command, the full command #:fdisk/dev/sdb

650) this.width=650; "Width=" 554 "height=" 408 "src="/e/u261/themes/default/images/spacer.gif "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "/>

Enter n to indicate whether to establish a primary or extended partition, I choose P Primary partition here

650) this.width=650; "Width=" 554 "height=" "src="/e/u261/themes/default/images/spacer.gif "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "/>

And then you choose One of the 1-4, and I'm going to choose 1.

650) this.width=650; "Width=" 553 "height=" of "src=" "/e/u261/themes/default/images/spacer.gif" style= "Background:url" ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "/>

then W is the save Operation

Results can be viewed through the fdsik–l command

650) this.width=650; "Width=" 554 "height=" 347 "src="/e/u261/themes/default/images/spacer.gif "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "/>

then we need to format the partition, we use #:mkfs.ext4/dev/sdb1, SDB1 to the sub-grid operation.

650) this.width=650; "Width=" 554 "height=" 254 "src="/e/u261/themes/default/images/spacer.gif "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "/>

Finally we need to mount the partition to a directory to use

first create a new directory, where I build a mydata directory under the etc directory #mkdir/etc/mydata

650) this.width=650; "Width=" 554 "height=" "src="/e/u261/themes/default/images/spacer.gif "style=" Background:url ( "/e/u261/themes/default/images/word.gif") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "/>

and then use the Mount command to Mount it under the MyData directory.

650) this.width=650; "Width=" 554 "height=" "src="/e/u261/themes/default/images/spacer.gif "style=" Background:url ( "/e/u261/themes/default/images/word.gif") no-repeat center;border:1px solid #ddd; "alt=" Spacer.gif "/>

This allows us to write information such as files in the MyData directory.

Analysis on the creation of CentOS file 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.