Solved

How to bypass manual fsck at startup?

Posted on 2002-03-09
7
1,571 Views
Last Modified: 2008-01-09

Dear Experts,

When electiricty goes off on my linux box, it usually needs manual intervention to run fsck at startup once electricity is back up.

If there is a way, how can I make it boot normally everytime without running fsck manually and requiring the root password to do so?  My problem is that I am not always available when such a thing happens and I would like to linux to start back up as normally as possible in case of electricity outage and restoration so that it provides the necessary routing and Internet connectivity it is supposed to serve.

Many thanks in advance for your help and experience.
0
Comment
Question by:u1
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
  • 2
  • +1
7 Comments
 
LVL 3

Expert Comment

by:tdaoud
ID: 6854190

One thing you can try is to

touch /etc/fastboot

Having that file there will make it bypass fsck checking at startup.

Tarik
0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 6854280
if the system goes down unexpected/unattened, the filesystem is corrupted, or as fsck says: dirty.

You need to run fsck, otherwise you will loose data, probably not what you want.

To prewent data loss, I can think of following solutions:
  1. use a journaling filesystem, like ext3, reiserfs, xfs, etc.
  2. run a cron which periodicala (every minute) syncs the disks using the sync command
     (but this will not always prewent fsck)

0
 

Author Comment

by:u1
ID: 6854579

ahoffmann,

ofcourse I don't like to loose data, but soemtimes not interrupting the service is very important.  My linux box is mainly for routing and web server.

I have redhat 7.1 and will be upgrading to redhat 7.2 soon when I get the time.

I have been reading about the new journaling filesystem like ext3.

My question is can you convert an existing ext2 partition to ext3 or you would need to create new ones and copy data from one to another and so forth?
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 3

Accepted Solution

by:
tdaoud earned 200 total points
ID: 6854667

If you'd like to upgrade to redhat 7.2 I suggest that you format a new hard disk with ext3 from scratch, it maybe a good way to upgrade and start using ext3.

Otherwise you can upgrade to redhat 7.2 then you need to create the journal file on each partition/filesystem using the command tune2fs (this can be done on mounted or unmounted filesystems).  Example of the command

tune2fs -j /dec/hdxx

Then you simply need to change the filesystem type in the /etc/fstab file from ext2 to ext3.

The good thing about ext3 is its compatiblity with ext2 and the ability to switch between both types at any time. Even old kernels see ext3 filesystems as ext2 and access it as normal as a simple ext2 filesystem.

Hope this helps

Tarik
0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 6854887
tdaoud said it all about ext3 :)
0
 
LVL 4

Expert Comment

by:newmang
ID: 6855058
Slightly off-topic but have you considered a small UPS equipped with software to gracefully shut down your system in the event of a power failure?
0
 

Author Comment

by:u1
ID: 6858508

Actually I do have an old UPS that has no serial/software conection to linux.  I was already thinking toward that direction too.  But sometimes (it happened twice) we get electricity problems that even put the UPS out instantly.

I will be using tdaoud's /etc/fastboot suggestion until I upgrade to redhat 7.2 and use ext3.

Thanks for all your suggestions.
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
LogmeIn using Linux Ubuntu 16.04 6 171
python - find anything after $ question. 9 84
Centos 7 DNS server not replying to clients 3 93
http response code 3 35
Introduction We as admins face situation where we need to redirect websites to another. This may be required as a part of an upgrade keeping the old URL but website should be served from new URL. This document would brief you on different ways ca…
Google Drive is extremely cheap offsite storage, and it's even possible to get extra storage for free for two years.  You can use the free account 15GB, and if you have an Android device..when you install Google Drive for the first time it will give…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
Suggested Courses

739 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