LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 07-31-2017, 02:08 AM   #1
sameeksha khandelwal
LQ Newbie
 
Registered: Jul 2017
Posts: 4

Rep: Reputation: Disabled
Unhappy fstab got corrupted


hi,

i made changes to fstab file by changing 0 0 to 1 1 that corresponds to backup and fsck dumps.
after rebooting server, it showed that file system mounting failed and i was dropped at root password prompt to repair the file system.
but when I corrected the values, it showed that file is not writable.
Even I am not able to go in single user mode as the system is unable to find the root directory, kindly help on this .
 
Old 07-31-2017, 03:06 AM   #2
HMW
Member
 
Registered: Aug 2013
Location: Sweden
Distribution: Debian, Arch, Red Hat, CentOS
Posts: 773
Blog Entries: 3

Rep: Reputation: 369Reputation: 369Reputation: 369Reputation: 369
Something similar happened to me just recently.

Whilst in the recovery prompt, in order to make changes to fstab, you need to remount the file system to make it writeable:
Code:
mount -o remount,rw /
After that, you can make changes to fstab (probably best to comment out the faulty line) with your editor of choice (Vi, nano) and reboot.

Last edited by HMW; 07-31-2017 at 03:08 AM.
 
2 members found this post helpful.
Old 07-31-2017, 05:15 AM   #3
sameeksha khandelwal
LQ Newbie
 
Registered: Jul 2017
Posts: 4

Original Poster
Rep: Reputation: Disabled
Thanks a bunch HMW, will run this command and get back soon.
 
Old 08-02-2017, 09:46 AM   #4
onebuck
Moderator
 
Registered: Jan 2005
Location: Central Florida 20 minutes from Disney World
Distribution: SlackwareŽ
Posts: 13,925
Blog Entries: 44

Rep: Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159Reputation: 3159
Member response

Hi,

I suggest that whenever you are going to change a configuration file is that you should make a backup copy first. For '/etc/fstab' then 'cp /etc/fstab /etc/masterconfiguration/fstab_bak'. I keep a '/etc/masterconfiguration' directory to keep my original and backup configuration files within in case of emergency.

Hope this helps.
Have fun & enjoy!
 
1 members found this post helpful.
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
help backup server corrupted /etc/fstab mahaila Linux - General 18 08-13-2005 01:02 PM
fstab file corrupted LSEmpyrean Linux - General 2 09-07-2004 11:14 PM
Yet another corrupted /etc/fstab Dag Linux - General 2 06-08-2004 11:17 AM
Corrupted fstab DevlshOne Linux - Newbie 1 01-16-2004 06:57 PM
Corrupted /etc/fstab nxny Linux - General 15 09-01-2003 09:06 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 07:02 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration