"Go" Linux disk mount

Source: Internet
Author: User

Mount the new hard disk after the input fdisk-l command to see the current disk information can be seen in addition to the current first hard disk and a second hard disk SDB, and then partition into the Fdisk command with FDISK/DEV/SDB, enter H can see the help of the command, to partition by N here the input e is divided into logical partition, according to P that is divided into the main partition, we want to divide this disk into primary partition is input p to enter the primary partition as the primary partition, because it is a new disk we enter the first primary partition, cylinder is the number of starting disks to select the partition, Here can be customized or do not choose, the default is 1, if no special demand is strongly recommended to choose the default, that is, a partition (directly press ENTER) Next is to define the size of the partition, if the default (press ENTER) is the use of all available storage amount, or can be the M or m units end of the number (uppercase M If the input 1M is actually X8 8m space), here we first divided into a 1G of space, so the input +1024m after the input w write the partition, waiting for the end can be entered fdisk-l can see a partition we just divided, followed by Mkfs-t ext3-c/dev/ SDB1 format, if there are multiple partitions can change SDB1 to SDB2 sdb3 ... And so on, the specific fdisk-l can see the name of each partition blue part is written hard disk volume label, if you do not want the label can be directly press ENTER, now partitioned well we use Mount mount the partition can be used, here I mount it to the MNT directory, You can also build a directory mount to see if the partition size is the same as scheduled, use the df-th command to look at the current mount partition and size, see the partition we just divided it. If you want to automatically mount the partition every time the system restarts, you can modify the/etc/fstab file, and add a/dev/at the end. Sdb1/www ext3 defaults 1 2 (format description:/DEV/SDB1 represents which partition ext3 is the format of the partition defaults is the parameter to be set when the mount is mounted (read-only, read-write, enable quota, etc.), input defaults include Parameters (rw, dev, exec, auto, nouser, async), 1 is the use of dump whether to record, 0 is not. 2 is the boot check order, is the boot system file is 1, the other file system is 2, such as do not check for 0)

"Go" Linux disk mount

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.