Re: No fsck in battery mode
According to firstname.lastname@example.org,
> On Mon, Sep 01, 2003 at 10:04:33AM +0200, Harry Brueckner wrote:
> > Hello,
> > is there a way to avoid the regular fsck run (every n mounts or after m
> > days) when the laptop is in battery mode?
> > I think its quite a waste of battery power for the fsck run and
> > rescheduling for the next reboot (with powersupply available) would be very
> > nice. :-)
> > Any idea how to get around the fsck run?
> > TIA for any ideas,
> > Harry
> If you use ext2, you can try `tune2fs -c 0 -i 3m`
I like the idea of changing the interval, but I don't (as
others have also said) like your idea of disabling it.
So this is what I just made for my laptop:
: PARTS="/dev/hda1 /dev/hda2 /dev/hda6"
: if /usr/bin/on_ac_power
: for PART in $PARTS
: tune2fs -c $FSCK_MOUNTS -i $FSCK_INTERVAL $PART
( this file also has hdparm control in it to make the drive
sleep more when on batteries, but that is not to the point,
so I omitted those refs )
The reason I like this approach is that it makes the fsck
happen when on AC but unlikely when on DC. But it doesn't
disable the fsck entirely.
Anyone have a reason why it would be bad to run tune2fs this
way at every reboot?