Re: XFS filesystem corruption

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Am Freitag, 8. März 2013 schrieb Stan Hoeppner:
> If the techs are determined to hard cut power because they don't have
> the time or the knowledge to do a clean shutdown, it may be well worth
> your time/effort to write a script and teach the field techs to execute
> it, before flipping the master switch.  Your simple script would run as
> root, or you'd need to do some sudo foo within, and would contain
> something like:
> 
> #! /bin/sh
> sync
> echo 2 > /proc/sys/vm/drop_caches
> echo "Ready for power down."

mount -o remount,ro /your/mount/point

One can at least try. Maybe some "service stop" commands before that.

But then, if using a script like this, why not just type "halt"?

Heck, Linux kernel / userspace / distro developers prepared safe shutdown 
already, so why not use it?

Another idea:

On Debian Usually on Ctrl-Alt-Delete on a TTY get a shutdown:

# What to do when CTRL-ALT-DEL is pressed.
ca:12345:ctrlaltdel:/sbin/shutdown -t1 -a -r now


Then you plug a keyboard to the server and tell the local admins to just 
press Ctrl-Alt-Del in order to shutdown the server instead of the power 
button.

But heck, even just pressing the power button for a short period of time 
should work. In Debian it does. So you can just tip the power button.

So, I do see not much of a reason to not shutdown the server properly.

Ciao,
-- 
Martin 'Helios' Steigerwald - http://www.Lichtvoll.de
GPG: 03B0 0D6C 0040 0710 4AFA  B82F 991B EAAC A599 84C7

_______________________________________________
xfs mailing list
xfs@xxxxxxxxxxx
http://oss.sgi.com/mailman/listinfo/xfs



[Index of Archives]     [Linux XFS Devel]     [Linux Filesystem Development]     [Filesystem Testing]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux