r/freebsd • • 12h ago

news FreeBSD 15.2: second release candidate

Thumbnail lists.freebsd.org
29 Upvotes

r/freebsd • • 1h ago

We Turned an arm64 Router into a FreeBSD Hypervisor

Thumbnail
alchemilla.io
10 Upvotes

r/freebsd • • 3h ago

news What changed on FreshPorts in November and early December

Thumbnail news.freshports.org
3 Upvotes

u/dlangille writes:

November was a busy month for FreshPorts, and December has started the same way. Between 1 November and 6 December there were 23 releases of the website and about 40 more of the code behind it: the scripts and modules which process commits, the daemons, the periodic jobs, and the packages import. Some of this already has its own post. This one collects all of it in one place, starting with what you can see on the website. …


r/freebsd • • 5h ago

help needed FreeBSD on Acer Aspire 3 A315-24P (Ryzen 5 7520U): Hardware Compatibility Issues

1 Upvotes

Hello everyone!

I'm investigating hardware compatibility issues on my
Acer Aspire 3 A315-24P and would appreciate some help
from the FreeBSD community.

My hardware:
- Laptop: Acer Aspire 3 A315-24P
- CPU: AMD Ryzen 5 7520U (Mendocino)
- GPU: Radeon 610M
- Wi-Fi: MediaTek MT7921
- BIOS: V1.28
- OS: FreeBSD 15.x

Current observations:

- FreeBSD boots and works, but I want to investigate
potential hardware and ACPI-related problems.
- Arch Linux has experienced memory-related errors.
- OpenBSD panics during startup.
- Windows 11 has experienced ntoskrnl.exe errors
following BIOS updates.
- macOS Hackintosh has compatibility issues.

I am NOT claiming that all these problems share
the same cause.

My questions:

  1. Has anyone tested FreeBSD on this exact laptop?
  2. Are there known issues with AMD Mendocino
    platforms and FreeBSD?
  3. Could firmware or ACPI implementation be worth
    investigating?
  4. What diagnostic information would be useful
    to collect?

I'd appreciate any suggestions or similar experiences.

Thanks!


r/freebsd • • 6h ago

do yall think freebsd is suckless

Thumbnail reddit.com
0 Upvotes

r/freebsd • • 7h ago

article Shrinking FreeBSD Containers With pkg-slim – Michael Johnson

Thumbnail
ahze.net
14 Upvotes

… I saw mozgan’s thread on freebsd-pkgbase about pkg-be, a pkg plugin that snapshots a ZFS boot environment before upgrades. It finally got me off my butt to fix something I had been putting off in Daemonless: our FreeBSD container images were huge, and the only cleanup we had was a pile of rm -rf lines scattered across Containerfiles. …

Via https://mastodon.bsd.cafe/@ahze/117706057262493735 and https://lemmy.ml/post/55936083


r/freebsd • • 8h ago

fluff Experimenting with borders

Post image
33 Upvotes

Window borders were always just space burners for me—I never had a need to highlight an active window with anything more than a status bar string. But I wanted to see how the borders would work with Nullspace's decorations. And I actually managed to get everything to work with the automatic tab slider corners. Very likely will merge this in a bit.


r/freebsd • • 8h ago

poll Community poll and discussion: desktop options for NextBSD 27.0

Thumbnail
github.com
2 Upvotes

The poll itself is at https://github.com/orgs/nextbsd/discussions/614#discussion-11211908, I suggest reading the comments before voting.


r/freebsd • • 8h ago

AI Architectural Concept: Using 32-Bit ReactOS & "Fake Hardware" to Generate Clean-Room 64-Bit Drivers and Documentation for 2000–2013 Hardware

0 Upvotes

Hi everyone,

*(Note: This text was drafted and formatted with the help of AI to express my idea clearly in English, while the core architectural concept and hardware research are my own. I am a hardware enthusiast, not a kernel developer, sharing this blueprint openly in case OS developers or reverse-engineering hobbyists want to explore it.)*

Between 2000 and 2013, hardware vendors poured their best engineering into official 32-bit Windows XP (.sys) drivers, while leaving alternative operating systems—like FreeBSD, OpenBSD, NetBSD, Haiku, and AROS—without official technical manuals.

The goal of this concept is not to run legacy 32-bit Windows drivers inside a slow runtime wrapper (like ndiswrapper). Instead, the goal is to use 32-bit ReactOS as a transparent, open-source interrogation lab to extract clean-room hardware documentation—allowing developers to write fast, native 64-bit (x86_64) drivers and open specifications from scratch.

2. Acknowledging Prior Work & Why This Concept Is Different

I am aware that great open-source drivers already exist on Linux—such as brcmsmac, b43, and impressive community projects like Italian developer aleferri’s b43-next and b43-tools (vchip / pmap), which uses virtualized QEMU hardware to force Broadcom's proprietary Linux wl blob to reveal its initialization formulas.

However, my proposal is free of license restrictions and solves three major gaps that Linux drivers and wl-based tools cannot address for BSD or Haiku:

  1. Zero GPL Taint: Linux drivers (b43, brcmsmac, etc.) are licensed under GPLv2, which prevents their code from being ported or merged into MIT or BSD-licensed kernels like Haiku or FreeBSD.
  2. Hardware That Never Had Linux Blobs: Thousands of 2000–2013 components (legacy GPUs, audio codecs, card readers, and obscure Wi-Fi chips) only ever had mature, bug-free drivers on 32-bit Windows XP.
  3. Direct Kernel Interaction (Full OS Context): Blind MMIO dumps only show raw 1s and 0s. By placing an open-source Windows-compatible kernel (ReactOS) in the middle, the kernel interacts directly with the .sys driver—revealing exact OS intent in real time (e.g., "the OS just requested a radio scan," "the OS is entering ACPI S3 sleep," or "the driver is allocating a 32-bit DMA ring").
  4. Summary of Lab Implementation & Hardware Targets
  • Minimal Subsystem & Virtualization: Retaining a minimal win32k/GDI subsystem prevents driver initialization failures, while software-mocked PCI/MMIO devices simulate hardware sequences without requiring physical components.
  • Key 2000–2013 Hardware Components:

    • Wi-Fi Chipsets: Broadcom BCM4313, BCM4312, Marvell Libertas, Ralink RT2860/RT3090, and Atheros AR5007/AR9285 variants.
    • Legacy GPUs: NVIDIA GeForce 6/7/8/9/200 and ATI/AMD Radeon X1000/HD 2000–5000 series for modesetting and VRAM setup.
    • Peripherals: Ricoh R5C822, JMicron JMB38X card readers, and Conexant/Realtek audio codecs.

r/freebsd • • 19h ago Obsessed

AI FreeBSD 15, from fresh install to a bspwm desktop with one script (built with AI assistance

4 Upvotes

I've been working on **freebsd-bspwm-aurtty**, a post-install script that turns a fresh FreeBSD 14/15 (amd64) into a full bspwm desktop. The video goes from a clean console to the finished desktop in real time, with only the waits sped up. The full install took about 4.5 min in a QEMU/KVM VM.

How it works

pkg install -y git
git clone https://github.com/RobertoBarbosa-AurTTY/freebsd-bspwm-aurtty.git
cd freebsd-bspwm-aurtty
sh install.sh

A `bsddialog` TUI asks for the user, keyboard, video driver (it detects VM, BIOS or UEFI), login method and optional extras. It then shows a summary, and nothing changes on the system until you confirm it.

What you get

* bspwm + polybar + picom + rofi + LightDM, with gh0stzk's Emilia theme ported to FreeBSD (Tokyo Night)
* A bar with MPD controls, a pending-updates counter (`pkg version`), and a power menu with a shutdown timer
* Clicking RAM or Disk on the bar opens GNOME System Monitor or Disk Usage Analyzer (right click opens btop or ncdu)
* Plank dock, particle effects when windows open and close, Firefox, Thunar and AstroNvim
* `atualizar` creates a ZFS boot environment before every upgrade, and `atualizar --voltar` rolls it back
* `devdb` runs PostgreSQL, MariaDB, Valkey or MongoDB, each in its own jail (no Docker)
* Everything that doesn't come from pkg is pinned to a version and checked against a SHA-256 hash

**FreeBSD-specific fixes I had to make:** MPD is `musicpd`, and the client is `musicpc` because the `mpc` package is a math library. polybar's IPC socket needed a FIFO fallback. libadwaita apps needed a dark-mode env var. BSD awk vs gawk, `daemon -f` instead of `setsid`, and a few more.

Notes

* The installer screens are in Portuguese (pt-BR) for now. The README is in English.
* This is a study and dev workstation, not a hardened setup: no firewall is configured (use `pf`).

Repo: https://github.com/RobertoBarbosa-AurTTY/freebsd-bspwm-aurtty

Feedback, issues and PRs are welcome, especially from people running it on real hardware (drm-kmod / NVIDIA).

---

*AI disclosure: parts of the script were written with help from Claude (Anthropic). The video editing, captions and background music were also made with it. The music is an original synthesized track, with no samples.*

---


r/freebsd • • 22h ago

fluff My FreeBSD system, built from the base kernel, uses few machine resources.

Thumbnail
gallery
69 Upvotes

r/freebsd • • 1d ago Heartwarming

discussion BSD Merch

Thumbnail
gallery
94 Upvotes

With the closing of the FreeBSD Mall, I decided to reach out to Marshall Kirk McKusick about licensing the BSD Daemon, and I got some excellent news back!

I'm looking at offering many of the same kinds of products that were available through the FreeBSD Mall, and I'd really like to get some feedback from the community before getting too far into production.

I'm already sourcing general apparel, but I'm curious what else people would actually be interested in seeing. Coffee mugs, mouse pads, desk mats, stickers, patches, posters, physical copies of the handbook or other documentation?

I've always been particularly fond of the 4.2BSD Daemon rendition. Personally, I think it's a much nicer illustration, but I'm curious how many people would actually prefer it over the more familiar Beastie artwork.

I'm not interested in producing a bunch of merchandise that nobody wants, so I'd love to hear what you'd like to see, what you'd actually buy, or even what you wish the old FreeBSD Mall had offered!

Edit: Please cross post so I can get as much feedback as possible!


r/freebsd • • 1d ago Heartwarming

help needed Your hardware could be the next FreeBSD commit

59 Upvotes

As a FreeBSD committer, I would like to ask for your help in improving our hardware support, especially the small things that are missing.

I'm not asking anybody to write an subsystem or port a filesystem.

I am interested in the little things:

  • Keyboards with non-functional special keys.
  • RGB lighting that cannot be controlled.
  • Mice with unsupported buttons or features.
  • Laptop keyboard backlights.
  • Missing PCI or USB device IDs.
  • Cameras that are glitchy with the new drivers uvideo(4) for example. (you need 16-Current)
  • USB Printers, Scanners....

I have a network of friendly repair stores with thousands of model and computers fro 2006-2026

But there is not reason i will submit everything at once.

What i want is that you spend few minutes of your time identifying these problem and report them either in bugzilla, github, or send me an email (seuros@) .

My role will be to help you have this landed in -CURRENT, then i will backport it to 15.x.
If you send a patch, it will have your name.

Every FreeBSD derivative benefit from it (Ghost, Hypr, Next, Hardened...) .

If your computer already boot FreeBSD, the subject above are often just quirks or missing attachement.

What out of scope are hardware that need full plumbing around them , like PCI-cameras (still working on it it), new Wifi/GPU cards.

If you have some open issues already, you can ping me there.

It nearly end of year, so my friends will do a inventory and they can send me the exact hardware for few days so i can test if i don't have already.

it a win-win situation for everybody.


r/freebsd • • 1d ago

discussion How to use AI to discuss when you are not english native.

0 Upvotes

I see many people starting comments or posts by an apology for using AI to write in r/freebsd.

Few are ashamed to share their FreeBSD setup because they can't write english.

Instead of doing that here is my trick to stay yourself.

Translate the following text into proper english, i'm not english native. I speak XXXX (list the languages you can speak , not the one you writing)  
Chain the ideas.  
Keep it simplified english.  
no em-dashes.  
Don't give examples or explanations, i didn't write down.  
Don't correct what i said.  
Fell free to explain/correct in a second block, but keep my personality intact  

This simple prompt will make you respond more naturally, you will not flood the reader with 1000 words that the AI companies advice the model to output, your ideas will be yours, you learn with time to not depend on AI.

Reread the output, if the output sound like you, submit. if has thing you didnt say, delete it (even if you feel it better))

I speak multiple languages IRL, and i notice that when i think in 1 language or a mix , writing the same idea in english make little sense.
With time, i trained myself to write correctly.

By using LLM to correct your grammar, you learn.
If you let LLM write the argument for you, nobody learn anything. because even the readers will dismiss it.

Have a nice weekend.

PS: No AI was used in this text.

EDIT:

IT related to this subreddit, because everybody that speak in their native language, get downvoted. Speak with AI and apology, get downvoted. Now even Google translate started to add em-dashes and rewording with AI lingo.

r/opensource was banning anyone that can't write english.

And i get DM from FreeBSD people asking question and apologising like they are doing a big sin.

They don't post here anymore, because once they did, they got downvoted for letting the AI translate their excitement.

Southern languages are very emotional, so when you give that to AI. The output become more emotional and unreadble.


r/freebsd • • 1d ago

AI OpenZFS 2.3 Features You Should Actually Turn On – Klara Systems

Thumbnail
klarasystems.com
49 Upvotes

… OpenZFS 2.3 is one of the most feature-dense releases the project has shipped in years, and we've spent the last month covering the headliners in depth. This piece is the practical companion: what you should focus on enabling, in what order, with the commands to do it. The kind of article you keep open in a terminal split. …


r/freebsd • • 1d ago

AI Why hasn't a truly simple, macOS-like desktop experience caught on with FreeBSD?

34 Upvotes

(Used LLM to translate my text)

I'm just an ordinary computer user. I mainly use Windows, though I've also spent time with Linux and macOS (via Hackintosh).

Even as a non-technical user, I find FreeBSD's overall philosophy really appealing. Having the entire base system developed and maintained by a single project makes it feel much more organized and consistent than Linux, which can sometimes feel like a patchwork of different components glued together.

That got me wondering, why hasn't FreeBSD managed to become a truly accessible desktop OS?

I've actually tried desktop-focused derivatives like GhostBSD and helloSystem, so I know people have tried to bridge this gap. However, in practice, they just didn't quite click on my laptop. Aside from running into driver and hardware headaches, the day-to-day workflow still feels far from macOS's simplicity. where installing or removing apps is often just drag-and-drop, or handled smoothly through an app store without having to fall back to the terminal.

Of course, server administrators and power users should always keep full manual control over their systems.

I'm just genuinely curious, from the community's perspective, is a polished, "it just works" FreeBSD desktop held back mostly by limited manpower and vendor driver support, or is there just not enough interest in targeting ordinary desktop users?


r/freebsd • • 1d ago

help needed Why do i cant install KDE anymore?

9 Upvotes

Today I reinstalled FreeBSD because I wanted to continue using the system and I really liked it, but when I tried to install KDE it showed that there were no packages available to install, did I miss something? Or is this a FreeBSD server error?


r/freebsd • • 2d ago Obsessed Bravo

AI A proposal for an experimental approach to human–AI collaboration in FreeBSD development.

0 Upvotes

Hi everyone,

Following a lengthy and interesting discussion about the use of Large Language Models in FreeBSD development in the forums.freebsd.com :

https://forums.freebsd.org/threads/how-to-instruct-claude-so-that-it-can-be-better-focused-when-it-works-to-my-implementations.104524/

I would like to know your opinion about my idea to propose a small experiment that might help us explore the potential of the LLMs without ignoring their limitations or compromising the development standards of FreeBSD.

1. The problem from an outsider's perspective

I am a hobbyist, not a professional programmer. I use FreeBSD and would like to contribute to its development while respecting its architectural principles, conventions, and development philosophy.

However, there is a considerable difference between producing something that works on FreeBSD and producing something that experienced developers would consider suitable for integration into FreeBSD.

My difficulty is not simply a lack of programming skills. It is also a lack of insider knowledge: the architectural history, unwritten conventions, relationships between subsystems, and reasoning behind certain development decisions.

Giving an LLM access to the entire FreeBSD source tree and documentation certainly helps, but access to knowledge does not necessarily imply the ability to identify, contextualize, and correctly apply it.

Furthermore, if I already possessed the expertise required to identify all the relevant knowledge and its architectural implications, I would already possess much of the expertise that I am trying to acquire.

2. The cognitive accessibility of technical knowledge

I would genuinely love to be able to assimilate all the information contained in the man pages and other technical documentation.

Unfortunately, wanting to learn something does not always mean being able to learn it effectively through a particular medium.

Our ability to assimilate information also depends on how that information is organized, explained, and presented. We do not have complete control over how our minds process knowledge.

The fact that knowledge is publicly available does not necessarily mean that it is cognitively accessible to everyone.

I believe LLMs could help bridge this gap by acting as intermediaries between formal technical knowledge and the different ways in which human beings understand and assimilate information.

3. How I use LLMs

My preferred approach is to ask an LLM to explain specific blocks of code, their purpose, their relationships, and the problems they are intended to solve.

Once I have acquired an understanding of the problem, I can formulate my own ideas, make decisions, and ask the LLM to assist me in implementing those decisions.

The objective is not to delegate my intellectual responsibility to the model, but to acquire the knowledge necessary to exercise that responsibility.

I fully recognize that a human contributor must understand, explain, and independently defend the code they submit. Using an LLM should not exempt anyone from this requirement.

However, I believe there is a distinction between the knowledge a contributor must possess and the tools through which that knowledge can be acquired.

4. Finding the appropriate level of abstraction

Rather than attempting to teach an LLM to think like a senior FreeBSD developer, I would like to explore whether experienced developers could construct an appropriate level of abstraction of the knowledge upon which their technical decisions are based.

Such an abstraction could include:

  • Relevant architectural principles and invariants.
  • Relationships and dependencies between subsystems.
  • Historical design decisions and their motivations.
  • Development conventions and constraints.
  • Previously rejected approaches and the reasons for their rejection.
  • Criteria for evaluating alternative implementations.
  • Requirements for testing, documentation, and maintainability.

The purpose would not be to reproduce human intelligence artificially, but to make existing human expertise more accessible, transferable, and reusable.

The abstraction should ideally remain independent of any particular LLM or commercial provider and be useful even to human developers who do not use AI.

5. Recognizing the limitations of LLMs

Several legitimate objections have emerged during the discussion.

LLMs are not reliably deterministic. They can disregard instructions, misunderstand architectural relationships, produce unnecessarily complex code, generate convincing but incorrect explanations, and overlook relevant information even when it is present in their context.

Tests, moreover, cannot establish that every architectural decision is correct, nor can they account for every unknown edge case or misunderstood design intention.

I do not dispute these limitations.

My proposal is not based on eliminating them, but on investigating whether an appropriately structured development methodology can mitigate some of their consequences.

There is a fundamental difference between expecting an LLM to be infallible and attempting to construct a reliable development process around a fallible tool.

The resulting code must remain understandable, reviewable, and maintainable without requiring access to the original LLM, its instructions, or its conversation history.

Human judgment and the traditional FreeBSD review process must remain essential.

6. The cost of involving experienced developers

Another legitimate objection concerns the time and effort required from FreeBSD developers.

Constructing and validating an abstraction of their knowledge would require an initial investment, while its benefits could only be demonstrated experimentally.

I fully acknowledge this problem.

However, rather than reducing the involvement of experienced developers to the point where their expertise can no longer serve its intended purpose, I would suggest reducing the scope of the experiment itself.

A small project, a small investment.

7. The proposed experiment

I would like to find one or more experienced FreeBSD developers voluntarily interested in the following experiment:

  1. Select a small, well-defined FreeBSD project with limited architectural complexity.
  2. Have the developers construct the appropriate level of abstraction for that specific project, identifying the relevant knowledge, architectural relationships, constraints, conventions, and decision-making criteria.
  3. Have a hobbyist, assisted by an LLM, attempt to implement the project using that structured knowledge.
  4. Evaluate the resulting implementation through conventional human review.
  5. Assess whether the hobbyist has actually acquired the understanding necessary to independently explain and defend the implementation.
  6. Where practical, compare the results with an LLM-assisted implementation produced without the additional abstraction.
  7. Evaluate the time invested by the developers, the quality of the results, and the potential reusability of the knowledge across similar projects.

The experiment should have a predefined, limited time budget and should create no obligation for the developers to continue supporting it or maintaining its results.

The primary objective would not necessarily be the implementation itself. The small project would serve as a testing ground for the knowledge abstraction and the methodology through which it is applied.

8. What would constitute success?

The experiment should investigate whether:

  • The resulting code is more consistent with FreeBSD's architectural principles.
  • The implementation is simpler, more understandable, and more maintainable.
  • Architectural misunderstandings are identified earlier.
  • The hobbyist acquires genuine technical understanding rather than merely an ability to generate code.
  • The knowledge provided by developers can be reused without repeatedly requiring their intervention.
  • The potential benefits justify the initial investment and any subsequent costs.

If the experiment fails, we should acknowledge that result. If it succeeds, we would have some preliminary evidence upon which to build further investigations.

Neither outcome should be assumed in advance.

9. The broader purpose

I am not trying to replace FreeBSD developers with artificial intelligence.

If I believed that an LLM could adequately replace an experienced FreeBSD developer, I would not be asking for their guidance in the first place.

Nor am I asking the FreeBSD community to lower its standards or accept contributions from people who cannot take responsibility for their work.

I am trying to investigate whether the expertise accumulated through years of human experience can be made more accessible, allowing people approaching FreeBSD from outside its developer community to acquire knowledge and contribute more effectively.

I do not want to eliminate the effort required to learn. I want to explore whether that effort can become more productive.

We do not need to agree on the nature of artificial intelligence, its commercial implications, or its role in the future of humanity before investigating one of its possible applications.

We only need a small, well-defined experiment, a limited voluntary investment, and a willingness to evaluate the results objectively.

Would any experienced FreeBSD developers be interested in exploring this possibility?

Thank you for reading.

For transparency, this text was developed through an extended dialogue with an LLM, BUT incorporating MY OWN ideas, decisions, corrections, and the objections raised by other community members.


r/freebsd • • 2d ago All Seeing Upvote

discussion From complaining about the FreeBSD desktop to using it for everything

Thumbnail
reddit.com
9 Upvotes

r/freebsd • • 2d ago Heartwarming

discussion Does Caterpillar's CEO commute to work in a bulldozer ?

43 Upvotes

People keep commenting the fact that some member of FreeBSD community don't use FreeBSD as their daily desktop OS, as if that invalidates their contribution or void the ideology.

  • Do you expect Caterpillar’s CEO and staff to commute to work in a bulldozer ?
  • Do you expect a Boeing enginer to fly to the supermarket ?
  • Do you expect a NASA engineer to spend their holidays in the ISS ?
  • Do you expect a submarine engineer to live under water ?
  • Do you expect a developer working on medical imaging software to own an MRI machine ?
  • Do you expect a Ferrari engineer to transport furniture in a Ferrari ?

FreeBSD is a server and appliance first OS.

A Server works 24/7 and must be used at 100%. This is why you might have a driver for a 400GB/s ethernet card, but your wifi card is barely hitting 2MB/s.
This is why we are working on suspend/resume only in 2026. A server in datacenter never needed suspend, it has it module that can control it via a KVM.

BSD is an idea.

The BSDs don't need porting with AI without commitement.

Anthropic and OpenAI offers free subscriptions to the devs.
We could have hooked those tokens into a loop and ported everything in 2 months.

Then nothing will work because nobody own anything. Everything will work in theory in Qemu or virtual box. But then the hardware will tell you "Not gonna talk to you with this attitude"

The BSDs need testing, understanding and funding. You dont have to fund with money, you can do it by spending time testing diffs , helping others in bugzilla and discussing in the forum or here.

And the BSDs is not only FreeBSD, there are OpenBSD, NetBSD, NextBSD, HyprBSD, GhostBSD, DragonFly BSD, etc...

Don't try use the same OS everywhere, because that not engineering, but tribalism. and i always say here : We are not a cult.


r/freebsd • • 2d ago

answered Where to get 16.0-CURRENT ISO images?

9 Upvotes

Hi, I was wondering where I can get the 16.0-CURRENT Installation ISO images. I checked out the download directory but it's empty : https://download.freebsd.org/snapshots/amd64/amd64/ISO-IMAGES/16.0

Are you supposed to compile it yourself?


r/freebsd • • 3d ago

AI Now FreeBSD boots from an EFI partition plus a single HAMMER2 volume, with snapshots and boot environments, without a single line of ZFS code.

1 Upvotes

Hello boys.

this is my latest project,that reached the working phase just right now,after weeks of tests :

https://github.com/Marietto2008/freebsd-src/tree/hammer2-root

HAMMER2 as the root filesystem of FreeBSD 16-CURRENT

3 December 2026

FreeBSD 16-CURRENT now boots from an EFI partition plus a single HAMMER2 volume, with snapshots and boot environments, without a single line of ZFS code.

The work ran from 21/11 to 03/12/2026: six gated phases, all passed, followed by a soak test and interoperability testing with DragonFly.

Why we did it

HyperBSD needs a root filesystem with snapshots and boot environments, but without any code derived from OpenSolaris (CDDL licence): the system must build and boot with ZFS disabled.

The gap in FreeBSD. The available root filesystems are UFS and ZFS. ZFS is ruled out by the licence requirement. UFS has snapshots designed for dump and background fsck, not for going back to an earlier version of the system; it has no data checksums and no compression.

Why HAMMER2. It is DragonFly BSD's file system: BSD licence, copy-on-write, instant snapshots, multiple PFSes (sub-volumes) on one volume, LZ4/zlib compression, a checksum on every block.

The starting point. A FreeBSD port already existed (kusumi/freebsd_hammer2 v1.2.13), but as a module for FreeBSD 14, not bootable as root and never tested under heavy load.

The goal of the brief (21/11). HAMMER2 as a "first-class" filesystem in the FreeBSD tree: kernel, mountroot, GEOM, loader, userland and boot environments,not a module bolted on top. Shortcuts were explicitly forbidden (mount options passed as a string, /boot on another filesystem, cron instead of periodic).

How we did it

Six phases in sequence, each closed by a gate: a list of tests with the expected outcome written down before running them, a report, and the project owner's decision. Without passing the gate, work did not move on to the next phase.

Working rules

Vendor model. Kusumi's port is imported untouched on its own branch; every integration step and every fix is a separate commit, recording what found the defect.

In total 65 commits on top of FreeBSD main 5ddfe1e, 132 files touched (most of the lines are the vendor imports).

Frozen on-disk format. No change to the format: a volume must remain readable and writable by DragonFly.

No CDDL. Not even libsa's lz4.c, which comes from OpenSolaris: the loader uses its own decompressor.

Isolated test bench. Everything in bhyve VMs (bhyveload or UEFI) on disk images; never the host's own disk. Test kernels always run with INVARIANTS and WITNESS enabled.

The phases

  1. P0, baseline (21–29/11). The port built into the FreeBSD 16 kernel and put through the hardest tests before touching the root. Most of the defects surfaced here (see below).

2. P1, the root (29–30/11). Mounting the root with volume@PFS syntax, mountroot waiting for every device of the volume, mount_hammer2 and its manual page.

3. P2, GEOM (30/11). A /dev/hammer2id/\<fsid\> label to find the volume without depending on the disk name.

4. P3, userland (30/11). fsck_hammer2 following the fsck(8) contract at boot, hammer2 in /rescue, periodic clean-up in periodic(8).

5. P4, the loader (30/11–01/12). A HAMMER2 reader written from scratch in libsa (loader.efi and userboot), which verifies checksums and refuses a corrupted kernel.

6. P5, boot environments (01/12). The hammer2be tool: each BE is a PFS snapshot; selectable from the loader menu, with "boot once" into a new BE.

7. P6, images (01/12). makefs -t hammer2 and mkimg: a bootable UEFI disk built without mounting anything, as for UFS and ZFS.

After the phases, the final validation (02–03/12): a soak test of three buildworlds on the HAMMER2 root, interoperability with DragonFly, a package build.

How we verified it

Every mandatory test passed on the final kernel or on the kernel of its phase; none was relaxed to make it pass.

Test | What it shows | Result

pjdfstest | POSIX semantics (permissions, rename, link, timestamps) | 230/230, repeated on every new kernel

fsx, 24 hours | Data consistency under random reads, writes, truncates, mmap | 403 million operations, 0 errors

stress2, 24 hours | FreeBSD's concurrent filesystem scenarios | rc 0, no panic

Crash loop, 500 rounds | After a hard reset no data confirmed by fsync is lost | 500/500, 720,848 markers verified, 0 lost

Crash loop on the root | The same, with HAMMER2 as the root | 500/500, 1,023,618 markers, 600 root mounts

100 reboots | The root always mounts, without waiting | 100/100, ssh ready in 22.9 s on average

KASAN and KMSAN | Out-of-bounds accesses and uninitialised memory in the kernel | 1 error found and fixed, then clean

WITNESS | Lock ordering (deadlock risk) | 0 reversals after the fixes

Loader reader | The loader reads exactly what the kernel reads | 61,420 entries in 20 compression/checksum combinations, identical

Loader fuzzing | Corrupted images neither hang nor fool the loader | over 12 million executions; 2 defects found and fixed, then 0

Crash while switching BE | The BE choice stays consistent | 20/20 after the fix

makefs -t hammer2 | An image built outside the kernel is correct | 12,079 entries, identical manifest as read by the kernel

Soak | Three buildworld+buildkernel -j8 on the root, bulkfree every 15 minutes | rc 0, 27 clean bulkfree runs, 0 LORs, clean fsck

DragonFly 6.4.2 interop | Volumes written by one system, read and written by the other, both ways | clean fsck on both, identical manifests (up to 125,119 entries)

The expected outcome of each test was written before running it, so a result different from the expectation is visible and cannot be rewritten afterwards.

Defects found and fixed

The tests found more than twenty defects in the starting code; seven of them could lose or corrupt data without any message. All are fixed in separate commits and covered by the test that found them. At least five also apply to DragonFly master (checked by reading the code); the report for its developers is ready but not yet sent.

fsync not durable | Data confirmed by fsync lost after a crash | Crash loop

Freemap: one block written several times per flush | Volume corrupted after a crash | Crash loop, round 422

bulkfree reused blocks still referenced | Volume corrupted after a crash | Crash loop, round 2047

Dirty buffers written after the volume header | Volume corrupted after a crash | Crash loop, rounds 3012 and 4047

Checksum "none" combined with dedup | Silent reads of stale or zeroed data | Comparing the loader reader with the kernel

SEEK_DATA ignored data still in memory | cp of a freshly written sparse file produced a copy full of zeros, with no error | Userland tests (P3)

truncate did not zero the tail of the block | After a truncate and an extension, old data reappeared | fsx

bufdaemon stalls and lost wake-ups | System hung under write load | WITNESS, stall reproducer

Lock not released, wrong assertion in rename | Panics (the second during the soak, in buildworld) | fsx and stress2; soak

Inconsistent lock ordering | Deadlock risk | WITNESS

bulkfree on an idle volume | Space was never freed | Userland tests (P3)

Read past the string on every mount | Out-of-bounds access in the kernel | KASAN

LZ4 decoder and two other undefined behaviours | Invalid accesses on particular data | Fuzzing, UBSan

BE choice saved with a rename on FAT | After a crash the choice vanished and the system booted single-user | Crash while switching BE

The last row was a defect in our own initial design, not in the vendor code: the file is now rewritten in place.

Strengths

The result is a complete root filesystem, entirely BSD-licensed, with robustness that has been measured rather than claimed.

Licence. All BSD: FreeBSD builds and boots from HAMMER2 with ZFS disabled, as HyperBSD requires.

Real integration. Root, GEOM label, loader, fsck at boot, /rescue, periodic, boot environments, makefs: HAMMER2 behaves like UFS and ZFS at every point of the system's life cycle, without any of the forbidden shortcuts.

Proven robustness. Over a thousand hard resets without losing a single confirmed write, 24 hours of fsx and 24 of stress2, three soak buildworlds, KASAN, KMSAN, WITNESS and fuzzing.

Cheap boot environments. A BE is a PFS snapshot: instant, taking space only for the blocks that change afterwards.

A loader that defends itself. The loader reader verifies checksums: a kernel with a single flipped bit does not boot.

Data not locked in. The on-disk format is DragonFly's, verified in both directions: a FreeBSD volume can be read and written by DragonFly and vice versa.

Traceability. Every change is a separate commit with the test that motivated it; every phase has a report with the expectations written beforehand.

Weaknesses and limits

The biggest limit is age: this is thirteen-day-old code, tested only in virtual machines and never used in production.

Never on real hardware. Everything ran in bhyve. The run on the dedicated disk is prepared but not done (it is destructive and needs consent).

amd64 only, UEFI only. arm64 was excluded by choice; there is no BIOS boot.

One disk, no self-healing. Checksums detect a corrupted block but cannot repair it from a copy; mirroring and RAID are possible only with GEOM underneath the filesystem (not tested).

Space is freed later. Deleting a file does not return the space at once: it needs bulkfree, which periodically runs daily and which may need two passes.

No performance figures. There is no speed or memory comparison with UFS and ZFS yet.

A fork to maintain. The fixes have not yet been proposed upstream (FreeBSD, kusumi, DragonFly). As long as they stay here, every update of the port or of FreeBSD main has to be merged by hand.

Few eyes. HAMMER2 has a small community: few users, few reviewers, little experience gathered on FreeBSD.

Pros and cons compared with UFS and ZFS

HAMMER2 offers almost everything ZFS boot environments provide, under a BSD licence, but without self-healing, send/receive and years of production use.

Feature | UFS | ZFS | HAMMER2 (this project)

Licence | BSD | CDDL | BSD

Boots with ZFS disabled | Yes | No | Yes

Boot environments | No | Yes (bectl) | Yes (hammer2be, new)

Snapshots | For dump and background fsck | Yes | Yes, also per PFS

Data checksums | No (metadata only) | Yes, with repair from copies | Yes, detects but does not repair

Compression | No | Yes | Yes (LZ4, zlib)

Redundancy | With GEOM underneath | Built in (mirror, RAIDZ) | With GEOM underneath (not tested)

Sending snapshots to other machines | No | Yes (send/receive) | No

Space after a deletion | Freed at once | Freed at once | After bulkfree

Years of use on FreeBSD | Decades | Over fifteen | Thirteen days (years on DragonFly)

Volumes usable by DragonFly | No | No | Yes, read and write

In short: compared with UFS you gain snapshots, boot environments, checksums and compression; compared with ZFS you gain the licence and lose self-healing, replication and maturity.

What remains to be done

Bare-metal runs on the dedicated disk

Propose the fixes upstream: kusumi/freebsd_hammer2, DragonFly, FreeBSD (needs approval).

Performances (HAMMER2 vs UFS vs ZFS) :

https://github.com/Marietto2008/freebsd-src/blob/hammer2-root/hammer2-project/rapporti/PERFORMANCE-report-20261203-en.md

Thanks to everyone that will help me to improve the code....


r/freebsd • • 3d ago

help needed Can't use VMware shared folders after installing XFCE

6 Upvotes

I am new to FreeBSD and have to learn about it for a competition.

Anyways, I just installed xfce on my FreeBSD VM on VMware. Now, however, shared folders are not working. I need to transfer files onto the VM for my competition. It was working before, on the same VM, before I installed xfce. Now I can no longer see the files that were being shared, and when I try to rerun my script for shared folders, I am getting an error.

Any advice would be greatly appreciated.


r/freebsd • • 3d ago Thanks Popcorn

AI Could AI help FreeBSD close the gap with Linux faster?

5 Upvotes

I used Linux for about 20 years before switching to FreeBSD around 2019, and I’ve been using FreeBSD ever since.

As a desktop user, the biggest difference I’ve noticed is hardware support. After that, it’s the little things. For example, plugging a USB stick into my FreeBSD machine running Xfce doesn’t behave quite the way it did on Linux. I suspect some of those differences could be sorted out with a setting or a small script.

I’ve thought about switching back to Linux once or twice, but ZFS keeps talking me out of it. It’s hard to give up a storage setup you already trust. :)

What makes me optimistic is that AI can help people tackle fixes they might not have attempted before. My hardware works well on FreeBSD, so I haven’t had to touch any drivers. But if you have a device that mostly works except for one thing, AI might help you read unfamiliar driver code, narrow down the cause, and draft a patch. Someone still has to test it on real hardware and maintain it afterward, of course.

If more of those fixes get tested and make it upstream, what might the FreeBSD desktop look like in five or ten years?

Honestly, I don’t have many complaints about FreeBSD. If I’m nitpicking, why underscores instead of hyphens in /etc/rc.conf settings like zfs_enable and local_unbound_enable? And since I tend to leave my machine running 24/7, I’d love to reboot less often for kernel updates.

I came across the FreeBSD kpatch proposal, which aims to patch individual functions in a running kernel. It got me thinking about a related but different idea: I’d like to use AI to help prototype live replacement of some FreeBSD kernel modules.

The idea is to separate the lifetime of the state from the lifetime of the code. The part of the kernel that stays in place would own things like device settings and runtime state, while the replaceable module would contain the code that works with that state. During a swap, the kernel would stop sending new work to the old module and wait for in-flight work and callbacks to finish before unloading it. If the new module is compatible with the existing state, it could pick up where the old one left off without having to save that state to disk and reload it. I’m not suggesting this should work for every driver. I’d start with modules where that separation makes sense and see whether they can be replaced without a reboot.

Well, this turned into a bit of a ramble.