Building mfsBSD

I've been using mfsBSD for several years, but never mastered the art of buiding, so Thought I'd have another go after reading:-


where it says:

3.2. Building an mfsBSD Image​

The process of building an mfsBSD image is pretty straightforward.


And it ends up with:

Next, build the bootable mfsBSD image:
# make BASE=DIST

When I run this I get

Cannot find direcory "DIST/base"


What have I done wrong here?

Bash:
DIST='/workdir/DIST'
echo $DIST
mkdir -p /workdir/DIST
cd  /workdir

pkg install -y git
git clone https://github.com/mmatuska/mfsbsd.git

fetch  -o - ftp://ftp.freebsd.org/pub/FreeBSD/releases/amd64/12.3-RELEASE/kernel.txz | tar xf - -C DIST
fetch  -o - ftp://ftp.freebsd.org/pub/FreeBSD/releases/amd64/12.3-RELEASE/base.txz | tar xf - -C DIST

cd mfsbsd

make BASE=$DIST
 
Cannot find direcory "DIST/base"
What have I done wrong here?
It's right there, just a few lines above that spot
Code:
# mkdir DIST
Maybe the Handbook's new wonky formatting threw you off. I keep hoping it gets better. It keeps not getting better.
 
Forget the article.

Major issue there is: There is no need to create a (DIST) directory and extract the base, kernel distribution sets inside it manually. No such procedure is to find in the mfsBSD documentation. When the build process is invoked, a mfsbsd/work/mfs directory is created, where the needed base and kernel components are extracted automatically.

Steps:

Code:
# mkdir -p /workdir/DIST  
# cd /workdir
# git clone <mfsbsd>
# fetch -o DIST ftp://ftp.freebsd.org/pub/FreeBSD/releases/amd64/12.3-RELEASE/kernel.txz
# fetch -o DIST ftp://ftp.freebsd.org/pub/FreeBSD/releases/amd64/12.3-RELEASE/base.txz
If needed make changes to the configuration for the targeted mfsBSD image, see mfsbsd/BUILD.md.

When there is no need for installed packages on the image, rename mfsbsd/tools/packages.sample, or when third party applications are needed, modify it to include/exclude packages.

Next, specify the directory where the base.txz and kernel.txz live by modifying BASE?= /cdrom/usr/freebsd-dist in the Makefile, or set the environment to the make command:

For a iso image:
Code:
# make iso BASE=/workdir/DIST

For a memstick image (.img) remove the 'iso' target from the command.
 
That seemed to work fine.

I'd just like to go through the targets of the three output images according to


This is my understanding...

Disk image suitable for dd to dedicated device...

ISO should be bootable via PXE

compressed tar file for extraction to a partition so would be bootable via Grub....


???
 
The 'tar' format, not 'compressed tar' as I mistakenly said above, works fine.

Now what I need to do is to hone the creation so mfsBSD boots up exactly as I want with the configuration and apps I want.
 
Back
Top