redhat:virtualization-redhat:start

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Next revisionBoth sides next revision
redhat:virtualization-redhat:start [2020/04/01 11:16] michaelredhat:virtualization-redhat:start [2020/04/01 12:05] – [Configure KVM Environment] michael
Line 123: Line 123:
  
 <WRAP center box 100%> <WRAP center box 100%>
-Validate all the components on your KVM host can support virtualization.+''Validate all the components on your KVM host can support virtualization.''
  
 <code> <code>
Line 188: Line 188:
 KVM and QEMU hypervisors has been installed on CentOS 8. KVM and QEMU hypervisors has been installed on CentOS 8.
  
 +
 +===== Configure KVM Environment =====
 +
 +<WRAP center box 100%>
 +''Allow QEMU/KVM Commands for personal user:''
 +
 +If you want to allow your login user (non-root) to run virsh command or other KVM/QEMU commands, or use these commands without sudo, (needed by cockpit) then add your login user to the libvirt group as follows:
 +
 +<code>
 +# usermod -aG libvirt YOURUSERNAME
 +</code>
 +</WRAP>
 +
 +<WRAP center box 100%>
 +''Setup own VM-Storage / ISO-Storage configuration:''
 +
 +----
 +
 +Create needed directories:
 +
 +<code>
 +# mkdir -p /data01/vm-storage
 +# mkdir /data01/iso-images
 +</code>
 +
 +----
 +
 +Make the virsh pool configuration changes:
 +
 +  - Listing current pools: <code># virsh pool-list</code><sxh bash; gutter: false;>
 +
 +Name                 State      Autostart 
 +-------------------------------------------
 +default              active     yes 
 +</sxh>
 +  - Destroying pool:<code># virsh pool-destroy default</code><sxh bash; gutter: false;>Pool default destroyed</sxh>
 +  - Undefine pool:<code># virsh pool-undefine default</code><sxh bash; gutter: false;>Pool default has been undefined</sxh>
 +  - Defining a new pool with name "default":<code># virsh pool-define-as --name default --type dir --target /data01/vm-storage</code><sxh bash; gutter: false;>Pool default defined</sxh>
 +  - Set pool to be started when libvirt daemons starts:<code># virsh pool-autostart default</code><sxh bash; gutter: false;>Pool default marked as autostarted</sxh>
 +  - Start pool:# virsh pool-start default</code><sxh bash; gutter: false;>Pool default started</sxh>
 +  - Checking pool state:<code># virsh pool-list</code><sxh bash; gutter: false;>
 +Name                 State      Autostart 
 +-------------------------------------------
 +default              active     yes  
 +</sxh>
 +
 +From now, when creating virtual machines, Virtual Machine Manager will inform you that the *.img file (virtual disk of your VM), will be saved at ''/data01/vm-storage/''.
 +</WRAP>
  
 ===== Installing Cockpit Web Interface in CentOS 8 ===== ===== Installing Cockpit Web Interface in CentOS 8 =====
  • redhat/virtualization-redhat/start.txt
  • Last modified: 2020/09/02 12:37
  • by michael