Linux hard disk mounting

Source: Internet
Author: User

Recently, a production machine has loaded a hard disk because the hard disk is not enough due to cache problems. The hard disk mounting process is recorded below for your reference. If you have any questions, please leave a message!

 

Fdisk-l

----------------------------------------------------------------------------
Disk/dev/sda: 10.7 GB, 10737418240 bytes
255 heads, 63 sectors/track, 1305 cylinders
Units = cylinders of 16065*512 = 8225280 bytes
Disk identifier: 0x000af383

Device Boot Start End Blocks Id System
/Dev/sda1*1 1244 9992398 + 83 Linux
/Dev/sda2 1245 1305 489982 + 5 Extended
/Dev/sda5 1245 1305 489951 82 Linux swap/Solaris

Disk/dev/sdb: 5368 MB, 5368709120 bytes
255 heads, 63 sectors/track, 652 cylinders
Units = cylinders of 16065*512 = 8225280 bytes
Disk identifier: 0x00000000

Disk/dev/sdb doesn' t contain a valid partition table
----------------------------------------------------------------------------
1

The newly added hard disk is/deb/sdb, but no partition table exists.

 

3. partitions

Fdisk/dev/sdb

There are many options, select m

Then select n

Then select p

Then select 1

There are two more options.

1
2
First Cylinder (1-1014, default 1 ):
Last cylindet or + siza or + sizeM or + sizeK:
I have selected the default option, input w, save, and exit

 

4. format the partition.

1
Sudo mkfs-t ext3/dev/sdb1

5. Mount partitions

1
2
3
Sudo mkdir/www // create a new mount point and install it with matlab
Sudo mount/dev/sdb1/www
Sudo df

6. automatic mounting upon startup

1
Vi/etc/fstab // modify this file, or use gedit.

Then add to the end

1
Dev/sdb1/www ext3 defaults 1 2

In this way, you can mount www. OK!

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.