Chinaunix首页 | 论坛 | 博客
  • 博客访问: 3298278
  • 博文数量: 258
  • 博客积分: 9440
  • 博客等级: 少将
  • 技术积分: 6998
  • 用 户 组: 普通用户
  • 注册时间: 2009-05-03 10:28
个人简介

-- linux爱好者,业余时间热衷于分析linux内核源码 -- 目前主要研究云计算和虚拟化相关的技术,主要包括libvirt/qemu,openstack,opennebula架构和源码分析。 -- 第五届云计算大会演讲嘉宾 微博:@Marshal-Liu

文章分类

全部博文(258)

文章存档

2016年(1)

2015年(4)

2014年(16)

2013年(22)

2012年(41)

2011年(59)

2010年(40)

2009年(75)

分类: LINUX

2012-06-12 10:01:45

第一种情况:非正常关机引起的磁盘分区问题 不能正常进入系统

如下问题一般是如何引起和应该怎么样解决呢?
Finding module dependencies;
modprobe:modprobe:can't locate module block-major-3
fsck.ext3Possibly non-existent or swap device?
such device or address while trying to open /dev/hdb1
/boot: clena, 41/26104 files. 12679/104391 blocks[FAILED]

 

*** AN error occurred during the file system check
*** Dropping you to a shell; the systm will reboot

*** when you leave the shell
Give root password for maintenance

(or type Control-D to continue):

Login incorrect.
(Repair filesystem) 1 #

 

非正常关机引起的,用fsck /dev/hdaX后reboot进入,或只用fsck来修复,只管y回车

 

第二种情况:由于/etc/fstab文件编辑错误 而引起的不能正常进入系统

解决方法就是修改/etc/fstab文件成原来正常格式 删除错误的或者是不存在的挂载目录,本来是/dev/vda1,/dev/vda2两个分区,竟然被修改成了/dev/xvda1,/dev/xvda2 。

操作:根据提示进入修复模式 Login incorrect.

(Repair filesystem) 1 # vim /etc/fstab
但是修复模式下(read-only system) 文件是被保护的不能修改 运行下面命令 把系统文件权限改成可读写(rw)

(Repair filesystem) 1 # mount -o remount,rw /
使根目录可写.即可以修复/etc/fstab文件,使之可写.然后就可以vi修改了
保存 wq

(Repair filesystem) 1 #reboot

阅读(6940) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~