Custom wic partition layout A/B rootfs and factory using tezi - not applied in final tar

Hi, I’m the Toradex AI Assistant.

I might make mistakes or occasionally get you wrong. Our support team will step in if needed.


I can help you create custom partitions in your Yocto build. Based on your setup with Verdin iMX8M Plus, you’re on the right track but need to adjust your approach for the Toradex Easy Installer (TEZI) format.

Understanding Your Current Setup

Your current configuration shows you’re trying to use both WIC format and TEZI format simultaneously. For Toradex modules, you need to focus on the TEZI approach since that’s what the Toradex Easy Installer expects.

Solution: Custom Partition Configuration

1. Update Your TEZI JSON Configuration

Based on the community examples (1), you can add custom partitions directly in your lokbest-tezi-image.json. Here’s how to structure it for your dual boot + factory setup:

{
  "config_format": "4",
  "autoinstall": false,
  "name": "Lokbest Firmware",
  "description": "Lokbest Partitioned Firmware with A/B OTA + Factory + Recovery + Data",
  "version": "1.0.0",
  "release_date": "2026-01-13",
  "supported_product_ids": [ "0063" ],
  "blockdevs": [
    {
      "name": "emmc-boot0",
      "erase": true,
      "content": {
        "filesystem_type": "raw",
        "rawfiles": [
          { "filename": "imx-boot", "dd_options": "seek=0" }
        ]
      }
    },
    {
      "name": "emmc",
      "partitions": [
        {
          "partition_size_nominal": 64,
          "want_maximised": false,
          "content": {
            "filesystem_type": "fat32",
            "label": "BOOT",
            "filename": "Reference-Multimedia-Image-verdin-imx8mp.rootfs.bootfs.tar.xz"
          }
        },
        {
          "partition_size_nominal": 2048,
          "want_maximised": false,
          "content": {
            "filesystem_type": "ext4",
            "label": "rootfs_A",
            "filename": "Reference-Multimedia-Image-verdin-imx8mp.rootfs.tar.xz"
          }
        },
        {
          "partition_size_nominal": 2048,
          "want_maximised": false,
          "content": {
            "filesystem_type": "ext4",
            "label": "rootfs_B"
          }
        },
        {
          "partition_size_nominal": 2048,
          "want_maximised": false,
          "content": {
            "filesystem_type": "ext4",
            "label": "factory"
          }
        },
        {
          "partition_size_nominal": 512,
          "want_maximised": false,
          "content": {
            "filesystem_type": "ext4",
            "label": "recovery"
          }
        },
        {
          "partition_size_nominal": 128,
          "want_maximised": true,
          "content": {
            "filesystem_type": "ext4",
            "label": "data"
          }
        }
      ]
    }
  ],
  "prepare_script": "prepare.sh",
  "wrapup_script": "wrapup.sh",
  "icon": "toradexlinux.png",
  "marketing": "marketing.tar",
  "license": "LA_OPT_NXP_SW.html",
  "u_boot_env": "u-boot-initial-env-sd"
}

(1)

2. Update Your Recipe Configuration

Modify your tdx-reference-multimedia-image.bbappend:

# Add our kiosk launcher
IMAGE_INSTALL:append = " display-qr-launch"

# Remove Toradex auto-launch system entirely
APP_LAUNCH_WAYLAND = ""
IMAGE_INSTALL:remove = " wayland-qtdemo-launch-cinematicexperience"
IMAGE_INSTALL:remove = " wayland-qtdemo-launch-analogclock"
IMAGE_INSTALL:remove = " wayland-qtdemo-launch-qtsmarthome"
IMAGE_INSTALL:remove = " wayland-terminal-launch"

# Enable TEZI format
IMAGE_FSTYPES += " teziimg"

# Override Tezi JSON to use custom partition layout
TEZI_IMAGE_JSON:${IMAGE_BASENAME} = "${THISDIR}/images/lokbest-tezi-image.json"

# Keep default rootfs and bootfs generation for TEZI
# Remove the WIC-related configurations since TEZI handles partitioning

(2)

3. Understanding the Build Process

The reason you’re still seeing the default rootfs and bootfs tarballs is because the Toradex BSP layers handle partition creation through the TEZI format, not through WIC when using Toradex Easy Installer (3). The image_type_tezi.bbclass is responsible for creating the final TEZI package with your custom JSON configuration (1).

4. Key Points for Success

  1. Remove WIC Configuration: Since you’re using TEZI, remove the WIC-related variables from your bbappend
  2. Keep TEZI Tarballs: Don’t disable TEZI_DEFAULT_BOOTFS and TEZI_DEFAULT_ROOTFS as these are needed for your primary partitions
  3. Partition Structure: The TEZI format will handle creating all partitions defined in your JSON during installation

5. Build and Deploy

After making these changes:

  1. Clean and rebuild your image:
bitbake -c cleanall tdx-reference-multimedia-image
bitbake tdx-reference-multimedia-image
  1. The resulting TEZI package will contain your custom partition layout and will create all specified partitions during installation on the target device.

This approach leverages the Toradex Easy Installer’s native partition management capabilities rather than trying to override it with WIC, which should give you the custom partition layout you need for your dual boot + factory setup.

Best regards, Toradex AI Assistant.


Did you like my answer? :+1: :-1:

If I answered your question, please tick the “Solution” checkbox.

For follow-up questions to me, please use @ToradexAI in your post.