From 1ee37f29262b5bb1a4d916f95b1e657b3aa16fec Mon Sep 17 00:00:00 2001 From: Nathan Steel Date: Tue, 16 Aug 2022 16:19:44 +0100 Subject: [PATCH] Add start of virsh-cheatsheet blog article --- blog/virsh-cheatsheet.html | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/blog/virsh-cheatsheet.html b/blog/virsh-cheatsheet.html index 3fce9bb..1daac12 100644 --- a/blog/virsh-cheatsheet.html +++ b/blog/virsh-cheatsheet.html @@ -73,12 +73,15 @@

Delete the snapshot, this doesn't delete anything else related to the VM

virsh snapshot-delete --domain $vm --snapshotname $snapshot_name
-

Drive management

+

(TODO)Drive management

Change Memory

In variantions of 512M, 1G, etc

virsh setmem $vm $ram
+

The amount of RAM the VM has assigned to it, this cannot be higher than the max, but can be altered on the fly (if I recall correctly).

virsh setmaxmem $vm $ram
+

The max mem sets the maximum amount of RAM the VM can use, and can only be set whilst the VM is offline

+

My recommendation here is to set a higher maxmem than you'd need, so if you do need to add some more RAM, it doesn't require any downtime.

Change vCPU cores

This is a little more tricky, as it involves editing the XML file