Ubuntu16.04 how the second disk

Source: Internet
Author: User

The test machine has 4 hard disk, the initial intention to do a disk array, but when installing the system does not know how to choose the boot file installation, so temporarily do not use disk array (post-study)

Detects if a hard drive is recognized

[Email protected]:/# fdisk-l

disk/dev/sda:465.8 GiB, 500107862016 bytes, 976773168sectorsunits:sectors of1 * 512 = 512bytessector size (logical/physical): bytes/4096Bytesi/o Size (minimum/optimal): 4096 bytes/4096Bytesdisklabel type:gptdisk Identifier:59353137-dd3b-40ff-9656-314427de1adb device Start End sector Size type/DEV/SDA1 2048 1050623 1048576512M EFI System/dev/sda2 1050624 960419839 959369216 457. 5G Linux filesystem/dev/sda3 960419840 976771071 16351232 7. 8G Linux Swapdisk/dev/sdb:465.8 GiB, 500107862016 bytes, 976773168sectorsunits:sectors of1 * 512 = 512bytessector size (logical/physical): bytes/4096Bytesi/o Size (minimum/optimal): 4096 bytes/4096Bytesdisklabel type:dosdisk Identifier:0xc48b3f11device start start end sector Size Id type/DEV/SDB1 2048 976773119 976771072 465.8G 83Linuxdisk/dev/sdc:465.8 GiB, 500107862016 bytes, 976773168sectorsunits:sectors of1 * 512 = 512bytessector size (logical/physical): bytes/512Bytesi/o Size (minimum/optimal): bytes/512Bytesdisk/dev/sdd:465.8 GiB, 500107862016 bytes, 976773168sectorsunits:sectors of1 * 512 = 512bytessector size (logical/physical): bytes/512Bytesi/o Size (minimum/optimal): bytes/512 bytes

In

DEV/SDA is automatically partitioned when the system is installed;

Dev/sdb for manual formatting

DEV/SDC and DEV/SDD are temporarily not partitioned.

Format disk

[Email protected]:/# mkfs.ext4/dev/sdb

Mount Disk

Temporarily create a directory on your local hard drive /wwwroot

and mount a partition from the second hard drive/dev/sdb1 to /wwwroot

See if the mount was successful.

[Email protected]:/#  mkdir/wwwroot[email protected]:/#  mount/dev/sdb1/wwwroot/
[Email protected]:/#df-hFile system capacity used% availablemount point Udev3.8G 0 3.8G 0%/Devtmpfs 778M9.4M 769M 2%/Run/dev/sda2 451G 20G 408G 5%/Tmpfs3.8G 56M 3.8G 2%/dev/Shmtmpfs5.0M 0 5.0M 0%/run/Locktmpfs3.8G 0 3.8G 0%/sys/fs/Cgroup/DEV/SDA1 511M 3.6M 508M 1%/boot/Efitmpfs 778M 0 778M 0%/run/user/121tmpfs 778M 92K 778M1%/run/user/1000/dev/sdb1 459G 70M 435G 1%/Wwwroot[email protected]:/# 

Uninstalling the hard drive

#umount/DEV/SDB1

Ubuntu16.04 how the second disk

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.