PDA

View Full Version : Improper shutdown question...



GreyGoose
1st June 2006, 08:24 PM
Greetings

No modern operating system (Windows, Linux, etc) likes to be shut down improperly which is why you should always shut it down from the start/system menu but what happens when you have multiple power outages, crashes, programs freeze up, etc over a period of weeks or months and you have no other choice but to just shut your computer off at the switch (manually)?.

In cases like this, would it be better to simply hit the "reset" button on the front of your PC or does'nt it matter?.

How do you "gracefully" recover from crashes/freezes/outages without corrupting your OS and ending up with all kinds of errors (ie; kernel panic, bad_geometry, disk error, etc) until it is so screwed up that it is no longer bootable and you have to start all over again with a complete reinstallation?.

Also, is there some way to whip your system back into shape after such crashes or some way of running an integrity check and correcting any/all problems?. I just hating having to do fresh installs every month or so.

Incidentally, I'm using Fedora Core 5 w/Gnome. Thank's for any assistance I can get on this (I really do appreciate it!).

- Regards, GG

dshaw256
1st June 2006, 08:45 PM
Back in the bad old days I believe you'd have to run fsck on your disk system to clean up after a bad shut-down. This would troll through the inodes and get everything back in a consistent state.

My understanding is that with the ext3 file system, this is no longer necessary. The journals help the OS put it all back in shape at the next boot without the need for an extensive sweep.

I've had to do a power-cycle restart on my system a number of times in a row due to an infinite loop in a bad driver under development, and I've not noticed any ill effects. But perhaps others will have different information.

bob
1st June 2006, 09:24 PM
If you can somehow get to a text interface of any kind, typing 'poweroff' will shut it down properly. Otherwise, you gotta do what you gotta do! I've had a couple of times in the last year where the automatic check didn't solve it and a manual fsck was necessary.

centos_x
1st June 2006, 09:31 PM
As for me the journals have done the trick, never had to do a extensive check



For power outages and other power related instances a UPS is not a really expensive item these days. Recomend one with a regulator so power is 99.X% at constant 120/240 depending on where you live.....




This also works
/sbin/shutdown -h now (or specified time in seconds)

jbannon
1st June 2006, 09:38 PM
Or Ctrl-Alt Del and then power off as it recycles the power. I sometimes have to power off at the switch if I log out of X without rebooting as the ATI driver locks out and never had a problem that I couldn't recover either automatically on startup or fsck from runlevel 1 or the rescue disk. Mind you, I'm not on a production machine so downtime doesn't really matter. If it does then I suggest a properly regulated power supply with a UPS as backup.