Re: [Hampshire] Periodic filesystem checks

2009-11-24 Thread Simon Reap
Leo wrote:
 I'm just looking for a way to skip the occasional check at boot, because 
 I don't want to wait ages for the computer boot. A lot of Ctrl-C does 
 the trick but then no disks get mounted so I end up spending just as 
 long mounting them manually as the computer takes checking them!
   

mount -a as root should mount all of the disks which the machine would 
have mounted automatically.

-- 
Please post to: Hampshire@mailman.lug.org.uk
Web Interface: https://mailman.lug.org.uk/mailman/listinfo/hampshire
LUG URL: http://www.hantslug.org.uk
--


Re: [Hampshire] Periodic filesystem checks

2009-11-24 Thread Damian Brasher
Leo wrote:

 Alan Pope wrote:
 2009/7/25 Leo li...@fractal.me.uk:
 On a not entirely unrelated note, when the a file system check starts
 during a boot up, is it possible to skip it? I've tried Ctrl-C but that
 doesn't work.

 Pressing Esc doesn't work for me, it just carries on doing the check.
 Does the ability to skip them have to be enabled somewhere?

If you don't have the resources to live with a file system check, fsck on
boot, then you can edit the 6th field in your /etc/fstab file for partitions
you want to exclude from checking, i.e.

instead of

UUID=69...   /var   ext3   defaults   0 1

use

UUID=69...   /var   ext3   defaults   0 0

but note that even if you use a command like:

]#sudo shutdown -rF now

this won't force a disk check, for this partition, on reboot. This is true
for my Debian 5.0 dev. box.

Damian

-- 
WWW http://www.diaser.org.uk - Open Source Data Vault Application - beta-1

RSS http://sourceforge.net/export/rss2_projnews.php?group_id=258272

Blog http://interlinux.co.uk/wordpress


-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.


-- 
Please post to: Hampshire@mailman.lug.org.uk
Web Interface: https://mailman.lug.org.uk/mailman/listinfo/hampshire
LUG URL: http://www.hantslug.org.uk
--


Re: [Hampshire] Periodic filesystem checks

2009-11-24 Thread Hugo Mills
On Mon, Nov 23, 2009 at 07:55:59PM +, Leo wrote:
 Keith Edmunds wrote:
  I put this command together to find out whether the checks would run if
  the system were rebooted. It isn't perfect - patches welcome! - but it
  does the job.
  
  for a in $(fdisk -l 2/dev/null|grep -v Extended|\
  grep ^/|awk '{print $1}');do echo $a:;dumpe2fs -h $a 21|\
  grep -v 'Bad magic number'|\
  egrep '(^Mount count:|Maximum mount count:|Next check after:)';echo;done
  
  Needs to be run as root; maybe it's helpful to someone.
  
 
 I'm just looking for a way to skip the occasional check at boot, because 
 I don't want to wait ages for the computer boot. A lot of Ctrl-C does 
 the trick but then no disks get mounted so I end up spending just as 
 long mounting them manually as the computer takes checking them!

   Another solution I've seen recently is to remove the check-on-boot
entirely. This in itself is a bad thing, because you then don't get to
find random bit-flip data corruptions (which is what the regular
fsck-on-boot is for). To get the same effect with no impact on boot
times, keep your filesystems in LVM, take a snapshot of each
filesystem at regular intervals, and then run fsck on the snapshot.
(This advice came from Ted Ts'o, who knows a thing or two about
filesystems... :) )

   Hugo.

-- 
=== Hugo Mills: h...@... carfax.org.uk | darksatanic.net | lug.org.uk ===
  PGP key: 515C238D from wwwkeys.eu.pgp.net or http://www.carfax.org.uk
--- emacs:  Eighty Megabytes And Constantly Swapping. ---


signature.asc
Description: Digital signature
-- 
Please post to: Hampshire@mailman.lug.org.uk
Web Interface: https://mailman.lug.org.uk/mailman/listinfo/hampshire
LUG URL: http://www.hantslug.org.uk
--

Re: [Hampshire] Periodic filesystem checks

2009-11-24 Thread Hugo Mills
On Tue, Nov 24, 2009 at 02:21:14PM -, Damian Brasher wrote:
 Hugo Mills wrote:
 
 Another solution I've seen recently is to remove the check-on-boot
  entirely. This in itself is a bad thing, because you then don't get to
  find random bit-flip data corruptions (which is what the regular
  fsck-on-boot is for). To get the same effect with no impact on boot
  times, keep your filesystems in LVM, take a snapshot of each
  filesystem at regular intervals, and then run fsck on the snapshot.
  (This advice came from Ted Ts'o, who knows a thing or two about
  filesystems... :) )
 
 Or, when you have time, boot onto emergency mode from grub by adding
 'emergency' at the grub command prompt. Login when prompted then fdisk -l to
 view the available partitions then fsck manually.

   That requires you to think about it, and involves a reboot and
significant downtime, which nobody is going to do. Ted's solution is
scriptable, (ana)cronnable, and entirely automated.

   Hugo.

-- 
=== Hugo Mills: h...@... carfax.org.uk | darksatanic.net | lug.org.uk ===
  PGP key: 515C238D from wwwkeys.eu.pgp.net or http://www.carfax.org.uk
  --- Do not meddle in the affairs of wizards, for they are subtle, ---  
   and quick to anger.   


signature.asc
Description: Digital signature
-- 
Please post to: Hampshire@mailman.lug.org.uk
Web Interface: https://mailman.lug.org.uk/mailman/listinfo/hampshire
LUG URL: http://www.hantslug.org.uk
--

Re: [Hampshire] Periodic filesystem checks

2009-11-24 Thread Damian Brasher
Hugo Mills wrote:

 Or, when you have time, boot onto emergency mode from grub by adding
 'emergency' at the grub command prompt. Login when prompted then fdisk -l
 to
 view the available partitions then fsck manually.

That requires you to think about it, and involves a reboot and
 significant downtime, which nobody is going to do. Ted's solution is
 scriptable, (ana)cronnable, and entirely automated.

Fair enough - I'm taking the view that the machine in question does not have
a great deal of resources available.

Use of tune2fs might be a better solution yet.

Damian

-- 
WWW http://www.diaser.org.uk - Open Source Data Vault Application - beta-1

RSS http://sourceforge.net/export/rss2_projnews.php?group_id=258272

Blog http://interlinux.co.uk/wordpress


-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.


-- 
Please post to: Hampshire@mailman.lug.org.uk
Web Interface: https://mailman.lug.org.uk/mailman/listinfo/hampshire
LUG URL: http://www.hantslug.org.uk
--


Re: [Hampshire] Periodic filesystem checks

2009-11-23 Thread Leo
Keith Edmunds wrote:
 I put this command together to find out whether the checks would run if
 the system were rebooted. It isn't perfect - patches welcome! - but it
 does the job.
 
 for a in $(fdisk -l 2/dev/null|grep -v Extended|\
 grep ^/|awk '{print $1}');do echo $a:;dumpe2fs -h $a 21|\
 grep -v 'Bad magic number'|\
 egrep '(^Mount count:|Maximum mount count:|Next check after:)';echo;done
 
 Needs to be run as root; maybe it's helpful to someone.
 

I'm just looking for a way to skip the occasional check at boot, because 
I don't want to wait ages for the computer boot. A lot of Ctrl-C does 
the trick but then no disks get mounted so I end up spending just as 
long mounting them manually as the computer takes checking them!

Leo

-- 
Please post to: Hampshire@mailman.lug.org.uk
Web Interface: https://mailman.lug.org.uk/mailman/listinfo/hampshire
LUG URL: http://www.hantslug.org.uk
--


Re: [Hampshire] Periodic filesystem checks

2009-11-21 Thread James
On Sat, 2009-11-21 at 11:10 +, Leo wrote:

 Pressing Esc doesn't work for me, it just carries on doing the check. 
 Does the ability to skip them have to be enabled somewhere?

Well, they can be stopped in the first place (or made more infrequent)
using the -c or -i options of tune2fs.

James

-- 
James   theholyet...@googlemail.com
PGP key ID: 03F94B5D
---


signature.asc
Description: This is a digitally signed message part
-- 
Please post to: Hampshire@mailman.lug.org.uk
Web Interface: https://mailman.lug.org.uk/mailman/listinfo/hampshire
LUG URL: http://www.hantslug.org.uk
--

Re: [Hampshire] Periodic filesystem checks

2009-11-21 Thread Keith Edmunds
I put this command together to find out whether the checks would run if
the system were rebooted. It isn't perfect - patches welcome! - but it
does the job.

for a in $(fdisk -l 2/dev/null|grep -v Extended|\
grep ^/|awk '{print $1}');do echo $a:;dumpe2fs -h $a 21|\
grep -v 'Bad magic number'|\
egrep '(^Mount count:|Maximum mount count:|Next check after:)';echo;done

Needs to be run as root; maybe it's helpful to someone.

-- 
Keith Edmunds

+-+
|Tiger Computing Ltd|  Helping businesses make the most of Linux  |
|  The Linux Specialists  |   http://www.tiger-computing.co.uk  |
+-+

-- 
Please post to: Hampshire@mailman.lug.org.uk
Web Interface: https://mailman.lug.org.uk/mailman/listinfo/hampshire
LUG URL: http://www.hantslug.org.uk
--


Re: [Hampshire] Periodic filesystem checks

2009-07-25 Thread Andy Smith
Hi Keith,

On Sat, Jul 25, 2009 at 01:53:07PM +0100, Keith Edmunds wrote:
 Is it possible to establish, on a running system, how many mounts each
 filesystem has had since the last check and what the tune2fs
 -c parameter is? Similarly, is it possible to find out how many days have
 elapsed since the last check and what the tune2fs -i parameter is?

dumpe2fs -h /dev/blah..

-- 
http://bitfolk.com/ -- No-nonsense VPS hosting

You dont have to be illiterate to use the Internet, but it help's.
 -- Mike Bristow


signature.asc
Description: Digital signature
-- 
Please post to: Hampshire@mailman.lug.org.uk
Web Interface: https://mailman.lug.org.uk/mailman/listinfo/hampshire
LUG URL: http://www.hantslug.org.uk
--

Re: [Hampshire] Periodic filesystem checks

2009-07-25 Thread Keith Edmunds
Thanks Andy, exactly what I was looking for.

Keith

-- 
Please post to: Hampshire@mailman.lug.org.uk
Web Interface: https://mailman.lug.org.uk/mailman/listinfo/hampshire
LUG URL: http://www.hantslug.org.uk
--


Re: [Hampshire] Periodic filesystem checks

2009-07-25 Thread Leo
On a not entirely unrelated note, when the a file system check starts 
during a boot up, is it possible to skip it? I've tried Ctrl-C but that 
doesn't work.

Leo

-- 
Please post to: Hampshire@mailman.lug.org.uk
Web Interface: https://mailman.lug.org.uk/mailman/listinfo/hampshire
LUG URL: http://www.hantslug.org.uk
--


Re: [Hampshire] Periodic filesystem checks

2009-07-25 Thread Alan Pope
2009/7/25 Leo li...@fractal.me.uk:
 On a not entirely unrelated note, when the a file system check starts
 during a boot up, is it possible to skip it? I've tried Ctrl-C but that
 doesn't work.


Depends. On Ubuntu you can press ESC to skip it.

Cheers,
Al.

-- 
Please post to: Hampshire@mailman.lug.org.uk
Web Interface: https://mailman.lug.org.uk/mailman/listinfo/hampshire
LUG URL: http://www.hantslug.org.uk
--