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
Solved

How to bypass manual fsck at startup?

Posted on 2002-03-09
7
1,564 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
  • 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
Three Reasons Why Backup is Strategic

Backup is strategic to your business because your data is strategic to your business. Without backup, your business will fail. This white paper explains why it is vital for you to design and immediately execute a backup strategy to protect 100 percent of your data.

 
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

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

You ever wonder how to backup Linux system files just like Windows System Restore?  Well you can use Timeshift in Linux to perform those similar action.  This tutorial will show you how to backup your system files and keep regular intervals. Note…
The purpose of this article is to fix the unknown display problem in Linux Mint operating system. After installing the OS if you see Display monitor is not recognized then we can install "MESA" utilities to fix this problem or we can install additio…
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.:
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…

828 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