mkdir: cannot create directory `test’: Read-only file system

linux提示为只读Read-only file system,不允许写入或删除,大多是硬盘故障造成的
如果不是很严重的话,fsck一般都能处理,如果是N多坏道的话,建议尽早更换硬盘以免丢失数据

  1. [root@localhost public_html]# mkdir test
  2. mkdir: cannot create directory `test': Read-only file system
  3.  
  4. [root@localhost ~]# umount /home/
  5. umount: /home: device is busy
  6. umount: /home: device is busy
  7.  
  8. [root@localhost ~]# fuser -m /dev/sda3
  9. /dev/sda3:           11334
  10.  
  11. [root@localhost ~]# ps auxww|grep 11334
  12. apache   11334  0.0  0.3  14288  6404 ?        S    09:47   0:00 /usr/sbin/httpd -k start -DSSL
  13. root     12184  0.0  0.0   4128   684 pts/0    R+   09:50   0:00 grep 11334
  14.  
  15. [root@localhost ~]# service httpd stop
  16. Stopping httpd: [  OK  ]
  17. [root@localhost ~]# umount /home/
  18.  
  19. [root@localhost ~]# fsck -V -a /dev/sda3
  20. fsck 1.39 (29-May-2006)
  21. [/sbin/fsck.ext3 (1) -- /home] fsck.ext3 -a /dev/sda3
  22. /home: recovering journal
  23. /home: clean, 1890281/20971520 files, 6941812/20970849 blocks
1 1