当前时区为 UTC + 8 小时



发表新帖 回复这个主题  [ 7 篇帖子 ] 
作者 内容
1 楼 
 文章标题 : os-prober 探测不到 Archlinux,除非挂载 Arch 所在分区
帖子发表于 : 2015-09-14 15:02 
头像

注册: 2011-03-20 13:12
帖子: 4519
地址: 山东省寿光县
系统: Debian
送出感谢: 105
接收感谢: 997
代码:
Disk /dev/sda: 465.8 GiB, 500107862016 bytes, 976773168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: dos
Disk identifier: 0xa18470c7

Device     Boot    Start       End   Sectors   Size Id Type  Filesystem OS
/dev/sda1           2048  27650047  27648000  13.2G 83 Linux xfs        Archlinux
/dev/sda2       52600832  97656831  45056000  21.5G  7 NTFS  NTFS       Microsoft Windows
/dev/sda3       97656832 974725119 877068288 418.2G 83 Linux ext4       -
/dev/sda4  *    27650048  52600831  24950784  11.9G 83 Linux ext4       Debian GNU/Linux


代码:
# os-prober
/dev/sda2:Windows 7 (loader):Windows:chain
# mount /dev/sda1 /mnt
# os-prober
/dev/sda1::Arch:linux
/dev/sda2:Windows 7 (loader):Windows:chain


探测不到 Arch 时 os-prober 的输出 http://paste.ubuntu.com/12406751/
能探测到 Arch 时 os-prober 的输出 http://paste.ubuntu.com/12406757/

安装时参考的这一篇:https://wiki.archlinux.org/index.php/Beginners%27_guide

怎样解决呢? :em20

参考:
http://askubuntu.com/questions/180882/os-prober-doesnt-find-arch-linux-until-i-manually-mount-arch-linux-partition
https://bugzilla.redhat.com/show_bug.cgi?id=995777
https://bbs.archlinux.org/viewtopic.php?id=165715


_________________
Debian 中文论坛 - forums.debiancn.org
欢迎所有 Debian GNU/Linux 用户


页首
 用户资料  
 
2 楼 
 文章标题 : Re: os-prober 探测不到 Archlinux,除非挂载 Arch 所在分区
帖子发表于 : 2015-09-14 16:22 
头像

注册: 2010-04-10 16:14
帖子: 2903
系统: Arch Linux
送出感谢: 8
接收感谢: 69
第2个参考链接的说法很有意思,貌似不是因为没挂载所以探测不到,而是因为没做“some kind of recovery”,
可以试试看比如 fsck 一下这个分区再执行一次看看会不会探测到,如果会的话,那就
把 arch 分区写到 fstab 里面,可以加上 noauto 选项让它不自动挂载,fstab 的第六栏 fs_passno 设置成 2,这样开机的时候会 fsck 一次。


_________________
dz,U,EIS. cies.
dz-cies@github
小香猪杀手@cc98.org



_________________
评价: 3.7% vickycq
 
页首
 用户资料  
 
3 楼 
 文章标题 : Re: os-prober 探测不到 Archlinux,除非挂载 Arch 所在分区
帖子发表于 : 2015-09-14 17:05 

注册: 2009-08-04 16:33
帖子: 16882
送出感谢: 21
接收感谢: 1825
引用:
安装时参考的这一篇:https://wiki.archlinux.org/index.php/Beginners%27_guide

如果你在安裝的 archlinux 內執行 os-prober 結果不包含 archlinux 所在的分割區 應該是正常的

參見
http://www.unix.com/man-page/centos/1/os-prober/
os-prober -- Discover bootable partitions on the local system.
The os-prober utility will scan all disks available on the system for other operating systems. For each discovered OS, it will output a line of the form:
引用:
怎样解决呢?

也許 這一篇 可以給你一些亮點 (Tip)
https://bbs.archlinux.org/viewtopic.php?id=145875
Tip for using Grub2 in another operating system

補充
在 grub 2 分工設計 掃描 本作業系統 (archlinux) 分割區裡的所有可開機檔案 是 /etc/grub.d/10_linux 的功能
試試
sudo /etc/grub.d/10_linux
https://wiki.archlinux.org/index.php/GR ... mmended.29
/etc/grub.d/10_linux is set to automatically add menu items for Arch linux that work out of the box, to any generated configuration.



_________________
评价: 3.7% vickycq
 
页首
 用户资料  
 
4 楼 
 文章标题 : Re: os-prober 探测不到 Archlinux,除非挂载 Arch 所在分区
帖子发表于 : 2015-09-14 18:26 
头像

注册: 2011-03-20 13:12
帖子: 4519
地址: 山东省寿光县
系统: Debian
送出感谢: 105
接收感谢: 997
susbarbatus 写道:
第2个参考链接的说法很有意思,貌似不是因为没挂载所以探测不到,而是因为没做“some kind of recovery”,
可以试试看比如 fsck 一下这个分区再执行一次看看会不会探测到,如果会的话,那就
把 arch 分区写到 fstab 里面,可以加上 noauto 选项让它不自动挂载,fstab 的第六栏 fs_passno 设置成 2,这样开机的时候会 fsck 一次。


感谢回复,用 fsck.xfs (xfs_repair) 检测无异常。不过倾向于认为 os_prober 对 xfs 分区的检测有问题。


_________________
Debian 中文论坛 - forums.debiancn.org
欢迎所有 Debian GNU/Linux 用户


页首
 用户资料  
 
5 楼 
 文章标题 : Re: os-prober 探测不到 Archlinux,除非挂载 Arch 所在分区
帖子发表于 : 2015-09-14 18:28 
头像

注册: 2011-03-20 13:12
帖子: 4519
地址: 山东省寿光县
系统: Debian
送出感谢: 105
接收感谢: 997
poloshiao 写道:
如果你在安裝的 archlinux 內執行 os-prober 結果不包含 archlinux 所在的分割區 應該是正常的

恕删

也許 這一篇 可以給你一些亮點 (Tip)
https://bbs.archlinux.org/viewtopic.php?id=145875
Tip for using Grub2 in another operating system

補充
在 grub 2 分工設計 掃描 本作業系統 (archlinux) 分割區裡的所有可開機檔案 是 /etc/grub.d/10_linux 的功能
試試


感谢回复,os-prober 是在 debian 系统中执行的。arch 未安装 grub。

在 arch 中安装了 lsb-release 后依然无效。

目前倾向于认为:
1) xfs 文件系统和 os-prober 不对付
2) mkinitcpio 出了问题。(挂载arch所在分区后update-grub可以生成对应启动项,但开机grub界面选择后立刻重启。)


_________________
Debian 中文论坛 - forums.debiancn.org
欢迎所有 Debian GNU/Linux 用户


页首
 用户资料  
 
6 楼 
 文章标题 : Re: os-prober 探测不到 Archlinux,除非挂载 Arch 所在分区
帖子发表于 : 2015-09-14 18:59 

注册: 2009-08-04 16:33
帖子: 16882
送出感谢: 21
接收感谢: 1825
引用:
os-prober 是在 debian 系统中执行的

https://bugs.launchpad.net/ubuntu/+sour ... ug/1038093
Fedora17 and ArchLinux dont appear in GRUB menu

https://bugs.launchpad.net/ubuntu/+sour ... omments/19
This bug is fix

https://bugs.launchpad.net/ubuntu/+sour ... omments/20
os-prober detects arch without its partition being mounted.



_________________
评价: 3.7% vickycq
 
页首
 用户资料  
 
7 楼 
 文章标题 : Re: os-prober 探测不到 Archlinux,除非挂载 Arch 所在分区
帖子发表于 : 2015-09-14 20:45 
头像

注册: 2011-03-20 13:12
帖子: 4519
地址: 山东省寿光县
系统: Debian
送出感谢: 105
接收感谢: 997
将 arch 所在分区重新格式化为 ext4,重装。在 debian 中 update-grub,执行到 /usr/lib/os-probes/50mounted-tests 一步时卡住。用 ^C 终止,再 update-grub,提示 failed to remove ‘/var/lib/os-prober/mount’: Device or resource busy 但成功检测到 arch。

重启进入 arch,安装 lsb-release,再进入 debian 执行 update-grub,成功检测到 arch,没有错误发生。


_________________
Debian 中文论坛 - forums.debiancn.org
欢迎所有 Debian GNU/Linux 用户


页首
 用户资料  
 
显示帖子 :  排序  
发表新帖 回复这个主题  [ 7 篇帖子 ] 

当前时区为 UTC + 8 小时


在线用户

正在浏览此版面的用户:没有注册用户 和 1 位游客


不能 在这个版面发表主题
不能 在这个版面回复主题
不能 在这个版面编辑帖子
不能 在这个版面删除帖子
不能 在这个版面提交附件

前往 :  
本站点为公益性站点,用于推广开源自由软件,由 DiaHosting VPSBudgetVM VPS 提供服务。
我们认为:软件应可免费取得,软件工具在各种语言环境下皆可使用,且不会有任何功能上的差异;
人们应有定制和修改软件的自由,且方式不受限制,只要他们自认为合适。

Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
简体中文语系由 王笑宇 翻译