Jails

Getting Home Assistant running in a FreeBSD 13.1 jail

Home Assistant is not friendly for plain installs. It seems designed for containers or running everything out of pip install. That, in itself, is a disturbing trend I’ve seen on several projects (what? you’re not running a git cloned image?). I’ve seen reports of people running containers etc. However, I want to run this on FreeBSD. I don’t want to muck about with installing containers etc. If containers are the only way for […]

Getting Home Assistant running in a FreeBSD 13.1 jail Read More »

Monitoring FreeBSD jails from the host

It was May 2021 when I tweeted about monitoring FreeBSD jails which had jail IP addresses only in the 127.0.0.0/8 range. Yesterday, nearly 6 months later, I did the first test of this. This came up because I’m getting a new FreshPorts node ready. I’ve created a file in the jail to be run from the host. That script runs in the jail but it initiated by a process on the host. In

Monitoring FreeBSD jails from the host Read More »

Upgrading a FreeBSD 12.2 jail to FreeBSD 13 using mkjail

Mark Felder and I have been working on a minimalist set of jail scripts for creating and updating jails. All jail management is accomplished via standard vanilla FreeBSD jails. No jail managers are involved. Everything goes through jail.conf. In this post: FreeBSD 13.0 host, recently update from FreeBSD 12.2 FreeBSD 12.s jail on that host, about to be updated to FreeBSD 13 These jails were NOT created with mkjail Jails are mounted at

Upgrading a FreeBSD 12.2 jail to FreeBSD 13 using mkjail Read More »

snapshot ; ls ; destroy; dataset is busy – WTF?

I have found this bizarre situation where a FreeBSD 12.2 snapshot cannot be destroyed. This is the simple example, which works: [dan@pkg01:~] $ sudo zfs snapshot tank_fast/poudriere@snapshot-for-backup [dan@pkg01:~] $ sudo zfs destroy tank_fast/poudriere@snapshot-for-backup [dan@pkg01:~] $ This is the simple example, which fails: [dan@pkg01:~] $ sudo zfs snapshot tank_fast/poudriere@snapshot-for-backup [dan@pkg01:~] $ ls /usr/local/poudriere/.zfs/snapshot/snapshot-for-backup cache data jails ports [dan@pkg01:~] $ sudo zfs destroy tank_fast/poudriere@snapshot-for-backup cannot destroy snapshot tank_fast/poudriere@snapshot-for-backup: dataset is busy [dan@pkg01:~] $ EDIT: we

snapshot ; ls ; destroy; dataset is busy – WTF? Read More »

Converting an iocage vnet jail to a vnet jail

In this post I will be creating a ‘new’ jail which uses vnet. I say ‘new’ because I am actually Converting an iocage jail to a vanilla jail which happens to use vnet. NOTE: I originally failed to get this to work. You can read about it. I’m going to repost this article soon with a working solution. I won’t describe the process of creating the jail. Sorry. For the record: FreeBSD 12.2

Converting an iocage vnet jail to a vnet jail Read More »

Converting an iocage jail to a vanilla jail

Tonight I got blocked by iocage and handling a ZFS filesystem from within an iocage jail. These are the steps I followed to convert that jail from iocage to a vanilla jail. The variable To make this solution easier to use, at least for me, on future jail migrations, I have these variables: For example, my devgit-nginx01 jail is at: [dan@knew:~] $ zfs list system/iocage/jails/mysql56 NAME USED AVAIL REFER MOUNTPOINT system/iocage/jails/mysql56 11.5G 20.6T

Converting an iocage jail to a vanilla jail Read More »

hostmask on an ip address can affect jail DNS

I encountered, and later solved, a DNS issue on a FreeBSD jail. The jail is my web proxy, of sorts. I have one public IP address, which is dynamic (not relevant, but mentioned only in passing) so all incoming web traffic goes to a single internal RFC-1918 IP address. From there, nginx does reverse proxies out to the various hosts: devgit.freshports.org dev.freshports.org test.freshports.org stage.freshports.org There are more, but you get the idea. Each

hostmask on an ip address can affect jail DNS Read More »

Creating a new iocage jail

Every time I go to create a new iocage jail, I cannot remember out the command. Here we go, for next time: iocage create -n devgit-ingress01 –thickjail host_hostname=devgit-ingress01.int.unixathome.org ip4_addr=10.0.0.141 –release 12.1-RELEASE iocage create -n devgit-nginx01 –thickjail host_hostname=devgit-nginx01.int.unixathome.org ip4_addr=10.0.0.147 –release 12.1-RELEASE

Creating a new iocage jail Read More »

using zfs rollback for cache clearing

I’m in the final stages of the FreshPorts packages project. One of the last tasks is clearing the packages cache from disk when new package information is loaded into the database. See also: Clearing the packages cache ZFS when you’re not doing ZFS Several of the configuration items have been learned from putting my poudriere instance into a jail. In this post: FreeBSD 12.1 py37-iocage-1.2_5 If I was to do this cache clearing

using zfs rollback for cache clearing Read More »

Creating a ZFS dataset for testing iocage within a jail

Be warned, this failed. I’m stalled and I have not completed this. I’m going to do jails within a jail. I already do that with poudriere in a jail but here I want to test an older version of iocage before upgrading my current jail hosts to a newer version. In this post: FreeBSD 12.1 py36-iocage-1.2_3 py36-iocage-1.2_4 This post includes my errors and mistakes. Perhaps you should proceed carefully and read it all

Creating a ZFS dataset for testing iocage within a jail Read More »

Scroll to Top