Message ID | 39b2a0d2ec39701f76a2b6b800f34ba3c123b0e8.1738229957.git.jan.kiszka@siemens.com (mailing list archive) |
---|---|
State | New |
Headers | show |
Series | Provide A/B snapshot support for persistent /var | expand |
On Thu, 2025-01-30 at 10:39 +0100, Jan Kiszka wrote: > From: Jan Kiszka <jan.kiszka@siemens.com> > > Other targets still need testing, some even kernel config tuning. Hi, do we have a target that uses docker / podman? The containers are usually stored on /var and this is not necessarily compatible with BTRFS OOTB. In general, docker does not play nicely with a COW filesystem. That's one of the reasons the docker-btrfs driver was invented. However, I'm unsure how that works together with our A/B logic. For details, please also see https://docs.docker.com/engine/storage/drivers/btrfs-driver/ Best regards, Felix > > Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> > --- > conf/machine/qemu-amd64.conf | 5 ++++- > conf/machine/qemu-arm64.conf | 5 ++++- > conf/machine/x86-uefi.conf | 5 +++-- > 3 files changed, 11 insertions(+), 4 deletions(-) > > diff --git a/conf/machine/qemu-amd64.conf b/conf/machine/qemu- > amd64.conf > index d7866468..5244c86a 100644 > --- a/conf/machine/qemu-amd64.conf > +++ b/conf/machine/qemu-amd64.conf > @@ -1,7 +1,7 @@ > # > # CIP Core, generic profile > # > -# Copyright (c) Siemens AG, 2019-2024 > +# Copyright (c) Siemens AG, 2019-2025 > # > # SPDX-License-Identifier: MIT > # > @@ -11,3 +11,6 @@ DISTRO_ARCH = "amd64" > IMAGE_FSTYPES ?= "ext4" > USE_CIP_KERNEL_CONFIG = "1" > KERNEL_DEFCONFIG = "cip-kernel- > config/${KERNEL_DEFCONFIG_VERSION}/x86/cip_merged_defconfig" > + > +IMAGER_INSTALL:wic += "btrfs-progs" > +VAR_FS_TYPE = "btrfs" > diff --git a/conf/machine/qemu-arm64.conf b/conf/machine/qemu- > arm64.conf > index a2c5e53e..49323a11 100644 > --- a/conf/machine/qemu-arm64.conf > +++ b/conf/machine/qemu-arm64.conf > @@ -1,7 +1,7 @@ > # > # CIP Core, generic profile > # > -# Copyright (c) Siemens AG, 2019 > +# Copyright (c) Siemens AG, 2019-2025 > # > # SPDX-License-Identifier: MIT > # > @@ -16,3 +16,6 @@ KERNEL_DEFCONFIG ?= "cip-kernel- > config/${KERNEL_DEFCONFIG_VERSION}/arm64/cip_mer > WDOG_TIMEOUT = "0" > > PREFERRED_PROVIDER_u-boot-${MACHINE} = "u-boot-qemu-arm64" > + > +IMAGER_INSTALL:wic += "btrfs-progs" > +VAR_FS_TYPE = "btrfs" > diff --git a/conf/machine/x86-uefi.conf b/conf/machine/x86-uefi.conf > index 33f82b16..0a69ea82 100644 > --- a/conf/machine/x86-uefi.conf > +++ b/conf/machine/x86-uefi.conf > @@ -1,7 +1,7 @@ > # > # CIP Core, generic profile > # > -# Copyright (c) Siemens AG, 2019-2024 > +# Copyright (c) Siemens AG, 2019-2025 > # > # SPDX-License-Identifier: MIT > # > @@ -10,6 +10,7 @@ DISTRO_ARCH = "amd64" > > IMAGE_FSTYPES ?= "wic" > WKS_FILE ?= "x86_64-generic.wks" > -IMAGER_INSTALL:wic += "${GRUB_BOOTLOADER_INSTALL}" > +IMAGER_INSTALL:wic += "${GRUB_BOOTLOADER_INSTALL} btrfs-progs" > +VAR_FS_TYPE = "btrfs" > USE_CIP_KERNEL_CONFIG = "1" > KERNEL_DEFCONFIG = "cip-kernel- > config/${KERNEL_DEFCONFIG_VERSION}/x86/cip_merged_defconfig"
On 30.01.25 15:06, Moessbauer, Felix (FT RPD CED OES-DE) wrote: > On Thu, 2025-01-30 at 10:39 +0100, Jan Kiszka wrote: >> From: Jan Kiszka <jan.kiszka@siemens.com> >> >> Other targets still need testing, some even kernel config tuning. > > Hi, > > do we have a target that uses docker / podman? The containers are > usually stored on /var and this is not necessarily compatible with > BTRFS OOTB. In general, docker does not play nicely with a COW > filesystem. That's one of the reasons the docker-btrfs driver was > invented. However, I'm unsure how that works together with our A/B > logic. > > For details, please also see > https://docs.docker.com/engine/storage/drivers/btrfs-driver/ > Yes, there is more to think about when it comes to production use. E.g., you may also not want to rollback your logs in /var/log on failed updates. That pattern we may address later on by creating a carveout from var on a separate partition again. In the end, this here is just a proposal that may need further tuning when further requirements need to be fulfilled. Jan
diff --git a/conf/machine/qemu-amd64.conf b/conf/machine/qemu-amd64.conf index d7866468..5244c86a 100644 --- a/conf/machine/qemu-amd64.conf +++ b/conf/machine/qemu-amd64.conf @@ -1,7 +1,7 @@ # # CIP Core, generic profile # -# Copyright (c) Siemens AG, 2019-2024 +# Copyright (c) Siemens AG, 2019-2025 # # SPDX-License-Identifier: MIT # @@ -11,3 +11,6 @@ DISTRO_ARCH = "amd64" IMAGE_FSTYPES ?= "ext4" USE_CIP_KERNEL_CONFIG = "1" KERNEL_DEFCONFIG = "cip-kernel-config/${KERNEL_DEFCONFIG_VERSION}/x86/cip_merged_defconfig" + +IMAGER_INSTALL:wic += "btrfs-progs" +VAR_FS_TYPE = "btrfs" diff --git a/conf/machine/qemu-arm64.conf b/conf/machine/qemu-arm64.conf index a2c5e53e..49323a11 100644 --- a/conf/machine/qemu-arm64.conf +++ b/conf/machine/qemu-arm64.conf @@ -1,7 +1,7 @@ # # CIP Core, generic profile # -# Copyright (c) Siemens AG, 2019 +# Copyright (c) Siemens AG, 2019-2025 # # SPDX-License-Identifier: MIT # @@ -16,3 +16,6 @@ KERNEL_DEFCONFIG ?= "cip-kernel-config/${KERNEL_DEFCONFIG_VERSION}/arm64/cip_mer WDOG_TIMEOUT = "0" PREFERRED_PROVIDER_u-boot-${MACHINE} = "u-boot-qemu-arm64" + +IMAGER_INSTALL:wic += "btrfs-progs" +VAR_FS_TYPE = "btrfs" diff --git a/conf/machine/x86-uefi.conf b/conf/machine/x86-uefi.conf index 33f82b16..0a69ea82 100644 --- a/conf/machine/x86-uefi.conf +++ b/conf/machine/x86-uefi.conf @@ -1,7 +1,7 @@ # # CIP Core, generic profile # -# Copyright (c) Siemens AG, 2019-2024 +# Copyright (c) Siemens AG, 2019-2025 # # SPDX-License-Identifier: MIT # @@ -10,6 +10,7 @@ DISTRO_ARCH = "amd64" IMAGE_FSTYPES ?= "wic" WKS_FILE ?= "x86_64-generic.wks" -IMAGER_INSTALL:wic += "${GRUB_BOOTLOADER_INSTALL}" +IMAGER_INSTALL:wic += "${GRUB_BOOTLOADER_INSTALL} btrfs-progs" +VAR_FS_TYPE = "btrfs" USE_CIP_KERNEL_CONFIG = "1" KERNEL_DEFCONFIG = "cip-kernel-config/${KERNEL_DEFCONFIG_VERSION}/x86/cip_merged_defconfig"