multipath curthook appears to execute whether or not multipath is disabled

Asked by Matthew Steele

I've been working on some custom designs with autoinstall, and I've run into a problem which appears to be Curtin trying to detect and handle my root partition as a multipath device. I have multipath disabled as per the documentation with the top-level setting:

Beginning snip of my user-data file

  version: 1
    - /custom-installation/
    - /custom-installation/
    update: true
    install-server: true
    mode: disabled


However, the installer still attempts to detect and configure multipath, and fails:

finish: cmd-install/stage-curthooks/builtin/cmd-curthooks/configuring-multipath: FAIL: configuring multipath
        finish: cmd-install/stage-curthooks/builtin/cmd-curthooks: FAIL: curtin command curthooks
        Traceback (most recent call last):
          File "/snap/subiquity/5097/lib/python3.10/site-packages/curtin/commands/", line 202, in main
            ret = args.func(args)
          File "/snap/subiquity/5097/lib/python3.10/site-packages/curtin/commands/", line 1918, in curthooks
            builtin_curthooks(cfg, target, state)
          File "/snap/subiquity/5097/lib/python3.10/site-packages/curtin/commands/", line 1804, in builtin_curthooks
            detect_and_handle_multipath(cfg, target, osfamily=osfamily)
          File "/snap/subiquity/5097/lib/python3.10/site-packages/curtin/commands/", line 1114, in detect_and_handle_multipath
            mpname = block.multipath.get_mpath_id_from_device(mp_device)
          File "/snap/subiquity/5097/lib/python3.10/site-packages/curtin/block/", line 192, in get_mpath_id_from_device
            info = udev.udevadm_info(device)
          File "/snap/subiquity/5097/lib/python3.10/site-packages/curtin/", line 86, in udevadm_info
            output, _ = util.subp(info_cmd, capture=True)
          File "/snap/subiquity/5097/lib/python3.10/site-packages/curtin/", line 275, in subp
            return _subp(*args, **kwargs)
          File "/snap/subiquity/5097/lib/python3.10/site-packages/curtin/", line 108, in _subp
            sp = subprocess.Popen(args, stdout=stdout,
          File "/snap/subiquity/5097/usr/lib/python3.10/", line 971, in __init__
            self._execute_child(args, executable, preexec_fn, close_fds,
          File "/snap/subiquity/5097/usr/lib/python3.10/", line 1796, in _execute_child
   = _posixsubprocess.fork_exec(
        TypeError: expected str, bytes or os.PathLike object, not bool
        expected str, bytes or os.PathLike object, not bool


Looking at the source in at detect_and_handle_multipath, the value of the setting appears to be read, but it appears to be overwritten to be "auto":

def detect_and_handle_multipath(cfg, target, osfamily=DISTROS.debian):
        DISTROS.debian: ['multipath-tools-boot'],
        DISTROS.redhat: ['device-mapper-multipath'],
        DISTROS.suse: ['multipath-tools'],
    if osfamily not in DEFAULT_MULTIPATH_PACKAGES:
        raise ValueError(
                'No multipath package mapping for distro: %s' % osfamily)

    mpcfg = cfg.get('multipath', {})
    mpmode = mpcfg.get('mode', 'auto')
    mppkgs = mpcfg.get('packages',
    mpbindings = mpcfg.get('overwrite_bindings', True)

    if isinstance(mppkgs, str):
        mppkgs = [mppkgs]

    if mpmode == 'disabled':

My install storage is intel fake raid, not multipath - is there some other way to prevent the multipath curthook from executing?

Question information

English Edit question
Ubuntu Edit question
No assignee Edit question
Last query:
Last reply:

Can you help with this problem?

Provide an answer of your own, or ask Matthew Steele for more information if necessary.

To post a message you must log in.