[systemd-devel] /var/lib/machines

Johannes Köhler koehler.johannes at googlemail.com
Sat Jun 26 11:05:48 UTC 2021


Hi systemd maintainer, again!

with my last post i got a hint to
follow the netiquette. My netiquette
with now, was: read manpages and html
searches before asking stupid questions... :)

So to say, i am happy about private messages for adding
concrete rules to that basic...

During my tour through systemd there spawned
some new questions:

_systemd-nspawn_

I think i realized: nspawn is using a machine and an
image to create a virtual machine container, to run
as process or thread within systemd.

1. Can i use systemd-nspawn like QEMU?

2. When iam installing an systemd linux distribution
does this result in an systemd container with my
linux installation (kernel, filesystem, etc.)?
Further, - runs systemd-nspawn service
before my linux kernel image is running?
(because: my .host is a machine and an image, also)

_/var/lib/machines_

When trying to mount a btrfs subvolume as user home directory
on boot, i got an html howto describing this by using
the service var-lib-machines.mount. Later, i realized i
can use mounts in /etc/fstab with btrfs subvolumes directly.

1. What is the /var/lib/machines directory for?
In the documentation of systemd it gets described with
the "usecase" to keep machine images? What is doing
the service var-lib-machines.mount? Like I told, i used it
to mount a btrfs subvolume to my linux filesystem (home)
during boot sequence. Since that, the service is starting
on boot because it is still enabled but for mounting
my home subvolume while fstab is doing the same...

https://cloudnull.io/2017/12/btrfs-subvolume-mounts-yes-you-can/

Is that a useless howto?

THX and sincerely
-kefko


-- 
Wonderful vim doku:
"When a mapping triggers itself, it will run forever"


More information about the systemd-devel mailing list