kvm虚机在线更改iso

 解释:guest01代表需更改的虚机名,*.iso为需添加的iso

      如果报错:

virsh # attach-disk ICCS-PM /gfs/sysdisk/installdisk-pool/cn_win_srv_2003_r2_enterprise_with_sp2_vl_cd2.iso hdc --driver file --type cdrom --mode readonly

错误:Failed to attach disk

错误:internal error unsupported driver name 'file' for disk '/gfs/sysdisk/installdisk-pool/cn_win_srv_2003_r2_enterprise_with_sp2_vl_cd2.iso'

取消--driver file参数即可

--------------------------------------------------------------------------------------------------------------------------------------

Add CDROM:

#virsh

attach-disk guest01 /root/disc1.iso hdc --driver file --type cdrom

--mode readonly

 

Change CDROM:

attach-disk guest01 /root/disc2.iso hdc --driver file --type cdrom

--mode readonly

 

Remove CDROM:

attach-disk guest01 " " hdc --driver file --type cdrom

--mode readonly

你可能感兴趣的:(kvm,更改,ISO)