I solved the issue. I used a different way to crate the bootable thumb drive.
I used an App called Mist, see GitHub - ninxsoft/Mist: A Mac utility that automatically downloads macOS Firmwares / Installers.
This app automate the process completely. It provides access to :
- A list of Firmwares, you may download a specific one
- A list of Installers, you may download a specific installer or create a bootable Installer
I choose the option the create a bootable Installer. Next step is to select a volume formatted as Mac OS Extended (Journaled). If the drive is not formatted this way, there is a button to open Disk Utility !
Second step is to download the Installer.
Third step is to erase the bootable volume. That's when things went wrong. There was an error (-69888, 0) erasing the disk. Hum, my guess was that the thumb drive may be defective, so I used an 32G microSSD card instead. I started the process again.
Since the Installer has already been downloaded and parsed, that step was skipped. Erase the disk was completed and the bootable drive was successfully created.
The error message sent me in the wrong direction when doing the process in the terminal. It was not a matter of an invalid Installer application, it was a problem with the drive. Mist provided a much more explicit message and I was able to take action. Kudos to Mist creators.
I was able to install Big Sur on a MackBook Pro.
My guess is that createmediafile bash file has bug(s), I kindly ask Apple to have a look at that.
Thanks