mirror of
https://github.com/ventoy/Ventoy.git
synced 2025-08-28 00:11:15 +00:00
Fix the hardcoded dev/dm-0
This commit is contained in:
@@ -78,6 +78,9 @@ fi
|
||||
|
||||
ventoy_udev_disk_common_hook "${vtdiskname#/dev/}2" "noreplace"
|
||||
|
||||
ln -s /dev/dm-0 /dev/root
|
||||
blkdev_num=$($VTOY_PATH/tool/dmsetup ls | grep ventoy | sed 's/.*(\([0-9][0-9]*\),.*\([0-9][0-9]*\).*/\1:\2/')
|
||||
vtDM=$(ventoy_find_dm_id ${blkdev_num})
|
||||
cp -a /dev/$vtDM /dev/ventoy
|
||||
ln -s /dev/$vtDM /dev/root
|
||||
|
||||
PATH=$VTPATH_OLD
|
||||
|
@@ -19,5 +19,5 @@
|
||||
|
||||
. $VTOY_PATH/hook/ventoy-os-lib.sh
|
||||
|
||||
$SED "s#^CDROM=.*#CDROM=/dev/dm-0#" -i /init
|
||||
$SED "s#^CDROM=.*#CDROM=/dev/ventoy#" -i /init
|
||||
$BUSYBOX_PATH/cp -a $VTOY_PATH/hook/easystartup/ventoy-initqueue.sh /initqueue/ventoy.sh
|
||||
|
Reference in New Issue
Block a user