How is the Ubuntu Startup Disk Creator deciding which iso files to accept as input? - and a workaround

The current version of the Ubuntu Startup Disk Creator (in Ubuntu 16.04 LTS and newer versions of Ubuntu) is easy to use. And it is a cloning tool, which makes it reliable.

It seems dedicated to creating USB boot drives for Ubuntu and Ubuntu family flavours (Kubuntu, Lubuntu ... Xubuntu).

I have tested with various iso files outside the Ubuntu family:

  • Respins based on Ubuntu are usually accepted as input
  • A few respins based on Debian are also accepted as input
  • Debian live iso files are not accepted (they do not appear in the box for input files after selecting them).
  • Other main linux distros for example Fedora and OpenSUSE are not accepted.

This is rather confusing and I draw the conclusion, that there is some filter, that decides which iso files to accept.

  • How is the Startup Disk Creator deciding which iso files to accept as input? What is it looking for in the iso file or in the file name?
  • Edit: Is there a workaround?

The Startup Disk Creator checks for two files in the iso file

Kudos @ubfan1 :-)

I looked into the Python code. At first it looked overwhelming, but soon I found a function that looked promising:

In the file /usr/lib/python3/dist-packages/usbcreator/backends/udisks/backend.py there is

def _is_casper_cd(self, filename):
    for search in ['/.disk/info', '/.disk/mini-info']:
        cmd = ['isoinfo', '-J', '-i', filename, '-x', search]
        try:
            output = misc.popen(cmd, stderr=None)
            if output:
                return output
        except misc.USBCreatorProcessException:
            # TODO evand 2009-07-26: Error dialog.
            logging.error('Could not extract .disk/info.')
    return None

which indicates that the Startup Disk Creator is checking for the content of the files /.disk/info and /.disk/mini-info.

These are present in Ubuntu, Debian and many but not all respins. The funny thing is that the difference between Debian 10.2 and Kali is a trailing line feed. I checked with Debian 8.8. It contains a newline and is accepted by the Startup Disk Creator.

sudodus@bionic64 /media/multimed-2/CD/debian $ sudo mount -o loop debian-live-8.8.0-amd64-standard.iso /mnt/lp1
mount: /mnt/lp1: VARNING: enhet skrivskyddad, monterad som endast läsbar.
sudodus@bionic64 /media/multimed-2/CD/debian $ cat /mnt/lp1/.disk/info
Debian GNU/Linux 8 "Jessie" - Official Snapshot amd64 LIVE/INSTALL Binary 20170506-14:26
sudodus@bionic64 /media/multimed-2/CD/debian $ sudo mount -o loop debian-live-10.2.0-amd64-standard.iso /mnt/lp2
mount: /mnt/lp2: VARNING: enhet skrivskyddad, monterad som endast läsbar.
sudodus@bionic64 /media/multimed-2/CD/debian $ cat /mnt/lp2/.disk/info
Official Debian GNU/Linux Live 10.2.0 standard 2019-11-16T10:15sudodus@bionic64 /media/multimed-2/CD/debian $ 

So it seems that I have found a bug. The Startup Disk Creator does not accept an iso file unless there is a trailing newline character in the file /.disk/info or /.disk/mini-info.

Edit 1: I reported the bug

Bug #1860411: The Startup Disk Creator is glitchy when I try to use non-Ubuntu iso files

Please help raising the heat by marking that This bug affects you.

Edit 2: Workaround - 'any' img file is accepted as input

You can trick the Startup Disk Creator to clone non-Ubuntu iso files, because it is willing to clone 'any' image file with the extension img. So make a symbolic link, for example

$ ln -s debian-live-11.0.0-amd64-standard.iso debian-live-11.0.0-amd64-standard.img
$ ls -ltr
total 924676                                                                                                                          
-rw-r--r-- 1 lubuntu lubuntu 946864128 Aug 18 13:02 debian-live-11.0.0-amd64-standard.iso
lrwxrwxrwx 1 lubuntu lubuntu        37 Oct 11 11:18 debian-live-11.0.0-amd64-standard.img -> debian-live-11.0.0-amd64-standard.iso

I tested this in 18.04.x LTS with usb-creator-gtk and in persistent live Lubuntu Impish Indri with usb-creator-kde, and it worked for me. The following screenshots are from Lubuntu Impish Indri,

enter image description here

enter image description here

enter image description here