You know how if you do an improper shutdown and then boot up, the server prompts you to run a file system check if you press "Y" within 5 seconds? Well, this is great but sometimes not practical in remote access situations when we call our datacenter to say reboot a hang server and they have no monitor or keyboard hooked up to the system. Is there a way to have the system forced to automatically fo the filesystem check every time it boots up, if there's a need for it, ie: WITHOUT hitting "Y"?
I couldn't find the answer to this one in docs or FAQs. If I missed it, a simple pointer to the source would be of great help.
Thank you,
Chris
On Wed, Apr 06, 2005 at 10:11:55AM -0700, centos.org_list@000a.com enlightened us:
know how if you do an improper shutdown and then boot up, the server prompts you to run a file system check if you press "Y" within 5 seconds? Well, this is great but sometimes not practical in remote access situations when we call our datacenter to say reboot a hang server and they have no monitor or keyboard hooked up to the system. Is there a way to have the system forced to automatically fo the filesystem check every time it boots up, if there's a need for it, ie: WITHOUT hitting "Y"?
I couldn't find the answer to this one in docs or FAQs. If I missed it, a simple pointer to the source would be of great help.
From rc.sysinit on my RHEL3 box, it looks like you can create /etc/sysconfig/autofsck. There is an AUTOFSCK_DEF_CHECK that can be set to yes to force the check and PROMPT can be set to no to skip the prompt.
All of this only happens when /.autofsck exists on the filesystem. /etc/init.d/halt removes this file when shut down properly.
Matt
centos.org_list@000a.com wrote:
You know how if you do an improper shutdown and then boot up, the server prompts you to run a file system check if you press "Y" within 5 seconds? Well, this is great but sometimes not practical in remote access situations when we call our datacenter to say reboot a hang server and they have no monitor or keyboard hooked up to the system. Is there a way to have the system forced to automatically fo the filesystem check every time it boots up, if there's a need for it, ie: WITHOUT hitting "Y"?
I couldn't find the answer to this one in docs or FAQs. If I missed it, a simple pointer to the source would be of great help.
Thank you,
Chris
CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos
.
You create the following file:
/etc/sysconfig/autofsck
and place the following in it:
AUTOFSCK_TIMEOUT=5 AUTOFSCK_DEF_CHECK=yes
On Wed, 2005-04-06 at 22:22 -0500, Chris Weisiger wrote:
centos.org_list@000a.com wrote:
You know how if you do an improper shutdown and then boot up, the server prompts you to run a file system check if you press "Y" within 5 seconds? Well, this is great but sometimes not practical in remote access situations when we call our datacenter to say reboot a hang server and they have no monitor or keyboard hooked up to the system. Is there a way to have the system forced to automatically fo the filesystem check every time it boots up, if there's a need for it, ie: WITHOUT hitting "Y"?
I couldn't find the answer to this one in docs or FAQs. If I missed it, a simple pointer to the source would be of great help.
Thank you,
Chris
CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos
.
You create the following file:
/etc/sysconfig/autofsck
and place the following in it:
AUTOFSCK_TIMEOUT=5 AUTOFSCK_DEF_CHECK=yes
---- or
shutdown now -Fr
Craig
You know how if you do an improper shutdown and then boot up, the server prompts you to run a file system check if you press "Y" within 5 seconds? Well, this is great but sometimes not practical in remote access situations when we call our datacenter to say reboot a hang server and they have no monitor or keyboard hooked up to the system. Is there a way to have the system forced to automatically fo the filesystem check every time it boots up, if there's a need for it, ie: WITHOUT hitting "Y"?
I couldn't find the answer to this one in docs or FAQs. If I missed it, a simple pointer to the source would be of great help.
Thank you,
Chris
You create the following file:
/etc/sysconfig/autofsck
and place the following in it:
AUTOFSCK_TIMEOUT=5 AUTOFSCK_DEF_CHECK=yes
Chris and all - Thank you! That is exactly what I was hoping to find. Much appreciated!
Chris
centos.org_list@000a.com wrote:
You know how if you do an improper shutdown and then boot up, the server prompts you to run a file system check if you press "Y" within 5 seconds? Well, this is great but sometimes not practical in remote access situations when we call our datacenter to say reboot a hang server and they have no monitor or keyboard hooked up to the system. Is there a way to have the system forced to automatically fo the filesystem check every time it boots up, if there's a need for it, ie: WITHOUT hitting "Y"?
I couldn't find the answer to this one in docs or FAQs. If I missed it, a simple pointer to the source would be of great help.
Thank you,
Chris
You create the following file:
/etc/sysconfig/autofsck
and place the following in it:
AUTOFSCK_TIMEOUT=5 AUTOFSCK_DEF_CHECK=yes
Chris and all - Thank you! That is exactly what I was hoping to find. Much appreciated!
Chris
CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos
This is how i have my system checked, even though it is sitting next to my desktop system, i dont have a monitor, keyboard or mouse hooked to it.. i connect to it only by ssh
glad i could help
-----Original Message----- From: centos-bounces@centos.org [mailto:centos-bounces@centos.org] On Behalf Of Chris Weisiger Sent: Wednesday, April 06, 2005 10:22 PM To: CentOS mailing list Subject: Re: [CentOS] Automatic disk check
centos.org_list@000a.com wrote:
You know how if you do an improper shutdown and then boot up, the server prompts you to run a file system check if you press "Y" within 5 seconds? Well, this is great but sometimes not practical in remote access situations when we call our datacenter to say reboot a hang server and they have no monitor or keyboard hooked up to the system. Is there a way to have the system forced to automatically fo the filesystem check every time it boots up, if there's a need for it, ie: WITHOUT hitting "Y"?
I couldn't find the answer to this one in docs or FAQs. If I missed it, a simple pointer to the source would be of great help.
Thank you,
Chris
.
You create the following file:
/etc/sysconfig/autofsck
and place the following in it:
AUTOFSCK_TIMEOUT=5 AUTOFSCK_DEF_CHECK=yes
If a problem is encountered during the fsck, will the system automagically fix it?
Mike
On Thu, Apr 07, 2005 at 07:30:20AM -0500, Mike Kercher enlightened us:
If a problem is encountered during the fsck, will the system automagically fix it?
By default, it doesn't appear to. However, it does get additional options from the /fsckoptions file, so you could give it the -p there to automatically fix problems. That can be dangerous, though...I've had entire filesystems end up in lost+found doing that :-)
Matt
Matt Hyclak wrote:
On Thu, Apr 07, 2005 at 07:30:20AM -0500, Mike Kercher enlightened us:
If a problem is encountered during the fsck, will the system automagically fix it?
By default, it doesn't appear to. However, it does get additional options from the /fsckoptions file, so you could give it the -p there to automatically fix problems. That can be dangerous, though...I've had entire filesystems end up in lost+found doing that :-)
While that's true (you can lose data), most people when confronted with the "should I correct this?" dialog during fsck simply hit "yes" anyway. I've been using Linux since the early 90's and unix since the mid-80's and still find the output of fsck to be somewhat cryptic.
If you want the machine to come up in an automated fashion (a headless system) then I don't really see any other way of accomplishing this. Personally, when I have a machine that's wedged or doesn't survive a reboot, I consider that a cue to visit (or send someone else to visit) the datacenter to find out why. Relying on some of the "technicians" I've seen in various datacenters in NYC/LDN/SFO/HK to troubleshoot the system just isn't an option. Troubleshooting generally means repeatedly leaning on the power button until it either recovers by itself or completely melts down. 8-)
Cheers,
C