osmates vm update-firmware
Save a stopped Windows machine, then update its firmware to Debian's newest EDK2.
osmates vm update-firmware <machine> [--without-agent] [--json]OSMates gets the EDK2 a new machine gets, Debian trixie's newest, or the newest one it has offline. When the machine has that build already, nothing changes. Otherwise OSMates saves the machine as a snapshot named "Before firmware <version>", starts Windows without a window and has the guest agent suspend BitLocker for one start, shuts Windows down, replaces the firmware, starts Windows again to resume BitLocker, and shuts it down: about 5 minutes. Until BitLocker resumes, the drive's key is unprotected on its disk. The machine must be shut down first. If the agent does not answer or BitLocker waits for a PIN, nothing changes. --without-agent replaces the firmware without starting Windows: BitLocker asks for its recovery key at the next start unless you suspended it in Windows first. To go back, revert to the snapshot it names.
Arguments
<machine>RequiredThe machine's name or identifier.
--without-agentReplace the firmware without asking Windows to suspend BitLocker.
--jsonPrint machine-readable JSON.
JSON output
With --json, it prints an object with these fields.
JSON Schema: /schemas/0/cli/vm/update-firmware.json
bitLockerstring or objectOne of
suspendedAndResumed,notAsked,notResumed, or an object that holds one key:alreadySuspendedornotNeeded.bitLocker.alreadySuspendedobjectbitLocker.notNeededobjectfromobjectfrom.sha256stringRequiredfrom.versionstringRequiredmachinestringRequiredsnapshotobjectsnapshot.idstring (uuid)Requiredsnapshot.namestringRequiredtoobjectRequiredto.sha256stringRequiredto.versionstringRequiredupdatedbooleanRequired
Fields nested deeper are in the schema.
Exit statuses
Its exit status is one of these.
| Status | Meaning |
|---|---|
| 0 | The command did what it was asked. |
| 1 | The command failed; with --json, standard error's last line is the error object. |
| 64 | The command line is wrong, as ArgumentParser found before the command ran. |
| 65 | What was given is wrong, found while the command ran; the same command fails until it changes. |
| 75 | The same command can work later with nothing changed, as while an update finishes. |
| 130 | Control-C cancelled what the command started. |