安装Gentoo时无意中发现/boot/boot是一个指向本身的链接,于是跑到Gentoo的论坛上去问了一下,结果管理员大大很快就给出了答案,简而言之是为了使得grub保持简单,因为grub引导系统时,linux的文件系统树并没有集合起来,这个时候/下面是找不到/boot的,即使是“point root (hd,x,y) to / as /boot“也是不行的,所以解决方法就是一个symlink to itself(.)
帖子地址:http://forums.gentoo.org/viewtopic-p-6172018.html#6172018
内容如下:
hewig-ovens
发表于: Sat Feb 13, 2010 1:57 am 发表主题: why /boot/boot is a symbolic link?
I am very curious about why~
_________________
NeddySeagoon
Administrator
来自: 56N 3W 发表于: Sat Feb 13, 2010 5:35 am 发表主题:
hewig-ovens,
Its to keep the grub documentation simple.
When you do not have a boot partition and /boot is a directory on the / (root) partiton, the pathname to your kernel is
and the root (hdx,y) statement points to your / (root) partition.
Now everything works as expected.
When you have a real boot, the root (hdx,y) statement points to the boot partition and a kernel at /boot/kernel... will not be found as the path /boot does not exist.
As the filesystem tree is not assembled when grub boots the system, you can't point root (hd,x,y) to / as /boot is not attached.
The solution is a symlink called boot, pointing to itseld (.) so the kernel can still be at
but now, the symlink is used to satisfy the reference to /boot
_________________
Regards,
NeddySeagoon