FreeBSD kernel change to NetBSD kernel

As stated in the title, I would like to change the kernel of my Unix build from FreeBSD to NetBSD, as I prefer the philosophy of the rump kernel to that of a monolithic, but prefer the lexicography and semantics of FreeBSD's system applications. The current build is FreeBSD, with only sudo, neovim and git installed. It is running in a VM, so I don't think any additional drivers are installed, if that is optional during the install process. (I've installed OS's so many times that it is practically subconscious for me) My question is this: is it possible to swap to the NetBSD kernel in FreeBSD? If so, I will build the kernel from source and swap it.
 
NetBSD is FFSv2
Ok, that says what NetBSD is, but my point was "It sounds like you currently are running a FreeBSD Kernel. What file system are you using under FreeBD? If UFS then it may be possible, if you are using FreeBSD with ZFS then you may be up the creek sans paddle because I don't think NetBSD supports ZFS".

If it's a VM my opinion, "pick one and stick with it". Pick NetBSD for the VM, pick FreeBSD for the VM. Mixing has a 99.44% chance of screwing you over. But honestly, your VM, your choice, not my problem.
 
... but prefer the lexicography and semantics of FreeBSD's system applications.
What are you referring to as "system applications"? Things included in base (like find and tar), or packages? Our of curiosity, can you explain what "lexicography and semantics" means, and what specific differences you see?
 
Likely not without a lot of work. FreeBSD's userland requires a bunch of syscalls in place, which may look very different with NetBSD (disclaimer: not a NetBSD expert by any means). You probably end up rewriting the whole of userland at which point it might be easier to rewrite NetBSD to just get the same structure and naming convention as FreeBSD.
 
That would be an interesting experiment, please tell us if you manage to build something usable. But unless you're an expert in operating system internals, your chances of success are very low: although they were forked from a common ancestor 30 years ago, NetBSD and FreeBSD are vastly different nowadays, so your idea is probably not much easier to implement then getting a Linux kernel to run on top of a FreeBSD userland.

I don't think NetBSD supports ZFS
It does.
 
So maybe instead what I should do is start with NetBSD and swap the desired programs?

That would be the approach I take, for the following reason...

If you try to put the NetBSD kernel into a working FreeBSD install, then you are taking a solid environment and introducing a very significant unknown to that environment, affecting very critical areas of the installation.

However, if you take a working NetBSD and change out some programs, the shock to the installation is much less significant, and may affect less-critical areas of the installation.

In other words, start with a known, solid foundation and make changes on top of that. Don't try to swap the foundation out from under an existing building.
 
It's a different kernel with different syscalls so you can't use a jail. You must use a virtual-machine like qemu,virtualbox,bhyve.
 
Bastille installs a userland kernel of choice, then a separate base system of choice. Though, both have always been versions of FreeBSD components so far.
 
But unless you're an expert in operating system internals
Not in the slightest. I have a basic understanding of system administration in Linux, and used to be absolutely enamored with Linux. Less so am I anymore. I have no idea what I’m doing really. Honestly though, I used to love making FrankenDebians. The builds didn’t last long, if at all, but it was fun. I am moving to BSD because A) it satisfies my need to do shit in ways that most people in my own culture don’t, and B) I prefer the BSD license to GPL, as it gives you, the programmer, more freedom. Oh yeah, and systemd. Red Hat/IBM can eat a bag of dicks.
What are you referring to as "system applications"? Things included in base (like find and tar), or packages? Our of curiosity, can you explain what "lexicography and semantics" means, and what specific differences you see?
I just throw terms around until I have a word spaghetti that makes sense to me. As people correct me, I improve upon my vocabulary, and move on. I prefer some of the tools of the FreeBSD userland, but yeah… Just ignore that stupid I made. I do that quite often.
That would be the approach I take, for the following reason...

If you try to put the NetBSD kernel into a working FreeBSD install, then you are taking a solid environment and introducing a very significant unknown to that environment, affecting very critical areas of the installation.

However, if you take a working NetBSD and change out some programs, the shock to the installation is much less significant, and may affect less-critical areas of the installation.

In other words, start with a known, solid foundation and make changes on top of that. Don't try to swap the foundation out from under an existing building.
So if I want the backwards learning experience (which I somewhat do)…

Anyway, I’m getting really pissed I have to work with windows, so I’m probably gonna dual boot Debian and change the kernel (Bullseye only has the 5.10 kernel but bullseye-backports has Linux 6.0). Once that is working, I will go back to working with BSD.
 
Back
Top