Live data from Hacker News

Microsandbox: Virtual Machines that feel and perform like containers

github.com

61–70 of 195 posts

Re: Microsandbox: Virtual Machines that feel and perform like containers

#61
post #44

I've been looking for something I could host for this kind of thing - for LLM agents. Ended up on https://www.daytona.io/ as I couldn't find anything suitable to self host and realised it was a complex thing to manage. It seems Daytona is open source, including the server platform, but there is no documentation for the server element. Azure also seem to offer a service for this, it's a space that is growing rapidly.

Microsandbox is for people that would like to maintain their own infra. I'm not going to stop trying to make it better to self-host.

Yeah, it looks great, makes me reconsider the self hosted route

Re: Microsandbox: Virtual Machines that feel and perform like containers

#62
Kind of almost off-topic: I'm working on a project where I must run possibly untrusted JavaScript code. I want to run it in an isolated environment. This looks like a very nice solution as I could spin up a microsandbox and securely run the code. I could even have a pool os live sandboxes so I wouldn't even experience the 200ms starts. Because this is OCI-compatible, I could even provide a whole sandboxed environment on which to run that code. Would that be a good use case for this? Are there better alternatives?

Re: Microsandbox: Virtual Machines that feel and perform like containers

#64

Thanks for sharing! I'm the creator of microsandbox. If there is anything you need to know about the project, let me know. This project is meant to make creating microvms from your machine as easy as using Docker containers. Ask me anything.

Can you use Microsandbox for everything you can use Docker for, or are there cases where containers make more sense?

Congratulations on the launch!

Re: Microsandbox: Virtual Machines that feel and perform like containers

#65

Kind of almost off-topic: I'm working on a project where I must run possibly untrusted JavaScript code. I want to run it in an isolated environment. This looks like a very nice solution as I could spin up a microsandbox and securely run the code. I could even have a pool os live sandboxes so I wouldn't even experience the 200ms starts. Because this is OCI-compatible, I could even provide a whole sandboxed environment…

> Would that be a good use case for this?

That is an ideal use case

> Are there better alternatives?

Created microsandbox because I didn't find any

Re: Microsandbox: Virtual Machines that feel and perform like containers

#66

Tangential question: why does it normally take so long to start traditional VMs in the first place? At least on Windows, if you start a traditional VM, it takes several seconds for it to start running anything . Edit: when I say anything , I'm not talking user programs. I mean as in, before even the first instruction of the firmware -- before even the virtual disk file is zeroed out, in cases where it needs to be. Yo…

Sounds like a VirtualBox problem.

I'm using Hyper-V and I can connect through XRDP to a GUI Ubuntu 22 in 10 seconds and I can SSH into a Ubuntu 22 server in 3 seconds after start.

Re: Microsandbox: Virtual Machines that feel and perform like containers

#68

Thanks for sharing! I'm the creator of microsandbox. If there is anything you need to know about the project, let me know. This project is meant to make creating microvms from your machine as easy as using Docker containers. Ask me anything.

i'm on a mid-level laptop, at times with slow or expensive internet, running ubuntu. i want to be able to run nominally-isolated "copies" of my laptop at near-native speed

1. each one should have it's own network config, eg so i can use wireguard or a vpn

2. gui pass-through to the host, eg wayland, for trusted tools, eg firefox, zoom or citrix

3. needs to be lightweight. eg gnome-boxes is dead simple to setup and run and it works, but the resource usage was noticeably higher than native

4. optional - more security is better (ie, i might run semi-untrusted software in one of them, eg from a github repo or npm), but i'm not expecting miracles and accept that escape is possible

5. optional - sharing disk with the host via COW would be nice, so i'd only need to install the env-specific packages, not the full OS

i'm currently working on a podman solution, and i believe that it will work (but rebuilding seems to hammer the network - i'm hoping i can tweak the layers to reduce this). does microsandbox offer any advantages for this use case ?

Re: Microsandbox: Virtual Machines that feel and perform like containers

#69

Earlier quoted context omitted.

That's not what I'm asking about. I'm saying it takes a long time for it to even execute a single instruction, in the BIOS itself. Even for the window to pop up, before you can even pause the VM (because it hasn't even started yet). What you're describing comes after all that, which I already understand and am not asking about.

probably the intel ME setting up for virtualization in a way that it can infiltrate

Ah yes, the source of all slowness in the CPU: hostile backdoors taking their time to compromise the work. Classic...

Re: Microsandbox: Virtual Machines that feel and perform like containers

#70

Congrats on launching! Booting VMs in milliseconds is certainly important, but it can also be achieved with CloudHypervisor/Firecracker. Where Containers beat VMs is runtime perf. The overhead in case of VMs stems from emulation of IO devices. I believe the overhead will become noticeable for AI agentic use cases. Any plans to address perf issues?

You are right. We leverage libkrun. Libkrun uses virtio-mmio transport for block, vsock and virtio-fs to keep overhead minimal so we basically depend on any perf improvement made upstream.

Firecracker is no different btw and E2B uses that for agentic AI workloads. Anyway, I don't have any major plan except fix some issues with the filesystem rn.

Post reply on HN