Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Linux Containers on FreeBSD (github.com/containerd)
40 points by gslin on June 15, 2022 | hide | past | favorite | 16 comments


This is a huge missing piece for FreeBSD. If docker Linux containers could run a-la macOS, via hypervisor, would be a huge boost in FreeBSD adoption.


> If docker Linux containers could run a-la macOS, via hypervisor, would be a huge boost in FreeBSD adoption

Hypervisor-based Linux is going to be more compatible with the bleeding edge of Linux kernels, but using a system call compatibility library seems more elegant, so I'm happy to see this, and I'd like to see a version for macOS as well.


Could be. However I know that one approach works wonders because I use a Mac daily. The other might be harder to maintain in the long run.


> This is a huge missing piece for FreeBSD.

How do you figure that? I thought this space was covered by FreeBSD jails, except Docker is 3rd party, jails are baked in to FreeBSD, and Docker is only able to run containers, while jails run FreeBSD and Linux programs. Maybe Docker can run in a jail on FreeBSD? idk. But it just seems like you're making a declarative statement from the perspective that "Linux is everything that matters" without being aware of jails and BHyVe, but then again, I am replying without much knowledge of Docker and not any understanding why young devs think it is the Second Coming.


Making too many assumptions might come back and bite you. Be smarter, if you wanna be taken seriously.


Is this using a VM to run Linux+containers or using the facilities in the freebsd kernel to emulate linux+syscalls?


This is using the facilities in FreeBSD to run Linux binaries directly it looks like using emulated linux sys calls.


You can already run Docker on Linux running as a guest on FreeBSD's own bhyve hypervisor. Pick a small Linux distro and go for it if you're prepared to accept the overhead.


But there is no overhead in Mac. At least not a UX overhead, the i/o performance is poor compared to Linux but no one cares.


I didn't know about LinuxJails (a technically appropriate and also rather amusing name) but I like it.

It also makes me dream of a day when BSD (including macOS) and Linux could agree on an interoperable system call interface and file system layout.


>LinuxJail

Ok I am sold.


I guess this depends very much on what the container image does. Doing basic Unix/Posix stuff in an application container shouldn't be that much work. But until systemd or something else very Linux-specific runs in a system container sounds like a huge amount of work.


From my experience there are few examples of software that’s both Linux-specific and actually useful. As for systemd - which container mechanisms depend on it?


It's the other way round. systemd depends on functionality offered by the Linux kernel like e.g. cgroups.


Okay, so what? The reason for missing support for those mechanisms is mostly the lack of need. And this goes deep in the Linux land, for example the Linux-specific signalfd(2) system call is pretty much completely unused - except for systemd.


I wanted BSD Jails on Linux, not the other way.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: