Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751267AbVJPAKk (ORCPT ); Sat, 15 Oct 2005 20:10:40 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1751268AbVJPAKk (ORCPT ); Sat, 15 Oct 2005 20:10:40 -0400 Received: from mailgw.cvut.cz ([147.32.3.235]:54679 "EHLO mailgw.cvut.cz") by vger.kernel.org with ESMTP id S1751267AbVJPAKk (ORCPT ); Sat, 15 Oct 2005 20:10:40 -0400 Message-ID: <43519A77.2040806@vc.cvut.cz> Date: Sun, 16 Oct 2005 02:10:31 +0200 From: Petr Vandrovec User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.12) Gecko/20051007 Debian/1.7.12-1 X-Accept-Language: en MIME-Version: 1.0 To: Anton Altaparmakov CC: Coywolf Qi Hunt , Lee Revell , Marc Perkel , linux-kernel@vger.kernel.org Subject: Re: Forcing an immediate reboot References: <43505F86.1050701@perkel.com> <1129341050.23895.12.camel@mindpipe> <2cd57c900510150056j2a6af6e5gf93ce9fa4ef16aac@mail.gmail.com> In-Reply-To: Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1403 Lines: 34 Anton Altaparmakov wrote: > On Sat, 15 Oct 2005, Coywolf Qi Hunt wrote: > >>On 10/15/05, Anton Altaparmakov wrote: >> >>>echo s > /proc/sysrq-trigger >>>echo u > /proc/sysre-trigger >>>echo s > /proc/sysrq-trigger >> >>What the purpose of the second sync? > > > Allows any i/o initiated between the first sync and the remount r/o to > complete. Remember that r/o mounting doesn't stop i/o. It only stops you > from writing to the fs at the vfs layer. Once a write/modification has > entered the fs driver it will get written no matter what, unless the > "reboot" sysrq is triggered in which case the kernel just reboots > immediately. > > Maybe it is just paranoia on my part but I have gotten used to hitting > Alt+PrtScr+S, +U, +S, +B so I do it automatically. Second sync is a must, otherwise remounting read-only is not written to the filesystem (at least in my case) so no fsck is saved. But you can save first sync (before remount), and then you get nice sequence which even admins comming from Windows can remember - they have to use USB to safely reboot their Linux systems ;-) (alt-sysrq-U, S, B) Petr - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/