LinuxSir.Org  
| 网站首页 | 论坛帮助 |

欢迎来到LinuxSir.Org!
您还未登录,请登录后查看论坛,或者点击论坛上方的注册链接注册新账号。


发表新主题 回复
 
主题工具
旧 10-08-03, 21:13 第 1 帖
gzl1100
 
 
 
注册会员  
  注册日期: Mar 2009
  帖子: 30
  精华: 0
 

标题: [已解决]LFS制作完成,并能正常使用,但是引导过程提示错误


宿主OS:redflag-6.0-sp3
包:lfs-packages-6.6.tar
参考:lfs-6.6英文文档
制作完成lfs,重启之后,在引导界面。
提示:
swapon:/dev/sda8:stat faild:No such file or directory
Mounting root file system in read-only mode…
checking file system…
fsck.ext3:No such file or dirctory while trying to opn /dev/sda10
/dev/sda10:
The superblock could not be read or does describe a correct ext2 filesystem.if the device is valid and it really contains an ext2 filesystem (and not swap or ufs or something else),then the superblock is corrupt,and you might try running esfsck with an alternate superblock:
e2fsck -b 8193 <device>

=======================
root:/# more /etc/fstab
# Begin /etc/fstab

# file system mount-point type options dump fsck
# order

/dev/sda10 / ext3 defaults 1 1
/dev/sda8 swap swap pri=1 0 0
proc /proc proc defaults 0 0
sysfs /sys sysfs defaults 0 0
devpts /dev/pts devpts gid=4,mode=620 0 0
tmpfs /dev/shm tmpfs defaults 0 0
# End /etc/fstab
=======================

root:/# fdisk -l

Disk /dev/sda: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
Disk identifier: 0xea67ea67

Device Boot Start End Blocks Id System
/dev/sda1 * 1 1894 15213523+ 7 HPFS/NTFS
/dev/sda2 1895 19457 141074797+ f W95 Ext'd (LBA)
/dev/sda5 1895 7650 46235038+ 7 HPFS/NTFS
/dev/sda6 7651 11522 31101808+ 7 HPFS/NTFS
/dev/sda7 11523 13373 14868126 83 Linux
/dev/sda8 13374 13495 979933+ 82 Linux swap / Solaris
/dev/sda9 13496 17958 35840000 83 Linux
/dev/sda10 17958 19457 12048705 83 Linux
===============================
/boot/grub/grub.cfg

menuentry "GNU/Linux, with Linux 2.6.32.8-lfs-6.6" {
insmod ext2
set root=(hd0,10)
search --no-floppy --fs-uuid --set 11c7d93a-3a17-4e23-985f-36717d36c7ad
linux /boot/vmlinux-2.6.32.8-lfs-6.6 root=/dev/sda10 ro
}

此帖于 10-08-06 21:57 被 gzl1100 编辑.
  gzl1100 当前离线   回复时引用此帖
旧 10-08-03, 21:15 第 2 帖
gzl1100
 
 
 
注册会员  
  注册日期: Mar 2009
  帖子: 30
  精华: 0
 

顺便补充下:kernel肯定支持ext2、ext3、ext4
已经测试过以下办法,仍然不行:
$umount /dev/sda10
$e2fsck -b 8193 /dev/sda10
仍然提示:
The superblock could not be read or does describe a correct ext2 filesystem.if the device is valid and it really contains an ext2 filesystem (and not swap or ufs or something else),then the superblock is corrupt,and you might try running esfsck with an alternate superblock:
e2fsck -b 8193 <device>

然后参考:http://www.linuxsir.org/bbs/showthread.php?t=167666
$mke2fs -n /dev/sda10
$e2fsck -b 32768 /dev/sda10
修复一下,重启,依然提示:如上错误。

此帖于 10-08-03 21:35 被 gzl1100 编辑.
  gzl1100 当前离线   回复时引用此帖
旧 10-08-03, 23:48 第 3 帖
cqcya
 
cqcya 的头像
 
 
注册会员  
  注册日期: Sep 2004
  我的住址: 重庆 沙坪坝
  帖子: 187
  精华: 0
 

应该是kernel的问题,我以前也碰见过,kernel编译时要选支持SATA硬盘
  cqcya 当前离线   回复时引用此帖
旧 10-08-04, 07:28 第 4 帖
gzl1100
 
 
 
注册会员  
  注册日期: Mar 2009
  帖子: 30
  精华: 0
 

请问kernel的SATA的驱动位置,这样我好重新编译,谢谢了。
  gzl1100 当前离线   回复时引用此帖
旧 10-08-04, 11:40 第 5 帖
gzl1100
 
 
 
注册会员  
  注册日期: Mar 2009
  帖子: 30
  精华: 0
 

引用:
作者: cqcya
应该是kernel的问题,我以前也碰见过,kernel编译时要选支持SATA硬盘
你是对的,我用make menuconfig查看了下Device Drivers中ATA的选项确实没有编译进内核。现在只能重新编译一下内核,再看看。
  gzl1100 当前离线   回复时引用此帖
旧 10-08-04, 13:10 第 6 帖
gzl1100
 
 
 
注册会员  
  注册日期: Mar 2009
  帖子: 30
  精华: 0
 

非常感谢,重新编译并添加ATA支持后,LFS制作完成,并成功进入。
  gzl1100 当前离线   回复时引用此帖
旧 10-08-04, 13:18 第 7 帖
cqcya
 
cqcya 的头像
 
 
注册会员  
  注册日期: Sep 2004
  我的住址: 重庆 沙坪坝
  帖子: 187
  精华: 0
 

引用:
作者: gzl1100
非常感谢,重新编译并添加ATA支持后,LFS制作完成,并成功进入。
嘿嘿不用谢,多作几次就有经验了
  cqcya 当前离线   回复时引用此帖
旧 10-08-04, 20:58 第 8 帖
gzl1100
 
 
 
注册会员  
  注册日期: Mar 2009
  帖子: 30
  精华: 0
 

经过重新编译,并添加STAT驱动,已经能够正常使用LFS,但是在引导过程提示:
mount:mount point /dev/pts does not exist
mount:mount point /dev/shm does not exist [fail]
请问我的LFS到底那里出错了,如何修复。

/etc/fstab

/dev/sda10 / ext3 defaults 1 1
/dev/sda8 swap swap pri=1 0 0
proc /proc proc defaults 0 0
sysfs /sys sysfs defaults 0 0
devpts /dev/pts devpts gid=4,mode=620 0 0
tmpfs /dev/shm tmpfs defaults 0 0
  gzl1100 当前离线   回复时引用此帖
旧 10-08-04, 21:15 第 9 帖
cqcya
 
cqcya 的头像
 
 
注册会员  
  注册日期: Sep 2004
  我的住址: 重庆 沙坪坝
  帖子: 187
  精华: 0
 

问题还是出来kernel,你看看Chapter 8. Making the LFS System Bootable,The /dev/shm mount point for tmpfs is included to allow enabling POSIX-shared memory. The kernel must have the required support built into it for this to work (more about this is in the next section). Please note that very little software currently uses POSIX-shared memory. Therefore, consider the /dev/shm mount point optional. For more information, see Documentation/filesystems/tmpfs.txt in the kernel source tree.

中文:/dev/shm 挂载点是为了tmpfs能包括启用POSIX共享内存。 这需要内核必须在编的时候支持这个选项才能起作用 (更多相关信息在下一章)。请注意, 目前很少软件使用POSIX共享内存。因而,认为/dev/shm加载点是可选的。 更多信息,请参考内核源码目录中的Documentation/filesystems/tmpfs.txt。
  cqcya 当前离线   回复时引用此帖
旧 10-08-04, 21:44 第 10 帖
gzl1100
 
 
 
注册会员  
  注册日期: Mar 2009
  帖子: 30
  精华: 0
 

如果在/etc/fstab中注释掉
#devpts /dev/pts devpts gid=4,mode=620 0 0
#tmpfs /dev/shm tmpfs defaults 0 0
按照字面意思应该不会对LFS OS有影响。如果以后我继续BLFS会不会有影响?
  gzl1100 当前离线   回复时引用此帖
旧 10-08-06, 21:59 第 11 帖
gzl1100
 
 
 
注册会员  
  注册日期: Mar 2009
  帖子: 30
  精华: 0
 

引用:
作者: cqcya
问题还是出来kernel,你看看Chapter 8. Making the LFS System Bootable,The /dev/shm mount point for tmpfs is included to allow enabling POSIX-shared memory. The kernel must have the required support built into it for this to work (more about this is in the next section). Please note that very little software currently uses POSIX-shared memory. Therefore, consider the /dev/shm mount point optional. For more information, see Documentation/filesystems/tmpfs.txt in the kernel source tree.

中文:/dev/shm 挂载点是为了tmpfs能包括启用POSIX共享内存。 这需要内核必须在编的时候支持这个选项才能起作用 (更多相关信息在下一章)。请注意, 目前很少软件使用POSIX共享内存。因而,认为/dev/shm加载点是可选的。 更多信息,请参考内核源码目录中的Documentation/filesystems/tmpfs.txt。
我用make menuconfig查看了下内核发现tmpfs、ptsfs已经编译进内核了。后来想可能是在编译、安装udev的问题。
就重新创建以下文件以及连接后,再次重启,问题解决。
install -dv /lib/{firmware,udev/devices/{pts,shm}}
mknod -m0666 /lib/udev/devices/null c 1 3
ln -sv /proc/self/fd /lib/udev/devices/fd
ln -sv /proc/self/fd/0 /lib/udev/devices/stdin
ln -sv /proc/self/fd/1 /lib/udev/devices/stdout
ln -sv /proc/self/fd/2 /lib/udev/devices/stderr
ln -sv /proc/kcore /lib/udev/devices/core
  gzl1100 当前离线   回复时引用此帖
发表新主题 回复


主题工具

发帖规则
您 [不可以] 发表新主题
您 [不可以] 回复主题
您 [不可以] 上传附件
您 [不可以] 编辑您的帖子

已 [启用] BB 代码
已 [启用] 表情符号
已 [启用] IMG 代码
已 [禁用] HTML 代码
[论坛跳转…]


所有时间均为[北京时间]。现在的时间是 03:48


Powered by vBulletin 版本 3.6.8
版权所有 ©2000 - 2012, Jelsoft Enterprises Ltd.
官方中文技术支持: vBulletin 中文
版权所有 ©2002 - 2011, LinuxSir.Org