Linux

美分 5.5重讀___-僅___F我是y__時間___R和一種d−這nl是F一世l和s是s噸和米Read-only file system重啟後的問題

  • August 23, 2014

我在 centos 5.5 下有一個虛擬伺服器(由一家名為sakura的日本公司託管)

從昨天開始,無法通過 ssh 建立連接。我已經聯繫了支持中心,他們告訴我從控制面板重新啟動 VS。重新啟動後,我收到以下消息

Connected to domain wwwxxxxxx.sakura.ne.jp                                     
Escape character is ^]                                                          

[  OK  ]                                                                        
Setting hostname localhost.localdomain:  [  OK  ]                               

Setting up Logical Volume Management:   No volume groups found                  
[  OK  ]                                                                        

Checking filesystems                                                            
Checking all file systems.                                                      

[/sbin/fsck.ext4 (1) -- /] fsck.ext4 -a /dev/vda3                               
/ contains a file system with errors, check forced.                             

/: Inodes that were part of a corrupted orphan linked list found.               


/: UNEXPECTED INCONSISTENCY; RUN fsck MANUALLY.                                 
       (i.e., without -a or -p options)                                        

@@cat: /proc/self/attr/current: Invalid argument                                
               Welcome to CentOS                                               

Starting udev: @[  OK  ]                                                        
Setting hostname localhost.localdomain:  [  OK  ]                               

Setting up Logical Volume Management:   No volume groups found                  
[  OK  ]                                                                        

Checking filesystems                                                            
Checking all file systems.                                                      

[/sbin/fsck.ext4 (1) -- /] fsck.ext4 -a /dev/vda3                               
/ contains a file system with errors, check forced.                             

/: Inodes that were part of a corrupted orphan linked list found.               


/: UNEXPECTED INCONSISTENCY; RUN fsck MANUALLY.                                 
       (i.e., without -a or -p options)                                        

[FAILED]                                                                        


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

*** when you leave the shell.                                                   
*** Warning -- SELinux is active                                                

*** Disabling security enforcement for system recovery.                         
*** Run 'setenforce 1' to reenable.                                             

/etc/rc.d/rc.sysinit: line 53: /selinux/enforce: Read-only file system          
Give root password for maintenance                                              

(or type Control-D to continue):                                                
bash: cannot set terminal process group (-1): Inappropriate ioctl for device    

bash: no job control in this shell                                              
bash: cannot create temp file for here-document: Read-only file system          

bash: cannot create temp file for here-document: Read-only file system          
bash: cannot create temp file for here-document: Read-only file system          

bash: cannot create temp file for here-document: Read-only file system          
bash: cannot create temp file for here-document: Read-only file system          

bash: cannot create temp file for here-document: Read-only file system          
bash: cannot create temp file for here-document: Read-only file system          

bash: cannot create temp file for here-document: Read-only file system          
bash: cannot create temp file for here-document: Read-only file system          

bash: cannot create temp file for here-document: Read-only file system          
(Repair filesystem) 1 # setenforce 1                                            

setenforce: SELinux is disabled                                                 
(Repair filesystem) 2 # echo 1  
(Repair filesystem) 4 # /etc/init.d/sshd  status

openssh-daemon is stopped
(Repair filesystem) 5 # /etc/init.d/sshd  start
Starting sshd: NET: Registered protocol family 10

lo: Disabled Privacy Extensions
touch: cannot touch `/var/lock/subsys/sshd': Read-only file system


(Repair filesystem) 6 # sudo /etc/init.d/sshd  start
sudo: sorry, you must have a tty to run sudo

(Repair filesystem) 7 #   

我有 4 個站點在生產中,我需要快速重啟伺服器(SSH + HTTPD,…)。

感謝您的時間。

您在文件系統維護螢幕中。此時,您只需按照提示進行操作即可。

執行手動文件系統檢查:

fsck -y /

完成後,您可以鍵入exit,系統將重新啟動。

引用自:https://serverfault.com/questions/623547