V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
Distributions
Ubuntu
Fedora
CentOS
中文资源站
网易开源镜像站
ImHabit
V2EX  ›  Linux

/dev/sda*,无法 mount

  •  
  •   ImHabit · 2018-01-18 10:16:53 +08:00 · 2692 次点击
    这是一个创建于 2283 天前的主题,其中的信息可能已经有所发展或是发生改变。

    命令执行和返回结果如下:

    # mount /dev/sda7 /mnt
    -> mount: /dev/sda7 is write-protected, mounting read-only
    -> mount: cannot mount /dev/sda7 read-only
    
    # mount -o remount /dev/sda7 /mnt
    -> mount: cannot mount /dev/sda7 read-write, is write-protected
    
    # mount -o ro /dev/sda7 /mnt
    -> mount: cannot mount /dev/sda7 read-only
    

    (sda7 为未挂载设备,sda*同 sda7,修改 /etc/fstab 可正常挂载)

    如何检查?

    第 1 条附言  ·  2018-01-18 16:18:45 +08:00
    系统因业务需要,开启强制访问控制( SeLinux ),且不允许关闭。因无法关闭,问问强防控制策略能否管控设备 mount 权限,是不是有受强防控制策略影响的可能。
    第 2 条附言  ·  2018-01-18 16:38:12 +08:00
    已确认为 SeLinux 策略配置导致。
    cnhongwei
        1
    cnhongwei  
       2018-01-18 11:34:14 +08:00
    先根据分区类型,使用对应 fsck 检查文件系统有没有问题。
    designer
        2
    designer  
       2018-01-18 11:55:03 +08:00 via iPhone
    dev 盘符出不来 sda 这个 U 盘 有解决方案吗
    gesse
        3
    gesse  
       2018-01-18 12:12:11 +08:00
    有时候是硬件故障, 软件无法解决
    Beebird
        4
    Beebird  
       2018-01-18 15:38:16 +08:00
    “修改 /etc/fstab 可正常挂载” 这句是什么意思?怎么修改的?
    ImHabit
        5
    ImHabit  
    OP
       2018-01-18 16:10:25 +08:00
    @Beebird 修改 /etc/fstab,重启系统,或者使用 mount -a 可以将设备挂载上
    ImHabit
        6
    ImHabit  
    OP
       2018-01-18 16:10:58 +08:00
    @cnhongwei 文件系统没有问题。
    Beebird
        7
    Beebird  
       2018-01-18 16:14:15 +08:00
    @ImHabit 那有可能是参数不对, /etc/fstab 对应 /dev/sda7 的那行贴出来看看?
    defunct9
        8
    defunct9  
       2018-01-18 16:38:54 +08:00
    开 ssh,我上去看看
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   931 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 25ms · UTC 20:29 · PVG 04:29 · LAX 13:29 · JFK 16:29
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.