Solved

CentOs disk repair

Posted on 2013-11-17
10
474 Views
Last Modified: 2013-12-02
My CentOS server was acting odd so I rebooted it.  During the boot it said

contains a file system with errors.  Check forced.  Then is says an error occurred during the file system check.  Dropping to a shell:  Give the root password for maintenance.

After putting in my root password I typed ‘fsck -a’ and hit enter.  A few lines cam up saying ‘Inode XXXXXXX was part of the orphaned in ode list. FIXED..  It seems to be running still.. Do I let it run and eventually it will ask me to reboot?

What do I do next?
0
Comment
Question by:gopher_49
10 Comments
 
LVL 19

Accepted Solution

by:
bevhost earned 500 total points
ID: 39655658
Yes, let it finish running.  It may complete ok, it may find problems that need you to do something.  Depending on the size of the disk / number of files etc it may take a while.
0
 

Author Comment

by:gopher_49
ID: 39655666
It finished and everything seems okay... I went ahead and restored my VM files to a temp drive.. And.. Got a few app level backups ready just in case something bad happens.  I have the VM on an iSCSI volume to the datacenter let me use temporarily.  I'm wondering if their iSCSI taget has issues for I've been running this VM for 2 years and never had an issue until moved it to their iSCSI target.  I'll keep an eye on it and update the ticket tomorrow.
0
 
LVL 61

Expert Comment

by:gheist
ID: 39656396
You can always have log for iscsi volume on better volume if in doubt about iscsi's quality. Then it will be log replay and no lengthy fsck in case network disappears.
0
 
LVL 6

Expert Comment

by:xeroxzerox
ID: 39658430
When ctrl+ D option show enter root password if it's not taking password then insert bootable cd of your os..and go to rescue mode...

OR

You can troubleshoot it in SINGLE USER MODE ...when you login in single user mode then
Go to
#vi /etc/fstab

Go to / line & change 0 0 last number in this line... {it show you like- 1 2 or 2 1 or 2 2 then change it to 0 0}
(change all mounting device )
save the file and restart your system..
0
 

Author Comment

by:gopher_49
ID: 39689083
I don't think it finished last time it ran.. I rebooted thinking it was hanging.  What are the correct steps to run 'fsck -a' and/or the process to detect and repair.  Don't I have to unmount the disk first?  I have a feeling if I reboot the server it will do what it did in the past...  This being to run 'fsck -a'..  But.. How do I manually run it?
0
Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

 
LVL 61

Expert Comment

by:gheist
ID: 39689238
You add boot parameter "single" near the end of kernel line

Usually you get to boot parameter editor by pressing up/dpwn when it tries to boot even if you have timeout 0
Then automatic fsck processes / filesystem and you an manually check the rest...
0
 

Author Comment

by:gopher_49
ID: 39690214
So.. I press up/down during the boot process.  Then...  What's the next step?
0
 

Author Comment

by:gopher_49
ID: 39690417
Please see attached screenshot.  Is this normal?  Do I just wait?
Screen-Shot-2013-12-02-at-11.33..png
0
 

Author Comment

by:gopher_49
ID: 39690471
nevermind.. I ran it with the -y switch and everything is good now.  I just had to wait longer.
0
 

Author Closing Comment

by:gopher_49
ID: 39690777
The -y switch is the one to use.. Just be patient and let it finish.
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Daily system administration tasks often require administrators to connect remote systems. But allowing these remote systems to accept passwords makes these systems vulnerable to the risk of brute-force password guessing attacks. Furthermore there ar…
I am a long time windows user and for me it is normal to have spaces in directory and file names. Changing to Linux I found myself frustrated when I moved my windows data over to my new Linux computer. The problem occurs when at the command line.…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.

947 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now