diff options
author | Alyssa Ross <hi@alyssa.is> | 2023-12-05 21:45:27 +0100 |
---|---|---|
committer | Alyssa Ross <hi@alyssa.is> | 2023-12-05 21:45:27 +0100 |
commit | d6373820f71f32f363d95ef6211d36a359c02e62 (patch) | |
tree | 47b33bc117584d028738ab02191cba9dff33a7a5 | |
parent | 009a0369c69cec24e0ffc43e4ba3d71d290b2bef (diff) | |
download | spectrum-d6373820f71f32f363d95ef6211d36a359c02e62.tar spectrum-d6373820f71f32f363d95ef6211d36a359c02e62.tar.gz spectrum-d6373820f71f32f363d95ef6211d36a359c02e62.tar.bz2 spectrum-d6373820f71f32f363d95ef6211d36a359c02e62.tar.lz spectrum-d6373820f71f32f363d95ef6211d36a359c02e62.tar.xz spectrum-d6373820f71f32f363d95ef6211d36a359c02e62.tar.zst spectrum-d6373820f71f32f363d95ef6211d36a359c02e62.zip |
Increase VM memory size
128M was not enough to even get to init on aarch64. We can probably optimise the kernel at some point, but I think that's something to do once things are further along. Signed-off-by: Alyssa Ross <hi@alyssa.is>
-rw-r--r-- | host/start-vm/lib.rs | 2 | ||||
-rw-r--r-- | host/start-vm/tests/vm_command-basic.rs | 2 | ||||
-rw-r--r-- | img/app/Makefile | 4 | ||||
-rw-r--r-- | vm/sys/net/Makefile | 4 |
4 files changed, 6 insertions, 6 deletions
diff --git a/host/start-vm/lib.rs b/host/start-vm/lib.rs index 32ba34d..5c07575 100644 --- a/host/start-vm/lib.rs +++ b/host/start-vm/lib.rs @@ -61,7 +61,7 @@ pub fn vm_command(dir: &Path, api_socket_fd: RawFd) -> Result<Command, String> { let mut command = Command::new("cloud-hypervisor"); command.args(["--api-socket", &format!("fd={api_socket_fd}")]); command.args(["--cmdline", "console=ttyS0 root=PARTLABEL=root"]); - command.args(["--memory", "size=128M,shared=on"]); + command.args(["--memory", "size=256M,shared=on"]); command.args(["--console", "pty"]); command.arg("--kernel"); command.arg(config_dir.join("vmlinux")); diff --git a/host/start-vm/tests/vm_command-basic.rs b/host/start-vm/tests/vm_command-basic.rs index 0abe23b..fac6a3d 100644 --- a/host/start-vm/tests/vm_command-basic.rs +++ b/host/start-vm/tests/vm_command-basic.rs @@ -32,7 +32,7 @@ fn main() -> std::io::Result<()> { OsStr::new("--cmdline"), OsStr::new("console=ttyS0 root=PARTLABEL=root"), OsStr::new("--memory"), - OsStr::new("size=128M,shared=on"), + OsStr::new("size=256M,shared=on"), OsStr::new("--console"), OsStr::new("pty"), OsStr::new("--kernel"), diff --git a/img/app/Makefile b/img/app/Makefile index fa8a07c..98a26eb 100644 --- a/img/app/Makefile +++ b/img/app/Makefile @@ -101,7 +101,7 @@ start-virtiofsd: .PHONY: start-virtiofsd run-qemu: $(imgdir)/appvm/blk/root.img start-virtiofsd - @../../scripts/run-qemu.sh -m 128 -cpu host -kernel $(KERNEL) -vga none \ + @../../scripts/run-qemu.sh -m 256 -cpu host -kernel $(KERNEL) -vga none \ -drive file=$(imgdir)/appvm/blk/root.img,if=virtio,format=raw,readonly=on \ -drive file=$(RUN_IMG),if=virtio,format=raw,readonly=on \ -append "root=PARTLABEL=root nokaslr" \ @@ -121,7 +121,7 @@ run-cloud-hypervisor: $(imgdir)/appvm/blk/root.img start-vhost-user-gpu start-vi rm -f build/vmm.sock @../../scripts/with-taps.elb ../../scripts/run-cloud-hypervisor.sh \ --api-socket path=build/vmm.sock \ - --memory size=128M,shared=on \ + --memory size=256M,shared=on \ --disk path=$(imgdir)/appvm/blk/root.img,readonly=on \ --disk path=$(RUN_IMG),readonly=on \ --fs tag=virtiofs0,socket=build/virtiofsd.sock \ diff --git a/vm/sys/net/Makefile b/vm/sys/net/Makefile index 6e5c651..d794df0 100644 --- a/vm/sys/net/Makefile +++ b/vm/sys/net/Makefile @@ -99,7 +99,7 @@ debug: .PHONY: debug run-qemu: build/host/data/netvm/blk/root.img - @../../../scripts/run-qemu.sh -m 128 -cpu host -kernel $(KERNEL) -vga none \ + @../../../scripts/run-qemu.sh -m 256 -cpu host -kernel $(KERNEL) -vga none \ -drive file=build/host/data/netvm/blk/root.img,if=virtio,format=raw,readonly=on \ -append "root=PARTLABEL=root nokaslr" \ -gdb unix:build/gdb.sock,server,nowait \ @@ -117,7 +117,7 @@ run-cloud-hypervisor: build/host/data/netvm/blk/root.img @../../../scripts/with-taps.elb \ ../../../scripts/run-cloud-hypervisor.sh \ --api-socket path=build/vmm.sock \ - --memory size=128M \ + --memory size=256M \ --disk path=build/host/data/netvm/blk/root.img,readonly=on \ --net tap=tap0 \ --net tap=tap1,mac=0A:B3:EC:80:00:00 \ |