recovery-initramfs: launch mdev as daemon

'mdev -s' run on ramfs initialization is able to mount external media already
detected but fails to automatically mount any media detected afterwards.
Running it as a daemon first it will also be able to mount any media detected
after 'mdev -s' is run.

Use argument '-d' to first run mdev as daemon in background.

Move 2 seconds delay to after mdev has been initialized to give external
hardware all the time possible to be successfully detected and mounted.

https://onedigi.atlassian.net/browse/DEL-7285

Signed-off-by: Gonzalo Ruiz <Gonzalo.Ruiz@digi.com>
This commit is contained in:
Gonzalo Ruiz 2021-06-21 09:37:47 +02:00
parent 2a72f64c40
commit 3e75c1ed34
1 changed files with 4 additions and 3 deletions

View File

@ -484,14 +484,15 @@ mount -t sysfs sysfs /sys
mount -t devtmpfs devtmpfs /dev
mount -t tmpfs tmpfs /tmp
# Give some time for the devices to settle down so mdev can mount all of them
sleep 2
# Register mdev as device manager
echo > /dev/mdev.seq
echo > /dev/mdev.log
mdev -d
mdev -s
# Give some time for the devices to settle down so mdev can mount all of them
sleep 2
# Run all shell scripts in postinstall folder
run-parts /etc/*-postinsts