use blockdev --rereadpt instead of sleep

FTR, this may not be needed. i have realized after this change that
the pendrive i was using was too small and fdisk errored out in a
way that was not visible in the log, only its symptoms.

but this is a nicer way than arbitrary sleeps for not much extra space.
This commit is contained in:
Attila Lendvai
2023-08-17 23:12:45 +02:00
parent a21e995567
commit 309e6dd80c
2 changed files with 15 additions and 3 deletions

View File

@@ -38,7 +38,8 @@ fi
# the absolute minimum for extroot to work at all (i.e. when the disk is already set up, for example by hand).
# this list may be smaller and/or different for your router, but it works with my ath79.
PREINSTALLED_PACKAGES="block-mount kmod-fs-ext4 kmod-usb-storage"
# blockdev is needed to re-read the partition table using `blockdev --rereadpt /dev/sdX`
PREINSTALLED_PACKAGES="block-mount kmod-fs-ext4 kmod-usb-storage blockdev"
# some kernel modules may also be needed for your hardware
#PREINSTALLED_PACKAGES+=" kmod-usb-uhci kmod-usb-ohci"