fix QEMU bug that does not odd numbers for memory
This commit is contained in:
parent
56f88aad3f
commit
f74d2887fb
@ -811,9 +811,9 @@ impl VM {
|
|||||||
vars += "\n";
|
vars += "\n";
|
||||||
vars += &format!(r#"export VCPUS="{}""#, self.vcpus);
|
vars += &format!(r#"export VCPUS="{}""#, self.vcpus);
|
||||||
vars += "\n";
|
vars += "\n";
|
||||||
vars += &format!(r#"export MEMORY="{}M""#, self.memory_mb);
|
vars += &format!(r#"export MEMORY="{}M""#, (self.memory_mb / 2 * 2));
|
||||||
vars += "\n";
|
vars += "\n";
|
||||||
vars += &format!(r#"export MAX_MEMORY="{}M""#, self.memory_mb + 256);
|
vars += &format!(r#"export MAX_MEMORY="{}M""#, (self.memory_mb / 2 * 2) + 256);
|
||||||
vars += "\n";
|
vars += "\n";
|
||||||
vars += &format!(r#"export DISK="{}""#, self.disk_path());
|
vars += &format!(r#"export DISK="{}""#, self.disk_path());
|
||||||
vars += "\n";
|
vars += "\n";
|
||||||
|
Loading…
Reference in New Issue
Block a user