Bug#665475: os-prober: follows symlinks in /dev/mapper/
Package: os-prober
Version: 1.49ubuntu1
Severity: normal
os-prober follows symbolic links in /dev/mapper/ which results in the
"root" parameter of the kernel being set to /dev/dm-<X>. This is an
issue because /dev/dm-<X> isn't guaranteed to map to the same logical
volume across reboots.
A possible fix would be to modify /usr/share/os-prober/common.sh to have:
---
if ! type mapdevfs >/dev/null 2>&1; then
mapdevfs () {
[ -n $(echo "$1" | grep "^/dev/mapper/") ] && echo "$1" || readlink -f "$1"
}
fi
---
instead of:
---
if ! type mapdevfs >/dev/null 2>&1; then
mapdevfs () {
readlink -f "$1"
}
fi
---
Regards,
Alexis
Reply to: