ma...@germteig.com:
> I am running the Dec 22 9legacy on a machine, and now want to create a 
> bootable USB on it.
> The USB is for a raspberry pi 4 4GB, acting as a standalone auth only.

When you say "bootable USB", do you want to boot the pi4 without an
SD card, and just a USB drive?

If you're happy to have both SD card and USB drive, you can use the
SD card to hold a DOS partition (with bootable kernel and cmdline.txt)
and a fsconfig partition (to hold a partition configuration for a
/dev/fs device (see fs(3)) which maps the USB drive. This is what I do
to set up a pi4 file server with fossil on a SSD drive. My pi4 kernel
config doesn't have partfs, fdisk and prep in the bootdir section,
and does have fs in the dev section. The cmdline.txt is
  readparts=1 nvram=#S/sdM0/nvram fsconfig=#S/sdM0/fscfg 
bootargs=local!/dev/sdXX/fossil
and the fscfg partition on the SD card looks like this (the fsdev:
first line seems to be undocumented)

fsdev:
part sdXX/nvram /dev/sdU0.0/data 2096640 512
part sdXX/fossil /dev/sdU0.0/data 2097152 8192000000
part sdXX/swap /dev/sdU0.0/data 8194097152 2048000000

... plus some other partitions for venti, etc

I use the fs(3) device because I haven't been able to get partfs(8)
to work at boot time. I think there may be a bug in /sys/src/9/boot
where an extra re-mount is missed out.

If you want to boot the pi4 completely from a USB drive, with no
SD card present (I've never tried this), you'll need an alternative
place for a fs(3) configuration (maybe in the built-in bootdir in
the kernel?), or the boot code will need tweaking to get the partfs(8)
partitions re-mounted at the right time.


------------------------------------------
9fans: 9fans
Permalink: 
https://9fans.topicbox.com/groups/9fans/T4cb044b1eee98e3e-Mc9962f736d0b6ee6e0c0ad7b
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription

Reply via email to