obsidianctl
obsidianctl
is a command-line utility designed to manage A/B boot slots and shared partitions on ObsidianOS systems. It provides functionalities for system installation, status monitoring, active slot switching, and updating system images.
You can run the obsidianctl
script directly. Remember to run it with sudo
as all commands other than obsidianctl status
require root privileges.
sudo obsidianctl [command] [options]
Commands
status
Displays the currently active A/B slot and various system details. This command does not require root.
obsidianctl status
install <device> <system_sfs>
Partitions the specified device and installs the SquashFS system image. WARNING: This will erase all data on the target device.
<device>
: The target block device (e.g.,/dev/sda
).<system_sfs>
: Path to the SquashFS system image file (e.g.,/path/to/obsidianos.sfs
). Defaults to/etc/system.sfs
sudo obsidianctl install /dev/sda /path/to/your_system.sfs
switch <slot>
Switches the active boot slot to either ‘a’ or ‘b’. This change is persistent across reboots.
<slot>
: The slot to make active (a
orb
).
sudo obsidianctl switch a
update <slot> <system_sfs>
Updates a specific A/B slot with a new SquashFS system image. WARNING: This will erase all data on the specified slot.
<slot>
: The slot to update (a
orb
).<system_sfs>
: Path to the new SquashFS system image file.
sudo obsidianctl update b /path/to/new_system_image.sfs
sync <slot>
Clones the currently running slot to the specified slot. This is a block-level copy using dd
. It copies both the root and ESP partitions. WARNING: This will erase all data on the specified slot.
<slot>
: The slot to sync to (a
orb
).
sudo obsidianctl sync b