FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Ubuntu > Ubuntu User

 
 
LinkBack Thread Tools
 
Old 09-07-2012, 01:59 PM
Liam Proven
 
Default fsck on mounted system?

On 7 September 2012 14:30, Dave Howorth <dhoworth@mrc-lmb.cam.ac.uk> wrote:
> Liam Proven wrote:
>> On 7 September 2012 11:26, oxy <oxyopes@googlemail.com> wrote:
>>>> sudo touch /forcefsck
>>>>
>>>> and then the filesystem should be checked at the next reboot.
>>>
>>> is there a way to force fsck on shutdown?
>>
>> No, not AFAIK, because the system would have to drop from a multituser
>> runlevel down to single-user in order that the filesystems could be
>> remounted read-only.
>
> That could be done of course,

Yes, you are quite right. Non-trivial, though, and liable to cause
questions to be asked of a user who will not be able to answer them.

> but at shutdown, the system is also in its
> 'most likely to be corrupt' state. Not the ideal time to run some
> self-checking code.

Not 100% convinced of that, but OTOH, what we have works, so by the
KISS principle I am inclined to leave it well alone.

> It would be better to let the system shut down,
> reboot so it's in a completely known state, then run fsck and shut down
> again.



--
Liam Proven • Profile: http://lproven.livejournal.com/profile
Email: lproven@cix.co.uk • GMail/G+/Twitter/Flickr/Facebook: lproven
MSN: lproven@hotmail.com • Skype/AIM/Yahoo/LinkedIn: liamproven
Tel: +44 20-8685-0498 • Cell: +44 7939-087884

--
ubuntu-users mailing list
ubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
 
Old 09-07-2012, 03:17 PM
Avi Greenbury
 
Default fsck on mounted system?

Liam Proven wrote:
> On 7 September 2012 14:30, Dave Howorth <dhoworth@mrc-lmb.cam.ac.uk>
> wrote:
> > Liam Proven wrote:
> >> On 7 September 2012 11:26, oxy <oxyopes@googlemail.com> wrote:
> >>>> sudo touch /forcefsck
> >>>>
> >>>> and then the filesystem should be checked at the next reboot.
> >>>
> >>> is there a way to force fsck on shutdown?
> >>
> >> No, not AFAIK, because the system would have to drop from a
> >> multituser runlevel down to single-user in order that the
> >> filesystems could be remounted read-only.
> >
> > That could be done of course,
>
> Yes, you are quite right. Non-trivial, though, and liable to cause
> questions to be asked of a user who will not be able to answer them.

This is hardly different to a boot-time check, though. Perhaps it could
do a check-without-repair, then prompt with questions on next boot?

> > but at shutdown, the system is also in its
> > 'most likely to be corrupt' state. Not the ideal time to run some
> > self-checking code.
>
> Not 100% convinced of that, but OTOH, what we have works, so by the
> KISS principle I am inclined to leave it well alone.

I don't think it does. I've never booted up a computer intending to not
use it until it's had time to fsck its disks. I don't recall the last
time any of my workstations got to the natural end of an automatic fsck
and I'd be surprised if I wasn't in at least a substantial minority.

--
Avi

--
ubuntu-users mailing list
ubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
 
Old 09-07-2012, 03:24 PM
Liam Proven
 
Default fsck on mounted system?

On 7 September 2012 16:17, Avi Greenbury <lists@avi.co> wrote:
> Liam Proven wrote:
>> On 7 September 2012 14:30, Dave Howorth <dhoworth@mrc-lmb.cam.ac.uk>
>> wrote:
>> > Liam Proven wrote:
>> >> On 7 September 2012 11:26, oxy <oxyopes@googlemail.com> wrote:
>> >>>> sudo touch /forcefsck
>> >>>>
>> >>>> and then the filesystem should be checked at the next reboot.
>> >>>
>> >>> is there a way to force fsck on shutdown?
>> >>
>> >> No, not AFAIK, because the system would have to drop from a
>> >> multituser runlevel down to single-user in order that the
>> >> filesystems could be remounted read-only.
>> >
>> > That could be done of course,
>>
>> Yes, you are quite right. Non-trivial, though, and liable to cause
>> questions to be asked of a user who will not be able to answer them.
>
> This is hardly different to a boot-time check, though.

Not massively, no, but hey, someone asked.

> Perhaps it could
> do a check-without-repair, then prompt with questions on next boot?

It could, but what's the point?

>> > but at shutdown, the system is also in its
>> > 'most likely to be corrupt' state. Not the ideal time to run some
>> > self-checking code.
>>
>> Not 100% convinced of that, but OTOH, what we have works, so by the
>> KISS principle I am inclined to leave it well alone.
>
> I don't think it does. I've never booted up a computer intending to not
> use it until it's had time to fsck its disks.

I am afraid I can't follow this sentence. Too many nested negatives.

> I don't recall the last
> time any of my workstations got to the natural end of an automatic fsck

I generally let them do it unless I'm in a hurry. Occasionally, if I
have had an abend, I schedule one myself with the forcefsck file - one
on / and one on /home.

> and I'd be surprised if I wasn't in at least a substantial minority.

I fear you are probably right.

I was amazed to discover, a few years ago, how many Windows techies
don't know how to do a CHKDSK and who *never* routinely do one. I
think it's a brilliant idea that Linux schedules one periodically.

--
Liam Proven • Profile: http://lproven.livejournal.com/profile
Email: lproven@cix.co.uk • GMail/G+/Twitter/Flickr/Facebook: lproven
MSN: lproven@hotmail.com • Skype/AIM/Yahoo/LinkedIn: liamproven
Tel: +44 20-8685-0498 • Cell: +44 7939-087884

--
ubuntu-users mailing list
ubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
 
Old 09-07-2012, 11:31 PM
NoOp
 
Default fsck on mounted system?

On 09/07/2012 02:38 AM, oxy wrote:
> Hi,
>
> it is nowadays common to have a big partition in your system with
> almost everything. When you have some energy blackouts and
> want to check for the integrity of your discs, how do you do it?
>
> thx...
>

Just so that you don't think you are alone, you may find these of
interest... pros and cons:
(Note: I can't recommend any as I've not tried them)

<https://wiki.ubuntu.com/AutoFsck>
<https://blueprints.launchpad.net/ubuntu/+spec/prompt-for-fsck-on-shutdown>
(code hasn't been updated since 2008)
2006:
<http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=393312>
[[Pkg-sysvinit-devel] Bug#393312: fsck should run at shutdown, not
startup, when possible]
<http://brainstorm.ubuntu.com/idea/11021/>
[Idea #11021: fsck always in the shutdown not during boot (AutoFsck) ]


--
ubuntu-users mailing list
ubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
 
Old 09-08-2012, 08:09 PM
Colin Law
 
Default fsck on mounted system?

On 7 September 2012 11:26, oxy <oxyopes@googlemail.com> wrote:
>>
>> sudo touch /forcefsck
>>
>> and then the filesystem should be checked at the next reboot.
>>
>
>
> is there a way to force fsck on shutdown?

Yes, with a little manual intervention. In a terminal run
sudo touch /forcefsck
then initiate a shutdown. Watch carefully and when the power light
goes out immediately press the power button, a filesystem check will
be initiated soon after.

Colin

--
ubuntu-users mailing list
ubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
 
Old 09-09-2012, 12:51 PM
Liam Proven
 
Default fsck on mounted system?

On 8 September 2012 21:09, Colin Law <clanlaw@googlemail.com> wrote:
>
> Yes, with a little manual intervention. In a terminal run
> sudo touch /forcefsck
> then initiate a shutdown. Watch carefully and when the power light
> goes out immediately press the power button, a filesystem check will
> be initiated soon after.

:¬D


--
Liam Proven • Profile: http://lproven.livejournal.com/profile
Email: lproven@cix.co.uk • GMail/G+/Twitter/Flickr/Facebook: lproven
MSN: lproven@hotmail.com • Skype/AIM/Yahoo/LinkedIn: liamproven
Tel: +44 20-8685-0498 • Cell: +44 7939-087884

--
ubuntu-users mailing list
ubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
 

Thread Tools




All times are GMT. The time now is 08:53 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org