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

Re: File check at boot




Quoting Erick Ocrospoma <zipper1790@gmail.com>:

On 21 July 2015 at 10:32, Martin Skjöldebrand <martin@skjoldebrand.eu>
wrote:

Hi,

Mail from desperate user here:

OS: Debian 8.1 Jessie

Scenario: Mail/web server with file corruption. I have I/O errors on a few
blocks which results in regular (daily) server crashes (including kernel
panic) at random times during the day, usually afternoon CET. I need to run
fsck on the disks. I have grub2 installed on the server.

Catch: For some reason there is only one partition - yes I know this is
retarded.
Catch2: This is on virtual hosting provider so I can access the server
through ssh or vnc but not physically

How can I run fsck at boot time while the disks are umounted. Adding
single to the grub linux kernel line fails to actually run fsck as the disk
is mounted when server goes into rescue mode.
I've Googled and (among other suggestions) read about the systemd fsck
service but am not sure this will help or really how to invoke the thing
properly
Adding init=/bin/systemd fsck.mode=force fsck.repair=yes didn't seem to do
much.


Well, common fsck at boot procedure I ever used was:

touch /forcefsck


Thanks for suggestion.
I've tried this but the server is back up in a few seconds, so I am fairly certain it isn't running a fsck at boot time after issuing "reboot".

And the only half helpful suggestion from the hosting was running in single mode from grub, but the disk is mounted at that time. Else to rollback a snapshot of the server which would mean hours of reconfiguration which I am hoping to avoid.

/Martin S
--
*************************************************************************
***         This address is for technical email lists only            ***
***     Please use my primary mail address at the .org domain         ***
***                        in all other matters                       ***
*************************************************************************


Reply to: