DragonFly BSD 6.4
dragonflybsd.orgCan somebody explain the niche or role of Dragonfly BSD? I'm only vaguely familiar with BSDs. So far my impression is that OpenBSD is the secure one, FreeBSD is the fast one (for servers). What's DragonFly good at?
Originally it was planned to be a distributed OS. The main reason for the fork from FreeBSD was disagreement about what the threading primitives and their semantics should be, IIRC. One major early goal was cache coherency between different machines, though that seems to be abandoned or indefinitely on hold. Other projects have been HammerFS(a filesystem similar to ZFS, and I believe it started before ZFS was ported to FreeBSD), moving more towards a microkernel approach, and dropping support for all platforms other than x86_64. This makes the implementation of things like threading much simpler.
In short, DragonflyBSD is Dillon's experimental OS with ideas he would never be able to get into FreeBSD. It's never really found a niche for production use as far as I can tell, but I'd love to be proven wrong on that.
Source: FreeBSD user of several years either as a server OS, workstation OS or both. And I've dabbled with Dragonfly and love reading about obscure unices and their quirks.
> FreeBSD user of several years either as a server OS, workstation OS
Oh, could you give a bit of an overview of the State of FreeBSD on the Desktop (or laptop)? I'm playing with the idea. Tried OpenBSD for a while but it just wasn't very consumer-ready. No bluetooth support at all, videos would have audio and video lag, and other issues. Is FreeBSD more suited to daily consumer laptop use? I use Arch btw
There are some tricks with OpenBSD. First, with blueooth, if I recall, OpenBSD devs are not a huge fan of bluetooth. OpenBSD takes a security above all else approach I believe this plays a bit of a role since bluetooth is often poorly implemented by bluetooth devices, so there isn't a huge drive for it to work well on OpenBSD. Bluetooth is also a nightmare to implement and the interest in picking up the torch probably isnt there. Second, small dev team with limited access to hardware. If you want to get the best support for OpenBSD, I've always heard that running Lenovo Thinkpads are the way to go. Quiet a bit of the dev team mains Thinkpads for laptops and they dog food their own code. So the Thinkpads often get the fastest and best support.
> if I recall, OpenBSD devs are not a huge fan of bluetooth
iirc, when they went to implement it in OpenBSD, it was decided the bluetooth stack was basically just too poorly implemented and not really secure. I think if we ever see bluetooth in OpenBSD it will be a rewrite by some of their devs; basically when one of them decides to scratch an itch.
I have been using FreeBSD as my primary OS since version 1.1.5, and I am currently running 12.4 on a Lenovo T480.
This is what works flawlessly on my configuration (SSD, 8G bytes of RAM): gigabit ethernet, second monitor via HDMI, USB mouse and keyboard, sound via audio jack, video playback on both the internal and external monitor. What I have not tried is Wifi, Bluetooth, the fingerprint reader, and the touchpad (disabled via BIOS). The trackpoint and buttons do work.
IMHO, FreeBSD is a nice system for everyday use. Note, though, that I do mostly terminal-based stuff (and some Ghostview, PDF reading, web browsing, occasional video watching, etc), so YMMV.
It's been a couple years since I daily drove FreeBSD on, my desktop/workstation and I never ran it on a laptop. Still chugging along on my home built NAS(read: shitty old tower with a bunch of disks in it) though.
I switched over from Arch on the desktop for a couple years at one point, and overall I was very happy. The FreeBSD project is still going strong, and they've been greatly improving their Linux syscall compat layer the last few years. ZFS support is great. It's perfectly viable as a desktop OS if you're experienced with Arch and you don't use a lot of weird hardware or software.
What I did when switching was just to install it and start slowly rebuilding my Arch setup as much as possible. It's a fun weekend project with some patience, and you'll quickly find what the pain points might be that way.
Just check that your hardware is supported before installing.
>Is FreeBSD more suited to daily consumer laptop use? I use Arch btw
It can be, it depends on what you use your laptop for. For example, if you game, maybe sticking with Arch is for the best. Bluetooth is supported on Free and NetBSD, but I haven't used it on those os's. EDIT: FreeBSD supports bluetooth, but support might be spotty/depend on how old/new the hardware is. On Free/Net, bluetooth also seems less straightforward ("user friendly) than on linux or commerical OS's like MacOS.
Since you're used to arch, installing, configuring, and maintaining FreeBSD shouldn't be too difficult. Try it in a VM for a while until you get used to using vs linux.
WiFi - doesn't work, you're going to run a VM with linux and pass Wi-Fi device there or deal with 802.11g speed if card even works at all.
GPU - if you're okay with Nvidia blob, then it's all good. If not, then I hope you're okay with RX580 era AMD.
Bluetooth...I don't think people in community know what it is because stack was broken for probably a decade.
Consumer NICs sometimes don't work out of the box.
It's very unfriendly for consumer, which is what I liked, but at one point I had enough and switched to Linux. Still running FreeBSD on home server, tho because i'm too lazy to switch it...
Have you tried iwlwifi?
Yes, it works exactly like I've described:
While iwlwifi supports all 802.11 a/b/g/n/ac/ax the compatibility code currently only supports 802.11 a/b/g modes. Support for 802.11 n/ac is to come. 802.11ax and 6Ghz support are planned.
We will get wider IPv6 adoption before 802.11n works on FreeBSD in stable way.
You can use WifiBox[1], being a user of FreeBSD myself (Laptop, Workstation and many servers) it would be nice to have "native" ac/ax.
Yes, I've mentioned that solution. It isn't really "FreeBSD support wireless" if I have to run a VM for it, is it?
Ah, my bad -- I misread the 'or' as 'and'. Agreed, lack of n/ac/ax has been an issue! Especially when cloning large repos I didn't realize how much I take >500mbps on wifi for granted.
I ran FreeBSD on my desktop for a while; it's fine as a daily driver. I can't speak to bluetooth, and I'm not sure I'd trust it on a laptop (given how hard it is to get suspend working properly even on Linux), but wifi and video work great (you can run the proper nvidia drivers same as Linux).
I used it to help recover a messed-up Linux instance, copying files over with either Samba or NFS; think NFS kept messing up. But yeah, it'll work as a Windows-friendly file server!
Is it still aiming for being a distributed OS?
Not explicitly it seems, although it certainly has a lot of the necessary features, like a message passing layer and network mirroring support in HammerFS.
I don't think it has a niche or role anymore. Some years ago they claimed to be fast. [0,1,2]
I don't know where did you get that FreeBSD is regarded as the fast one. I think it is considered the popular/general purposed one, without a single aim like openBSD or netBSD have.
[0] : https://www.dragonflybsd.org/performance/
>Some years ago they claimed to be fast.
It is fast, maybe the fastest of all BSD's:
You are right, it seems much faster than freeBSD in a lot of areas and relevant benchmarks (real world programs and scenarios).
They got similar overall results, but as far as I see, freeBSD is mainly faster in irrelevant benchmarks. (This is an opinion based on a glance of the phoronix article. I haven't spent much time looking at the results, also I am not an expert at benchmarking.)
I mean it's just impressive for such a small project, and benchmark's...well they just count for your very own workload..it's good to find regressions but not much else.
BTW i run FreeBSD ;)
FreeBSD focuses on performance moreso than Net or OpenBSD.
Maybe just cause allegedly Netflix uses it for servers.
>allegedly Netflix uses it for servers
Not really "allegedly" as you can read here:
Dragonfly BSD is very good at being bad at taking constructive feedback /s
It was born out of disagreement about how SMP should work in FreeBSD around Northwood P4 era (first HyperThreaded consumer CPU). Around that time, every general purpose OS as absolutely horrible at utilizing more than one logical cores.
FreeBSD first gained SMP support at 5.0, and it was actually usable at 5.2. DragonFly BSD author had a disagreement how to implement it and though 5.x direction is bad, so, IIRC, he forked 4.x line and implemented his own vision from there. Then it was "FreeBSD does it, so I'm going to do it differently", at least that's how it looks from an outside perspective.
So, it's good at SMP if we're going by that outdated classification of BSD systems.
A lot of people would consider FreeBSD 5.x a horrible release (especially given how rock solid 4.x was), and things not stabilizing again until 8.x (many years later).
Some would argue that in hindsight, Matt was correct at the time for the fork - from a technical standpoint.
I remember explaining why I used FreeBSD instead of Linux back in the day, and just after I said "it's a bit more stable than Linux" the system completely froze. Ouch, embarrassing. Needless to say, no one was especially convinced. That was on 5.0 or 5.1 IIRC.
(These days, there isn't too much of a difference any more; Linux has come a long way in the last 20 years.)
My whole journey to freebsd started because I had a very old PC that I used as PPTP server while running not-so-legal ISP in the neighborhood. FreeBSD happened to be the greatest for this because of in-kernel support thanks to netgraph, but the real reason why - Linux couldn't finish the installation on that machine without crashing. FreeBSD meanwhile kept working until I made enough money to buy a better hardware.
Just for that reason, I will forever love it, but won't be using it on desktop - I can't use 10 years for GPU drivers on my main rig.
Oh, I know. I suffered the entire way to 8.0. Until 5.2 it was completely unusable. I also remember unplugging or plugging USB device would often lead to kernel panic until 9.0 IIRC.
I agree that he was correct at the time. Likewise, I do wish that split never happened, though.
> * I do wish that split never happened*
I too wish the split hadn’t happened, and for Matt’s ideas to have landed in FreeBSD.
Dragonfly today is remarkable, still competing head to head with FreeBSD 15 years later but with a development team literally 1/50th the size.
FreeBSD doesn’t have 50 active core developers so it’s hard to imagine how Dragonfly could be 1/50th the size.
FreeBSD (402)
https://docs.freebsd.org/en/articles/contributors/#staff-com...
vs.
DragonflyBSD (67)
https://www.dragonflybsd.org/team/
So, correct. Not 1/50th.
The majority of names on the FreeBSD list are relatively inactive.
My impression(i only really use openbsd)
Freebsd has the most developer resources and tends to be good at optimizing for speed but the userland always feels, it is hard to explain, but off, if you are fine with with the linux userland this will be a step up, openbsd, a step down. It has very good zfs integration and that is a solid reason for using it alone.
Netbsd just sits in the corner doing their own thing, I am not sure what that is but I suspect if I had not fallen for openbsd I would be using netbsd. A good solid small OS.
Dragonfly has an incredible main developer who has strong views about how parallel systems should be structured and the programing chops to pull it off. If you can take using a system with absolutely minuscule developer resources you will find real gems here, an amazing filesystem and very good multiprocessor support.
Openbsd strives for correctness above all else, speed tends to be a second class citizen, that is, if the developers have to make a choice between a simple obviously correct solution and a messy but quick one, they will almost always go for the simple one. speed is fine but not at the expense of readability. the system is probably the most full featured. With an emphasis on network daemons. but limited developer resources keep everything simple. I think of it as the best desktop system due to it's ease of administration and excellent ports system.
>Netbsd just sits in the corner doing their own thing, I am not sure what that is but I suspect if I had not fallen for openbsd I would be using netbsd. A good solid small OS.
Portability, pkgsrc, some neat innovations, and a small and welcoming community. I'm not qualified to judge this, but they also value code quality and security.
I was an OpenBSD and FreeBSD user at that time DragonFly was announced so I remember the original fork. Improving SMP (or SMP at all) was a thing a few of the BSDs were working on around this time as I believe processors were starting to add hyper-threading. I think that was the core rationale for the fork but Matt Dillon had a few other things he was trying. There have been a few similar forks like this where someone wanted to go their own way some with better success than others.
See Annoucning DragonFly BSD!
https://lists.freebsd.org/pipermail/freebsd-current/2003-Jul...
Further reading
First two paragraphs of History section found on DragonFly web site[1]:
> A technical introduction: The ultimate goal of the DragonFly project at its inception was to provide native clustering support in the kernel. This type of functionality requires a sophisticated cache management framework for filesystem namespaces, file spaces and VM spaces. These and other features eventually culminate in the ability to allow heavily interactive programs to run across multiple machines with cache coherency fully guaranteed in all respects. This also requires being able to divide resources, including the CPU by way of a controlled VM context, for safe assignment to potentially unsecured third-party clusters over the internet. This original design direction, although no longer the primary goal of the DragonFly project, has influenced many of the design decisions made in the intervening years. While full cache coherency is no longer a top level goal, filesystem coherency is, and that direction continues to guide the project in a number of ways.
> DragonFly BSD was forked from FreeBSD 4.8 in June of 2003, by Matthew Dillon. The project was originally billed as "the logical continuation of the FreeBSD 4.x series", as quoted in the announcement, but this description has long since become obsolete. From a performance perspective DragonFly's only real competitor these days is Linux.
Yea, I checked the about section of the website a bit and honestly didn't get it :) Not familiar with most of the terms.
Roughly the original idea was similar to https://en.wikipedia.org/wiki/Single_system_image That is, make a cluster of machines look like a single BSD instance, by allowing virtual memory to span multiple machines, processes to move, etc, all while preserving cache coherency.
Obviously this is an insanely difficult goal, which is why DragonFly didn't make it particularly far towards it. Additionally we've seen the rise of virtualization and systems like k8s for managing clusters, which would reduce interest from potential collaborators.
From Wikipedia:
Intended as the logical continuation of the FreeBSD 4.x series, DragonFly has diverged significantly from FreeBSD, implementing lightweight kernel threads (LWKT), an in-kernel message passing system, and the HAMMER file system. Many design concepts were influenced by AmigaOS.
I am a bit of a BSD outsider, but I've been exploring them recently.
I'd say it's more like:
• NetBSD – the oldest, aims at the widest platform support
• FreeBSD – next oldest, aims at modern hardware, best hardware and desktop support, native ZFS.
• OpenBSD – a bit younger, aims at correctness and security, so very basic hardware support, e.g. no Bluetooth at all. But that means it supports some of the newest kit, e.g. Apple M1 and M2, because its idea of "support" is so rudimentary.
• Dragonfly BSD – the youngest, the most experimental. X86-64 only. Aims at supporting lots of CPUs, lots of memory, lots of disk via a homegrown fancy modern FS, HAMMER2.
So, no, I suspect DragonFly is the fastest.
DragonFlyBSD is Dillon’s FreeBSD. It’s a fork because of personality disagreements between Dillon and other developers in the FreeBSD 5.0 timeframe. It does some interesting experimental stuff like HammerFS but isn’t really suitable for general use.
>but isn’t really suitable for general use.
Can you tell me why? Because i used it for 3 years regularly in a professional setup (~10 servers). Never had a problem with hammer 1 or 2 or anything else.
Perhaps a bit too scandalous (I don't know), but my understanding is that there was also a falling out of sorts between the DragonFly lead and BSD people, largely caused by allegedly abusive behaviour form the DragonFly lead while they were still working on BSD main. As I understand it, DragonFly came after this. Maybe doesn't answer your question, but it contextualises (however accurately!) part of how it came to be.
My source on that is a LinuxConfAU talk I can't recall off the top of my head (the same speaker gave a somewhat notable talk in defence of SystemD)
Benno Rice -> "The Tragedy of systemd" OR "The Trouble with FreeBSD"
I am a bit torn apart about him, he's half right half wrong, anyway it's good to have discussions like that.
The original plan was a SSI, single-system-image operating system, where one cohesive system could span across multiple physical machines. It's quite a long ambitious plan, but it's still up on the project's history page[1]:
> DragonFly BSD has been going through rapid and ever increasing development since the fork. One of the important works included the simplification and general cleanup of the majority of the kernel subsystems. This work was originally intended to support single system image clustering, but has had the effect of making the kernel much more reliable, understandable and easily maintainable. One of the fundamental synchronization concepts that DragonFly uses throughout the kernel, the token, lends itself directly to ease of maintenance and understandability of the kernel.
There's been plenty of neat off-shoot advantages DragonflyBSD has gained along this quest. Great great scalability has been notable; the core coherency construct, the serializing token, targets reducing locking in the system & potentially allows scale-out into SSI. DragonflyBSD has some really cool tricks, like being able to run virtual kernels- running a kernel as a process, for "jail" or just kerneldev reasons.
Still it's impossible to mention DragonflyBSD without mentioning it's filesystem, HAMMERFS, and now HAMMERFS2, which is a great Copy-on-Write & snapshotted fs intended for radical scale out, & ultimately, clustering, where multiple machines can cohesively contribute & operate a single filesystem together, with pooled resources. There is already a good bit of quorumed clustering support in HAMMERFS2.
> The HAMMER filesystem is also intended to serve as a basis for the clustering and other work that makes up the second phase of the project.
There's a StackOverflow question talking to DragonflyBSD as a SSI[2] as well, which mainly cites the same History page, but also has some other links.
[1] https://www.dragonflybsd.org/history/
[2] https://unix.stackexchange.com/questions/429464/dragonfly-bs...
I always thought it was centered around the HammerFS.
Based on the Wikipedia page, HammerFS does basically everything.
Would be interesting to know the hardcore performance benchmarks for memory handling, comparing Darwin, Linux, Dragonfly and sw-engineer's aesthetics.
Scalability.
filesystem designed with cluster in mind (Just the design - the implantation still experimental). Process checkpointing. etc
Back when Dragonfly 6 was released, phoronix found it quite performant in their benchmarks[0].
Kind of wish HAMMER2 development switched to Linux and got a big boost in visibility and exposure. I've been excited about it for ~15 years, but I've never gotten enough round-tuits to put it to any real use. I'd love to switch my rsync+ZFS snapshots backup servers over to HAMMER, but ZFS works great except for deduplication.
>I'd love to switch my rsync+ZFS snapshots backup servers over to HAMMER
Why don't you do that? You don't need linux to be happy, quite be opposite actually, install DFly and have fun.
As I said, I haven't made the time: it's not just installing DFly, I've got to convert all my backup code to work with HAMMER, track down issues, figure out updates, etc... Really the thing I want to try about HAMMER is the deduplication, ZFS deduplication perpetually seems to require more RAM than I have to give it
HAMMER2 is really impressive, and Matthew Dillon's work on it and the rest of DragonFly is spectacular. I guess I feel like DragonFly is limiting the exposure that HAMMER could have. I know long ago there was an early aborted effort to port it, not sure it was ever very serious.
Linux has a history of rejecting any actually good file systems.
This includes but isn't limited to Tux3 and ReiserFS 4 & 5.
What was the story with tux3? It looks like it "read and wrote it's first file" in August 2008, and then had it's last update a few months later in Dec 2008. If if never got out of heavy development phase, being in the kernel wasn't the right place for it.
ReiserFS 4, it's been a very long time since I thought about it, but ISTR there were technical issues the needed to be addressed to bring it in mainline, and personality issues didn't help any, but that's a fading memory. Which is unfortunate, because ReiserFS had some great features.
On the other hand, btrfs made it into the kernel fairly easily, as a counterpoint. It's a unusual situation because it's been fairly broken and in heavy development for much of it's life in kernel, but early in-kernel versions were actually working fairly good (in my experience, I ran some fairly early versions in my laptop for a year or two with good luck, then an OS update brought in a new version and I had terrible corruption issues.