ITPub博客

首页 > Linux操作系统 > Linux操作系统 > fstab文件错误导致系统无法启动

fstab文件错误导致系统无法启动

原创 Linux操作系统 作者:studywell 时间:2015-08-11 17:32:21 0 删除 编辑

fstab文件错误导致系统无法启动
如由于分区表/etc/fstab中的磁盘不存在,导致系统无法启动,可如下处理
正常启动系统,在系统提示输入root密码后,进入修复模式,此时fstab文件为只读模式;
先退出vi,直接在命令行输入下面命令就可顺利编辑保存vi操作了.
#mount -o remount,rw /      注意逗号之间没有空格
如此就可修改fstab文件了。
可将需要修改的磁盘分区那一行删除或者将最后一列值修改为0;

错误原图如下,由于设置/dev/sdb1自动挂载,且检查,后操作将该分区删掉,导致启动失败;



附: $mount -o remount  解释
    Note  that the filesystem mount options will remain the same as those on the original
              mount  point,  and  cannot  be  changed  by  passing  the  -o   option   along   with
              --bind/--rbind.  The  mount options can be changed by a separate remount command, for
              example:

                     mount --bind olddir newdir
                     mount -o remount,ro newdir

来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/29519108/viewspace-1768490/ ,如需转载,请注明出处,否则将追究法律责任。

下一篇: linux添加swap分区
请登录后发表评论 登录
全部评论

注册时间:2014-03-04

  • 博文量
    307
  • 访问量
    535501