|
修改了ubuntu24.10 livecd initrd里的scripts/casper-helpers脚本,尝试使用ntfs3挂载,但是直接挂载失败了(提示No such device)。又重新编译了内核(用的ubuntu官方6.11.11内核的源码),直接在内核里添加ntfs3就成功了,关机也不会卡死,后台也没有mount.ntfs的进程。稳定性和速度还没有测试。
- --- casper-helpers.bak
- +++ casper-helpers
- @@ -182,7 +182,11 @@
- mount -o bind $(where_is_mounted ${dev}) ${mountp} || panic "Cannot bind-mount"
- return 0
- else
- - mount -t $(get_fstype "${dev}") -o "${opts}" "${dev}" "${mountp}"
- + devfstype=$(get_fstype "${dev}")
- + if [ "$devfstype" == "ntfs" ]; then
- + devfstype="ntfs3"
- + fi
- + mount -t $devfstype -o "${opts}" "${dev}" "${mountp}"
- ret=$?
- if [ $ret -ne 0 ]; then
- log_warning_msg "Cannot mount ${dev} on ${mountp}"
- @@ -372,6 +376,7 @@
- modprobe jfs
- modprobe vfat
- modprobe fuse
- + modprobe ntfs3
- [ "$quiet" != "y" ] && log_end_msg "...devs loaded..."
- touch /dev/.initramfs/lupin-waited-for-devs
- }
复制代码 |
|