国产成人精品18p,天天干成人网,无码专区狠狠躁天天躁,美女脱精光隐私扒开免费观看

KVM虛擬機怎么擴展磁盤(pán)空間

發(fā)布時(shí)間:2021-08-17 12:35 來(lái)源:億速云 閱讀:0 作者:chen 欄目: 服務(wù)器 歡迎投稿:712375056

本篇內容介紹了“KVM虛擬機怎么擴展磁盤(pán)空間”的有關(guān)知識,在實(shí)際案例的操作過(guò)程中,不少人都會(huì )遇到這樣的困境,接下來(lái)就讓小編帶領(lǐng)大家學(xué)習一下如何處理這些情況吧!希望大家仔細閱讀,能夠學(xué)有所成!

KVM支持在線(xiàn)擴展磁盤(pán)空間,支持RHEL系列6以上的版本

列出在線(xiàn)虛擬機磁盤(pán)

[root@e3 images]# virsh list --all
 Id    名稱(chēng)                         狀態(tài)
----------------------------------------------------
 29    centos6.6                      running
 41    centos6.5                      running
 -     kvm001                         關(guān)閉
 -     kvm002                         關(guān)閉
 -     kvm003                         關(guān)閉
 -     template                       關(guān)閉

[root@e3 images]# virsh domblklist centos6.5  #列出在線(xiàn)虛擬機磁盤(pán)情況
目標     源
------------------------------------------------
vda        /data/kvm/images/centos6.5.qcow2

[root@e3 images]#

創(chuàng )建一塊qcow2磁盤(pán)并在線(xiàn)添加

[root@e3 images]# qemu-img create -f qcow2 centos6.5-add.qcow2 5G #創(chuàng  )建一塊5G大小的硬盤(pán)
Formatting 'centos6.5-add.qcow2', fmt=qcow2 size=5368709120 encryption=off cluster_size=65536 lazy_refcounts=off 
[root@e3 images]# ll centos6.5-add.qcow2 
-rw-r--r--. 1 root root 197120 1月  21 18:31 centos6.5-add.qcow2
#在線(xiàn)添加磁盤(pán)
[root@e3 images]# virsh attach-disk centos6.5 /data/kvm/images/centos6.5-add.qcow2 vdb --cache=none --subdriver=qcow2   ##
成功附加磁盤(pán)

查看

[root@e3 images]# virsh domblklist centos6.5  
目標     源
------------------------------------------------
vda        /data/kvm/images/centos6.5.qcow2
vdb        /data/kvm/images/centos6.5-add.qcow2  #添加成功

#切換虛擬機里查看
[root@kvm003 ~]# fdisk -l

Disk /dev/vda: 32.2 GB, 32212254720 bytes
16 heads, 63 sectors/track, 62415 cylinders
Units = cylinders of 1008 * 512 = 516096 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000903e2

   Device Boot      Start         End      Blocks   Id  System
/dev/vda1   *           3        1018      512000   83  Linux
Partition 1 does not end on cylinder boundary.
/dev/vda2            1018       41611    20458496   8e  Linux LVM
Partition 2 does not end on cylinder boundary.

Disk /dev/mapper/VolGroup-lv_root: 19.9 GB, 19906166784 bytes
255 heads, 63 sectors/track, 2420 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000


Disk /dev/mapper/VolGroup-lv_swap: 1040 MB, 1040187392 bytes
255 heads, 63 sectors/track, 126 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000


Disk /dev/vdb: 5368 MB, 5368709120 bytes   #添加的
16 heads, 63 sectors/track, 10402 cylinders
Units = cylinders of 1008 * 512 = 516096 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

免責聲明:本站發(fā)布的內容(圖片、視頻和文字)以原創(chuàng )、來(lái)自本網(wǎng)站內容采集于網(wǎng)絡(luò )互聯(lián)網(wǎng)轉載等其它媒體和分享為主,內容觀(guān)點(diǎn)不代表本網(wǎng)站立場(chǎng),如侵犯了原作者的版權,請告知一經(jīng)查實(shí),將立刻刪除涉嫌侵權內容,聯(lián)系我們QQ:712375056,同時(shí)歡迎投稿傳遞力量。

中文字幕免费不卡二区| ZZIJZZIJ亚洲日本少妇| JUL一542人妻秘书汗中出| 天堂а√在线地址中文在线| 免费A级毛片无码免费视频首页| 欧美黑人又粗又大的性格特点|