Skip to content
This repository has been archived by the owner on Nov 9, 2020. It is now read-only.

Commit

Permalink
Booting USB kernel with duid and added more sd devices to make bootin…
Browse files Browse the repository at this point in the history
…g on USB-stick more compatible with different hardware
  • Loading branch information
jryberg committed Oct 2, 2011
1 parent bbaf010 commit 2882a54
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 2 deletions.
9 changes: 9 additions & 0 deletions build-usbimage.sh
Expand Up @@ -106,6 +106,15 @@ echo "Installing disklabel..."
${SUDO} disklabel -R $DEVICE $TEMPFILE
rm $TEMPFILE

echo ""
echo "Setting duid with disklabel..."
${SUDO} disklabel -E $DEVICE << __EOC >/dev/null
i
0123456789abcdef
write
quit
__EOC

echo ""
echo "Creating new filesystem..."
${SUDO} newfs -q /dev/r${DEVICE}a
Expand Down
2 changes: 1 addition & 1 deletion build-usbkernel.sh
Expand Up @@ -87,7 +87,7 @@ gzip -c9 ${CWD}/${WORKDIR}/obj/bsd.rd > ${CWD}/${WORKDIR}/obj/bsd.gz
# Clean up
rm -rf ${CWD}/${WORKDIR}/dev/*
rm -r ${CWD}/obj/*
#rm -f list.temp
rm -f list.temp
rm -f $KERNEL

# Move kernel files from sandbox to the "old" location as before chroot
Expand Down
2 changes: 1 addition & 1 deletion initial-conf/fstab.initial.usb
@@ -1,2 +1,2 @@
/dev/rd0a / ffs rw 0 0
/dev/sd0a /flash ffs ro,sync,noatime 0 1
0123456789abcdef.a /flash ffs ro,sync,noatime 0 1
1 change: 1 addition & 0 deletions list
Expand Up @@ -6,6 +6,7 @@ SPECIAL cd dev; ./MAKEDEV ttyU0 ttyU1
SPECIAL cd dev; ./MAKEDEV tun0 tun1 tun2 tun3 tun4 tun5 tun6 tun7
SPECIAL cd dev; ./MAKEDEV bpf0 bpf1 bpf2 bpf3 bpf4 bpf5 bpf6 bpf7
SPECIAL cd dev; ./MAKEDEV pf crypto fd wsmux wscons apm local gpio
SPECIAL cd dev; ./MAKEDEV sd1 sd2 sd3 sd4 sd5 sd6 sd7 sd8 sd9

COPY ${DESTDIR}/etc/disktab etc/disktab
COPY ${DESTDIR}/etc/login.conf etc/login.conf
Expand Down

0 comments on commit 2882a54

Please sign in to comment.