linux 下掛載磁碟陣列

來源:互聯網
上載者:User

3.把磁碟陣列掛到linux 系統上來

[root@database1 ~]# fdisk -l

Disk /dev/sda: 146.9 GB, 146999869440 bytes
255 heads, 63 sectors/track, 17871 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1          13      104391   83  Linux
/dev/sda2              14        2053    16386300   82  Linux swap / Solaris
/dev/sda3            2054       17714   125796982+  83  Linux
/dev/sda4           17715       17871     1261102+   5  Extended
/dev/sda5           17715       17871     1261071   8e  Linux LVM

Disk /dev/sdb: 2186.1 GB, 2186127343616 bytes
255 heads, 63 sectors/track, 265781 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

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

Disk /dev/sdc: 20 MB, 20971520 bytes
1 heads, 40 sectors/track, 1024 cylinders
Units = cylinders of 40 * 512 = 20480 bytes

Disk /dev/sdc doesn't contain a valid partition table

Disk /dev/sde: 20 MB, 20971520 bytes
1 heads, 40 sectors/track, 1024 cylinders
Units = cylinders of 40 * 512 = 20480 bytes

Disk /dev/sde doesn't contain a valid partition table

 

上面的 Disk /dev/sdb: 2186.1 GB, 2186127343616 bytes
就是我們分配給linux的磁碟陣列的 2T 的空間
我們做如下的操作:
1)fdisk /dev/sdb  
輸入m
    Command (m for help): m   
    寫分區表
    2)Command (m for help): p      5、6
    3)添加一個新的分區,分區號為1
    Command (m for help): w      7
    4)下面要負載檔案系統,選擇ext3檔案系統進行載入
[root@localhost ~]# mkfs.ext3 /dev/sda      8
5)建立一個檔案夾
mkdir /pz
    6)把檔案系統掛接到linux上去
    mount /dev/sdb  /pz
    7)確認掛載成功
    [root@database1 /]# df -m
檔案系統               1M-塊        已用     可用 已用% 掛載點
/dev/sda3               119001      3184    109675   3% /
/dev/sda1                   99        12        83  13% /boot
tmpfs                     3988         0      3988   0% /dev/shm
/dev/sdb               2052141       199   1947700   1% /pz

 

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

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.