Torizon Core Builder: bundle error: InvalidStorageDriverError

I’m trying to build a project that was previously building fine, under WSL, using the latest Torizon Core Builder docker image.

The build is failing and when I turn on the debug output, I’m seeing the following message:

2024-12-17 08:50:13,968 - root - ERROR - Error: Error trying to bundle Docker containers
2024-12-17 08:50:13,969 - root - DEBUG - Traceback (most recent call last):
File “/builder/tcbuilder/cli/build.py”, line 456, in handle_bundle_common
download_containers_by_compose_file(**download_params)
File “/builder/tcbuilder/backend/bundle.py”, line 591, in download_containers_by_compose_file
manager = DindManager(output_dir, host_workdir)
File “/builder/tcbuilder/backend/bundle.py”, line 168, in init
raise InvalidStorageDriverError(
tcbuilder.errors.InvalidStorageDriverError: Error: Incompatible Docker Storage Driver ‘overlayfs’; only ‘overlay2’ is currently supported.
Learn more on TorizonCore Builder Issue Tracker

I don’t believe that anything has changed since I last built the project a couple of weeks ago (apart from perhaps a Windows update).

Can anyone point me in the right direction to fixing the build?

TIA, Jon.

Hi, I’m the Toradex AI Assistant. The Toradex Support team will follow up with you shortly!

Did you like my answer?

:+1: :-1:


Hello Jon,

Thank you for reaching out with your issue. The error you’re encountering, InvalidStorageDriverError, indicates that the Docker storage driver ‘overlayfs’ is not supported by TorizonCore Builder. Instead, the tool requires the ‘overlay2’ storage driver.

This issue might have arisen due to a change in your Docker configuration, possibly influenced by a recent Windows update or Docker update.

To resolve this, you need to change the Docker storage driver to ‘overlay2’. Here’s how you can do it:

  1. Open Docker Settings:

    • Right-click on the Docker icon in your system tray and select ‘Settings’.
  2. Change the Storage Driver:

    • Navigate to the ‘Docker Engine’ section.
    • You will see a JSON configuration file. Look for the "storage-driver" setting.
    • Change its value to "overlay2". If this setting is not present, you can add it like this:
      {
        "storage-driver": "overlay2"
      }
      
  3. Apply Changes:

    • Save the changes and restart Docker for the new settings to take effect.
  4. Verify the Change:

    • After Docker restarts, you can verify the storage driver by running the command docker info in your terminal. Look for the ‘Storage Driver’ line to ensure it says ‘overlay2’.

Once you have made these changes, try building your project again with TorizonCore Builder. This should resolve the error and allow your build to proceed successfully.

If you continue to experience issues, ensure that your Docker and WSL installations are up to date, as compatibility improvements are frequently released.

I hope this helps! If you have any more questions, feel free to ask.

Best regards,
Toradex AI Assistant.

Please, also check if these links can help you solve your problem:

Error while generating an image that pre-provisions containers (torizoncore-builder bundle).

After making that change to the Docker Engine JSON configuration file, I’m now seeing this error when I try to build the package:

docker: Error response from daemon: InvalidArgument: snapshotter not loaded: overlay2: invalid argument.

It seems like this may have been a compatibility issue between Torizon Core Builder and Windows Docker Desktop when running under WSL2. I was able to build successfully after reverting Windows Docker Desktop to v4.34.1, having seen the problems when I was running the latest version (v.4.36.0).

Dear @jonmills,

Thank you very much for bringing this to our attention. I have brought this up to our Torizon team.

Best regards,
Collin