LukeShortCloud / rootpages

Root Pages is a collection of easy-to-reference tutorials and guides primarily for Linux and other UNIX-like systems.
Other
57 stars 6 forks source link

[virtualization][virtual_machines] Manually create partitions for Fedora Silverblue with Kickstart #927

Open LukeShortCloud opened 1 year ago

LukeShortCloud commented 1 year ago

This person got close to figuring it out: https://discussion.fedoraproject.org/t/how-to-create-custom-installer-for-vision-five-2-riscv-sbc-with-fedora-silverblue/46098/26

LukeShortCloud commented 1 year ago

Using this manual partition layout in Kickstart:

part biosboot --fstype biosboot --size 1
part /boot/efi --fstype efi --size 99
part /boot --fstype ext4 --size 1000
part btrfs.100 --fstype btrfs --grow
btrfs none --label=root btrfs.100
btrfs / --subvol --name=root root
btrfs /home --subvol --name=home root

Results in this error while booting up:

ostree-prepare-root: Couldn't find specified OSTree root '/sysroot//ostree/boot.0/fedora-silverblue/2a179e4ce3581620c59de35196297b422dbd16e648cf975738ee5fe0b709eaf5/0': No such file or directory

I then rebooted using systemd.unit=rescue.target to view the file system. I found that the file path that exists and should be used (but is not).

$ ls -1 /sysroot/
home
root
$ ls -1 /sysroot/ostree/boot.0/fedora-silverblue/2a179e4ce3581620c59de35196297b422dbd16e648cf975738ee5fe0b709eaf5/0/
bin -> usr/bin
boot
dev
etc
home -> var/home
lib -> usr/lib
lib64 -> usr/lib64
media -> run/media
mnt -> var/mnt
opt -> var/opt
ostree -> sysroot/ostree
proc
root -> var/roothome
run
sbin -> usr/sbin
srv -> var/srv
tmp
usr
var
LukeShortCloud commented 1 year ago

The relevant Anaconda code for managing rpm-ostree can be found here: https://github.com/rhinstaller/anaconda/blob/master/pyanaconda/modules/payloads/payload/rpm_ostree/installation.py