hi
What's coolest/best/worst of ext3, ReiserFS and XFS?
I just set up a RedHat 7.2 box with ext3, and after a few tests/chrashes,
I see no difference at all. After a chrash, it really wants to run fsck
anyway. I've tried ReiserFS before, with no fsck after chrashes - is this
because ReiserFS is better, or is it more like a hope-it's-ok-thinkig?
Then - last - How about XFS?
roy
--
Roy Sigurd Karlsbakk, MCSE, MCNE, CLS, LCA
Computers are like air conditioners.
They stop working when you open Windows.
> I just set up a RedHat 7.2 box with ext3, and after a few tests/chrashes,
> I see no difference at all. After a chrash, it really wants to run fsck
> anyway. I've tried ReiserFS before, with no fsck after chrashes - is this
Umm RH 7.2 after an unexpected shutdown will give you a 5 second count down
when you can choose to force an fsck - ext3 doesnt need an fsck but
sometimes folks might want to force it thats all
On Wed, 7 Nov 2001, Alan Cox wrote:
> > I just set up a RedHat 7.2 box with ext3, and after a few tests/chrashes,
> > I see no difference at all. After a chrash, it really wants to run fsck
> > anyway. I've tried ReiserFS before, with no fsck after chrashes - is this
>
> Umm RH 7.2 after an unexpected shutdown will give you a 5 second count down
> when you can choose to force an fsck - ext3 doesnt need an fsck but
> sometimes folks might want to force it thats all
I get this countdown, but after 5 seconds fsck starts anyway, without me
hitting Y! Should I hit N, or should I change some config somewhere? Now each
time my battery runs out, I need fsck!
--
Dr. Zvi Har'El mailto:[email protected] Department of Mathematics
tel:+972-54-227607 Technion - Israel Institute of Technology
fax:+972-4-8324654 http://www.math.technion.ac.il/~rl/ Haifa 32000, ISRAEL
"If you can't say somethin' nice, don't say nothin' at all." -- Thumper (1942)
Wednesday, 21 Heshvan 5762, 7 November 2001, 5:26PM
On Wednesday 07 November 2001 3:23 pm, Alan Cox wrote:
> > I just set up a RedHat 7.2 box with ext3, and after a few tests/chrashes,
> > I see no difference at all. After a chrash, it really wants to run fsck
> > anyway. I've tried ReiserFS before, with no fsck after chrashes - is this
>
> Umm RH 7.2 after an unexpected shutdown will give you a 5 second count down
> when you can choose to force an fsck - ext3 doesnt need an fsck but
> sometimes folks might want to force it thats all
Hm.. after a decidedly unclean shutdown, I decided to force an fsck here and
my ext3 partition DID have two inode errors on fsck... (Having said that, the
last entry in syslog was from the SCSI driver, and ext3's journalling
probably doesn't help much when the disk it's on goes AWOL...)
James.
At 15:23 07/11/2001, Alan Cox wrote:
> > I just set up a RedHat 7.2 box with ext3, and after a few tests/chrashes,
> > I see no difference at all. After a chrash, it really wants to run fsck
> > anyway. I've tried ReiserFS before, with no fsck after chrashes - is this
>
>Umm RH 7.2 after an unexpected shutdown will give you a 5 second count down
>when you can choose to force an fsck - ext3 doesnt need an fsck but
>sometimes folks might want to force it thats all
Hm, while still on the default RH7.2 kernel using ext3 on all partitions I
flicked the reset switch accidentally (wrong reset switch it was...) and
when coming back up it fscked (I didn't touch anything - didn't even notice
any 5 second thing but I wasn't looking at this screen) and it found two
lost inodes (I got two entries in lost and found). So it still needs to
fsck by the looks of it?
Anton
--
"I've not lost my mind. It's backed up on tape somewhere." - Unknown
--
Anton Altaparmakov <aia21 at cam.ac.uk> (replace at with @)
Linux NTFS Maintainer / WWW: http://linux-ntfs.sf.net/
ICQ: 8561279 / WWW: http://www-stu.christs.cam.ac.uk/~aia21/
> when coming back up it fscked (I didn't touch anything - didn't even notice
> any 5 second thing but I wasn't looking at this screen) and it found two
> lost inodes (I got two entries in lost and found). So it still needs to
> fsck by the looks of it?
That sounds like you used your own kernel with it and had ext2 mounting
the root fs (remember its back compatible)
Alan
On Wed, Nov 07, 2001 at 04:31:24PM +0000, you [James A Sutherland] claimed:
>
> Hm.. after a decidedly unclean shutdown, I decided to force an fsck here
> and my ext3 partition DID have two inode errors on fsck... (Having said
> that, the last entry in syslog was from the SCSI driver, and ext3's
> journalling probably doesn't help much when the disk it's on goes AWOL...)
A stupid question: does ext3 replay the journal before fsck? If not, the
inode errors would be expected...
-- v --
[email protected]
At 19:12 07/11/2001, Alan Cox wrote:
> > when coming back up it fscked (I didn't touch anything - didn't even
> notice
> > any 5 second thing but I wasn't looking at this screen) and it found two
> > lost inodes (I got two entries in lost and found). So it still needs to
> > fsck by the looks of it?
>
>That sounds like you used your own kernel with it and had ext2 mounting
>the root fs (remember its back compatible)
Yes, that makes a lot of sense. After the reset I went into my own kernel
with both ext2 and ext3 compiled into it. However, before the reboot, I was
still in the RH kernel (99% sure it was so, but my memory might be
deceiving me).
Is there any Right Way(TM) to fix this situation considering I want to have
both ext2 and ext3 in my kernels (apart from the obvious of changing the
order fs are called during root mount in the kernel)?
Thanks,
Anton
--
"I've not lost my mind. It's backed up on tape somewhere." - Unknown
--
Anton Altaparmakov <aia21 at cam.ac.uk> (replace at with @)
Linux NTFS Maintainer / WWW: http://linux-ntfs.sf.net/
ICQ: 8561279 / WWW: http://www-stu.christs.cam.ac.uk/~aia21/
FWIW, I run both ext3 and reiserfs on the same computer, and, after a crash, neither of them run fsck. My ext3 partition is mounted on /, so maybe it matters that it's mounted *before* it's fscked? The journal replay should mark it clean, so fsck should only run when it times out. You can also set the fsck number to "0" in your fstab, and it will never fsck, but then you will loose the periodic fscks. (I run 2.4.13-ac7-preempt-sse at the moment.)
Daniel
---
Recursion n.:
See Recursion.
-- Random Shack Data Processing Dictionary
On Wed, 7 Nov 2001 21:38:37 +0200
Ville Herva <[email protected]> wrote:
> On Wed, Nov 07, 2001 at 04:31:24PM +0000, you [James A Sutherland] claimed:
> >
> > Hm.. after a decidedly unclean shutdown, I decided to force an fsck here
> > and my ext3 partition DID have two inode errors on fsck... (Having said
> > that, the last entry in syslog was from the SCSI driver, and ext3's
> > journalling probably doesn't help much when the disk it's on goes AWOL...)
>
> A stupid question: does ext3 replay the journal before fsck? If not, the
> inode errors would be expected...
>
>
> -- v --
>
> [email protected]
On Nov 07, 2001 16:00 +0100, Roy Sigurd Karlsbakk wrote:
> I just set up a RedHat 7.2 box with ext3, and after a few tests/chrashes,
> I see no difference at all. After a chrash, it really wants to run fsck
> anyway.
If you are getting a real* fsck for an "ext3" filesystem there are two
possibilities:
1) You actually have ext2, not ext3 - check /proc/mounts to be sure.
2) After 20 (by default) crashes, ext3 filesystems are fsck'd anyways.
This is NOT because ext3 is bad/unreliable, but because hardware,
RAM, kernels can be bad. Use "tune2fs -c 50" to change this interval
to every 50 mounts. It is a bad idea to turn it off completely.
(*) Note that e2fsck WILL run on each boot, but will only recover the journal
and clean up orphan inodes. That will take < 2 seconds, and is not a sign
that something is wrong with the filesystem.
> I've tried ReiserFS before, with no fsck after chrashes - is this
> because ReiserFS is better, or is it more like a hope-it's-ok-thinkig?
The latter - Hans and other reiserfs folks acknowledge that reiserfsck
is NOT safe enough to run on each boot, so they don't suggest running it
unless you have a problem. e2fsck IS very good, so it can run on each
boot. There are still lots of problems reported with reiserfs, and Hans
acknowledges that many of them are due to memory/hardware/kernel problems,
so it IS still a good idea to run fsck periodically at boot, but reiserfsck
cannot do that yet.
Cheers, Andreas
--
Andreas Dilger
http://sourceforge.net/projects/ext2resize/
http://www-mddsp.enel.ucalgary.ca/People/adilger/
On Nov 07, 2001 17:28 +0200, Zvi Har'El wrote:
> I get this countdown, but after 5 seconds fsck starts anyway, without me
> hitting Y! Should I hit N, or should I change some config somewhere? Now each
> time my battery runs out, I need fsck!
Are you SURE you are using ext3? Check /proc/mounts to be sure. What it
says in /etc/fstab is irrelevant for the root filesystem.
Cheers, Andreas
--
Andreas Dilger
http://sourceforge.net/projects/ext2resize/
http://www-mddsp.enel.ucalgary.ca/People/adilger/
Anton Altaparmakov wrote:
>
> At 19:12 07/11/2001, Alan Cox wrote:
> > > when coming back up it fscked (I didn't touch anything - didn't even
> > notice
> > > any 5 second thing but I wasn't looking at this screen) and it found two
> > > lost inodes (I got two entries in lost and found). So it still needs to
> > > fsck by the looks of it?
> >
> >That sounds like you used your own kernel with it and had ext2 mounting
> >the root fs (remember its back compatible)
>
> Yes, that makes a lot of sense. After the reset I went into my own kernel
> with both ext2 and ext3 compiled into it. However, before the reboot, I was
> still in the RH kernel (99% sure it was so, but my memory might be
> deceiving me).
>
> Is there any Right Way(TM) to fix this situation considering I want to have
> both ext2 and ext3 in my kernels (apart from the obvious of changing the
> order fs are called during root mount in the kernel)?
>
There's a fair bit of material on this at
http://www.uow.edu.au/~andrewm/linux/ext3/ext3-usage.html
executive summary:
- use latest util-linux and e2fsprogs
- Make the root fs have fstype `ext3' in /etc/fstab
- Make the others `auto'
- Alternatively, use "ext3,ext2" in fstab.
The problem is that various tools (mount, fsck, df, others?)
make various assumptions about what to do when certain
filesystem types are encountered in fstab. It's been a bit
painful.
-
On Nov 07, 2001 18:40 +0000, Anton Altaparmakov wrote:
> Hm, while still on the default RH7.2 kernel using ext3 on all partitions I
> flicked the reset switch accidentally (wrong reset switch it was...) and
> when coming back up it fscked (I didn't touch anything - didn't even notice
> any 5 second thing but I wasn't looking at this screen) and it found two
> lost inodes (I got two entries in lost and found). So it still needs to
> fsck by the looks of it?
Well, e2fsck will always run if the filesystem has an error marked in it.
When was the last time you ran e2fsck on the fs before you converted to
ext3? It is possible that these lost inodes were in the fs before you
converted?
Cheers, Andreas
--
Andreas Dilger
http://sourceforge.net/projects/ext2resize/
http://www-mddsp.enel.ucalgary.ca/People/adilger/
On Wed, 2001-11-07 at 14:38, Ville Herva wrote:
> A stupid question: does ext3 replay the journal before fsck? If not, the
> inode errors would be expected...
ext3 will reply the root file systems journal on boot when the kernel
mounts root. other ext3 partitions will have their journals replayed
when they are mounted.
also, btw, I use RedHat 7.2 and fsck does not run if I don't hit Y. It
is there for pedants or seriously screwed disks -- the journal replay
should be sufficient.
Robert Love
At 20:21 07/11/2001, Andreas Dilger wrote:
>On Nov 07, 2001 18:40 +0000, Anton Altaparmakov wrote:
> > Hm, while still on the default RH7.2 kernel using ext3 on all partitions I
> > flicked the reset switch accidentally (wrong reset switch it was...) and
> > when coming back up it fscked (I didn't touch anything - didn't even
> notice
> > any 5 second thing but I wasn't looking at this screen) and it found two
> > lost inodes (I got two entries in lost and found). So it still needs to
> > fsck by the looks of it?
>
>Well, e2fsck will always run if the filesystem has an error marked in it.
>When was the last time you ran e2fsck on the fs before you converted to
>ext3? It is possible that these lost inodes were in the fs before you
>converted?
It was a blank HD (well I had just installed Windows on it first so it
wasn't quite blank any more) and then installed RH7.2 and told the
installer to use ext3 for all the partitions. So it should be impossible
that something is left over from before. There was nothing there... (-:
Anton
--
"I've not lost my mind. It's backed up on tape somewhere." - Unknown
--
Anton Altaparmakov <aia21 at cam.ac.uk> (replace at with @)
Linux NTFS Maintainer / WWW: http://linux-ntfs.sf.net/
ICQ: 8561279 / WWW: http://www-stu.christs.cam.ac.uk/~aia21/
On Nov 07, 2001 19:40 +0000, Anton Altaparmakov wrote:
> Yes, that makes a lot of sense. After the reset I went into my own kernel
> with both ext2 and ext3 compiled into it. However, before the reboot, I was
> still in the RH kernel (99% sure it was so, but my memory might be
> deceiving me).
>
> Is there any Right Way(TM) to fix this situation considering I want to have
> both ext2 and ext3 in my kernels (apart from the obvious of changing the
> order fs are called during root mount in the kernel)?
If both ext2 and ext3 are compiled into the kernel, then ext3 will try first
to mount the root fs. If there is no journal on this fs (check this with
tune2fs -l <dev>, and look for "has_journal" feature), then it will be
mounted as ext2. If you are doing strange things with initrd and modules,
then there is more chance to have problems.
I don't know why you would want to go back to ext2 if you have ext3 in your
kernel, but if so, there is a patch to add a "rootfstype" parameter which
allows you to select the fstype to try and mount your root fs as. It looks
like it is in Linus' 2.4.13 kernel at least (don't know when it went in).
Cheers, Andreas
--
Andreas Dilger
http://sourceforge.net/projects/ext2resize/
http://www-mddsp.enel.ucalgary.ca/People/adilger/
At 20:25 07/11/2001, Andreas Dilger wrote:
>On Nov 07, 2001 19:40 +0000, Anton Altaparmakov wrote:
> > Yes, that makes a lot of sense. After the reset I went into my own kernel
> > with both ext2 and ext3 compiled into it. However, before the reboot, I
> was
> > still in the RH kernel (99% sure it was so, but my memory might be
> > deceiving me).
> >
> > Is there any Right Way(TM) to fix this situation considering I want to
> have
> > both ext2 and ext3 in my kernels (apart from the obvious of changing the
> > order fs are called during root mount in the kernel)?
>
>If both ext2 and ext3 are compiled into the kernel, then ext3 will try first
>to mount the root fs. If there is no journal on this fs (check this with
>tune2fs -l <dev>, and look for "has_journal" feature), then it will be
>mounted as ext2. If you are doing strange things with initrd and modules,
>then there is more chance to have problems.
Will check. Thanks for info.
>I don't know why you would want to go back to ext2 if you have ext3 in your
>kernel, but if so, there is a patch to add a "rootfstype" parameter which
>allows you to select the fstype to try and mount your root fs as. It looks
>like it is in Linus' 2.4.13 kernel at least (don't know when it went in).
Well one good reason is I don't trust ext3 because it is new and I haven't
used it before. (You can call me paranoid all you want...) Before I start
trusting it with my really important data, I would rather use ext3 for a
while on /, /usr and other non-important partitions (they can be
reinstalled, /home cannot...)
Anton
--
"I've not lost my mind. It's backed up on tape somewhere." - Unknown
--
Anton Altaparmakov <aia21 at cam.ac.uk> (replace at with @)
Linux NTFS Maintainer / WWW: http://linux-ntfs.sf.net/
ICQ: 8561279 / WWW: http://www-stu.christs.cam.ac.uk/~aia21/
Robert Love wrote:
>
> On Wed, 2001-11-07 at 14:38, Ville Herva wrote:
> > A stupid question: does ext3 replay the journal before fsck? If not, the
> > inode errors would be expected...
>
> ext3 will reply the root file systems journal on boot when the kernel
> mounts root. other ext3 partitions will have their journals replayed
> when they are mounted.
>
> also, btw, I use RedHat 7.2 and fsck does not run if I don't hit Y. It
> is there for pedants or seriously screwed disks -- the journal replay
> should be sufficient.
>
fsck can perform journal replay. It's the same code, in fact.
So even if one does run fsck against an unclean ext3 partition,
fsck will just replay the journal and then exit. It won't do
the twenty minute go-grab-a-coffee thing unless it has explicitly
been passed the `-f' option. Doing that is very, very paraniod.
I normally just leave ext3 at the default check-time settings,
so fsck runs every thirtieth boot or so. ie: hourly :)
=
On Wednesday 07 November 2001 7:38 pm, Ville Herva wrote:
> On Wed, Nov 07, 2001 at 04:31:24PM +0000, you [James A Sutherland] claimed:
> > Hm.. after a decidedly unclean shutdown, I decided to force an fsck here
> > and my ext3 partition DID have two inode errors on fsck... (Having said
> > that, the last entry in syslog was from the SCSI driver, and ext3's
> > journalling probably doesn't help much when the disk it's on goes
> > AWOL...)
>
> A stupid question: does ext3 replay the journal before fsck? If not, the
> inode errors would be expected...
Yes, it does: this was AFTER the journal replay. And yes, it was ext3 not
ext2 mounting it (well, either that or ext2 has learned to do journal
replays...). So, AFTER a journal replay, there were still two damaged inodes
- which sounds like Anton's problem. Maybe ext3 just hates Cambridge? :-)
James.
On Wed, 7 Nov 2001, Andreas Dilger wrote:
> On Nov 07, 2001 17:28 +0200, Zvi Har'El wrote:
> > I get this countdown, but after 5 seconds fsck starts anyway, without me
> > hitting Y! Should I hit N, or should I change some config somewhere? Now each
> > time my battery runs out, I need fsck!
>
> Are you SURE you are using ext3? Check /proc/mounts to be sure. What it
> says in /etc/fstab is irrelevant for the root filesystem.
>
/proc/mounts has
/dev/root / ext2 rw 0 0
/dev/hda6 /home ext3 rw 0 0
However, tune2fs -l on both /dev/hda1 (the root filesystem) and /dev/hda6 gives
Filesystem features: has_journal sparse_super
How do fix the situation at this stage? I am using Redhat 7.2 with kernel
2.4.9-13
Thanks for your help,
Zvi.
--
Dr. Zvi Har'El mailto:[email protected] Department of Mathematics
tel:+972-54-227607 Technion - Israel Institute of Technology
fax:+972-4-8324654 http://www.math.technion.ac.il/~rl/ Haifa 32000, ISRAEL
"If you can't say somethin' nice, don't say nothin' at all." -- Thumper (1942)
Wednesday, 22 Heshvan 5762, 7 November 2001, 11:02PM
On Nov 07, 2001 20:44 +0000, James A Sutherland wrote:
> On Wednesday 07 November 2001 7:38 pm, Ville Herva wrote:
> > On Wed, Nov 07, 2001 at 04:31:24PM +0000, you [James A Sutherland] claimed:
> > > Hm.. after a decidedly unclean shutdown, I decided to force an fsck here
> > > and my ext3 partition DID have two inode errors on fsck... (Having said
> > > that, the last entry in syslog was from the SCSI driver, and ext3's
> > > journalling probably doesn't help much when the disk it's on goes
> > > AWOL...)
> >
> > A stupid question: does ext3 replay the journal before fsck? If not, the
> > inode errors would be expected...
>
> Yes, it does: this was AFTER the journal replay. And yes, it was ext3 not
> ext2 mounting it (well, either that or ext2 has learned to do journal
> replays...).
Actuall, e2fsck can also do the journal replay, so depending on whether this
is the root fs or not, it may be that you get a journal replay and still
mount it as ext2...
> So, AFTER a journal replay, there were still two damaged inodes
> - which sounds like Anton's problem. Maybe ext3 just hates Cambridge? :-)
Well, if you had a SCSI error, then it may be that the fs marked an error
in the superblock, which would force a full fsck also.
Note also, that it is often normal to have "orphaned inodes" cleaned up when
the journal is cleaned up. This is not an error. I normally have these on
my system because of PCMCIA cardmgr creating device inodes in /tmp and then
unlinking them immediately after opening them.
If you have an open but unlinked file, then ext3 will delete this file at
mount/fsck time (unlike reiserfs which leaves it around wasting space).
Did you actually get files in lost+found, or only the orphaned inode
message?
Cheers, Andreas
--
Andreas Dilger
http://sourceforge.net/projects/ext2resize/
http://www-mddsp.enel.ucalgary.ca/People/adilger/
> /dev/root / ext2 rw 0 0
> /dev/hda6 /home ext3 rw 0 0
>
> However, tune2fs -l on both /dev/hda1 (the root filesystem) and /dev/hda6
> gives Filesystem features: has_journal sparse_super
You don use ext3.
ext3 is backward compatible with ext2. So you can mount ext3 as ext2
completely ignoring the journal.
Look for a line in /etc/fstab
/dev/root and change the file system to ext3.
greetings
Christian Borntr?ger
On Wed, Nov 07, 2001 at 04:00:55PM +0100, Roy Sigurd Karlsbakk wrote:
> hi
>
> What's coolest/best/worst of ext3, ReiserFS and XFS?
> I just set up a RedHat 7.2 box with ext3, and after a few tests/chrashes,
> I see no difference at all. After a chrash, it really wants to run fsck
> anyway.
It will run fsck after a crash, but the fsck simply runs the journal
on ext3 filesystems that were uncleanly mounted. So the fsck will run
very quickly, *unless* the kernel had detected some kind of filesystem
error, and had set the "the filesystem has errors" flag, in which case
the full fsck check will be run.
If you're seeing a full fsck (i.e., a run which takes over a minute
and where you see the progress bar) after a crash consistently, you
might want to check and make sure that you've really converted the
filesystem in question to ext3.....
- Ted
On Wed, Nov 07, 2001 at 12:15:12PM -0800, Andrew Morton wrote:
> Anton Altaparmakov wrote:
> >
> > At 19:12 07/11/2001, Alan Cox wrote:
> > > > when coming back up it fscked (I didn't touch anything - didn't even
> > > notice
> > > > any 5 second thing but I wasn't looking at this screen) and it found two
> > > > lost inodes (I got two entries in lost and found). So it still needs to
> > > > fsck by the looks of it?
> > >
> > >That sounds like you used your own kernel with it and had ext2 mounting
> > >the root fs (remember its back compatible)
> >
> > Yes, that makes a lot of sense. After the reset I went into my own kernel
> > with both ext2 and ext3 compiled into it. However, before the reboot, I was
> > still in the RH kernel (99% sure it was so, but my memory might be
> > deceiving me).
> >
> > Is there any Right Way(TM) to fix this situation considering I want to have
> > both ext2 and ext3 in my kernels (apart from the obvious of changing the
> > order fs are called during root mount in the kernel)?
> >
>
> There's a fair bit of material on this at
>
> http://www.uow.edu.au/~andrewm/linux/ext3/ext3-usage.html
>
> executive summary:
>
> - use latest util-linux and e2fsprogs
> - Make the root fs have fstype `ext3' in /etc/fstab
> - Make the others `auto'
> - Alternatively, use "ext3,ext2" in fstab.
>
I have a switch "data=journal" that ext2 will choke on when I boot into an
ext2 only kernel.
Is there another way to change the journaling mode besides modifying
/etc/fstab?
It'd be nice if it could be a compile time switch for default journal mode...
Mike
On Wed, Nov 07, 2001 at 02:11:57PM -0700, [Andreas Dilger] said:
>
> If you have an open but unlinked file, then ext3 will delete this file at
> mount/fsck time (unlike reiserfs which leaves it around wasting space).
Is this really still true for reiserfs? Is there a way to get rid of them?
reiserfsck? I had this vague impression that this bug had been dealt with
but...
-- v --
[email protected]
On Wed, Nov 07, 2001 at 10:25:12PM +0100, Christian Borntr?ger wrote:
> > /dev/root / ext2 rw 0 0
> > /dev/hda6 /home ext3 rw 0 0
> >
> > However, tune2fs -l on both /dev/hda1 (the root filesystem) and /dev/hda6
> > gives Filesystem features: has_journal sparse_super
>
> You don use ext3.
> ext3 is backward compatible with ext2. So you can mount ext3 as ext2
> completely ignoring the journal.
>
> Look for a line in /etc/fstab
> /dev/root and change the file system to ext3.
>
No.
This is chosen at boot time before /etc/fstab can be read...
check /proc/filesystems and make sure that ext3 is listed before ext2.
Also make sure that ext3 is compiled into the kernel. You can use modules
if you want to mess with initrd, but I don't...
Mike
On Nov 07, 2001 23:11 +0200, Zvi Har'El wrote:
> On Wed, 7 Nov 2001, Andreas Dilger wrote:
> > Are you SURE you are using ext3? Check /proc/mounts to be sure. What it
> > says in /etc/fstab is irrelevant for the root filesystem.
> >
> /proc/mounts has
>
> /dev/root / ext2 rw 0 0
> /dev/hda6 /home ext3 rw 0 0
>
> However, tune2fs -l on both /dev/hda1 (the root filesystem) and /dev/hda6
> Filesystem features: has_journal sparse_super
>
>
> How do fix the situation at this stage? I am using Redhat 7.2 with kernel
> 2.4.9-13
Do you have ext3 compiled into the kernel? I suspect you have it as a module.
Also, given the large number of similar bug reports, maybe RedHat has a bug in
their mkinitrd script which doesn't try to mount the root fs with ext3? I
don't know enough about their mkinitrd tools to say - Alan, Stephen?
Cheers, Andreas
--
Andreas Dilger
http://sourceforge.net/projects/ext2resize/
http://www-mddsp.enel.ucalgary.ca/People/adilger/
On Nov 07, 2001 23:37 +0200, Ville Herva wrote:
> On Wed, Nov 07, 2001 at 02:11:57PM -0700, [Andreas Dilger] said:
> > If you have an open but unlinked file, then ext3 will delete this file at
> > mount/fsck time (unlike reiserfs which leaves it around wasting space).
>
> Is this really still true for reiserfs? Is there a way to get rid of them?
> reiserfsck? I had this vague impression that this bug had been dealt with
It may be fixed by now, but it wasn't for a long time. I'm not sure what
reiserfs patches are in the stock kernel anymore.
Cheers, Andreas
--
Andreas Dilger
http://sourceforge.net/projects/ext2resize/
http://www-mddsp.enel.ucalgary.ca/People/adilger/
In article <Pine.GSO.4.33.0111072302460.12525-100000@leeor.math.technion.ac.il> you wrote:
> On Wed, 7 Nov 2001, Andreas Dilger wrote:
> /dev/root / ext2 rw 0 0
ext2!
> /dev/hda6 /home ext3 rw 0 0
> How do fix the situation at this stage? I am using Redhat 7.2 with kernel
> 2.4.9-13
Be sure to use the initrd as used by default in when you install the kernel.
Are you using lilo ? If so add
initrd /boot/initrd-2.4.9-13.img
to the lilo.conf in the relevant kernel section.
Greetings,
Arjan van de Ven
Mike Fedyk wrote:
>
> I have a switch "data=journal" that ext2 will choke on when I boot into an
> ext2 only kernel.
>
> Is there another way to change the journaling mode besides modifying
> /etc/fstab?
Try adding `rootflags=data=journal' to your kernel boot
commandline.
> It'd be nice if it could be a compile time switch for default journal mode...
It can be done via lilo.conf and /etc/fstab.
In article <[email protected]> you wrote:
> Also, given the large number of similar bug reports, maybe RedHat has a bug in
> their mkinitrd script which doesn't try to mount the root fs with ext3? I
> don't know enough about their mkinitrd tools to say - Alan, Stephen?
I think most people who report this are using lilo and didn't add the initrd
to the lilo.conf when they upgraded the kernel... So far I've not had a
single report about mkinitrd doing it wrong...
On Wed, Nov 07, 2001 at 02:00:53PM -0800, Andrew Morton wrote:
> Mike Fedyk wrote:
> >
> > I have a switch "data=journal" that ext2 will choke on when I boot into an
> > ext2 only kernel.
> >
> > Is there another way to change the journaling mode besides modifying
> > /etc/fstab?
>
> Try adding `rootflags=data=journal' to your kernel boot
> commandline.
>
Does that work for non-root ext3 mounts also? ie, will ext3 default to
data=journaled mode for future mounts?
> > It'd be nice if it could be a compile time switch for default journal mode...
>
> It can be done via lilo.conf and /etc/fstab.
Mike
On Wed, Nov 07, 2001 at 02:00:53PM -0800, Andrew Morton wrote:
> Mike Fedyk wrote:
> >
> > I have a switch "data=journal" that ext2 will choke on when I boot into an
> > ext2 only kernel.
> >
> > Is there another way to change the journaling mode besides modifying
> > /etc/fstab?
>
> Try adding `rootflags=data=journal' to your kernel boot
> commandline.
>
Oh, JOY!
adding that line to an ext2 only kernel will make it kernel panic when it
tries to mount root because it doesn't understand the option!
Mike
Mike Fedyk wrote:
>
> On Wed, Nov 07, 2001 at 02:00:53PM -0800, Andrew Morton wrote:
> > Mike Fedyk wrote:
> > >
> > > I have a switch "data=journal" that ext2 will choke on when I boot into an
> > > ext2 only kernel.
> > >
> > > Is there another way to change the journaling mode besides modifying
> > > /etc/fstab?
> >
> > Try adding `rootflags=data=journal' to your kernel boot
> > commandline.
> >
>
> Does that work for non-root ext3 mounts also? ie, will ext3 default to
> data=journaled mode for future mounts?
Nope. You specify the option to other filesystems in /etc/fstab.
Mike Fedyk wrote:
>
> On Wed, Nov 07, 2001 at 02:00:53PM -0800, Andrew Morton wrote:
> > Mike Fedyk wrote:
> > >
> > > I have a switch "data=journal" that ext2 will choke on when I boot into an
> > > ext2 only kernel.
> > >
> > > Is there another way to change the journaling mode besides modifying
> > > /etc/fstab?
> >
> > Try adding `rootflags=data=journal' to your kernel boot
> > commandline.
> >
>
> Oh, JOY!
>
> adding that line to an ext2 only kernel will make it kernel panic when it
> tries to mount root because it doesn't understand the option!
>
It's dumb that an unrecognised option be a fatal error. Same
problem with modules, actually. If you add a new module option
to modules.conf and then go back to an older kernel your module
won't load (here's where kaos pokes me with the rtfm stick).
You can create a second entry in lilo.conf which refers to the same
kernel image, but which doesn't have the rootflags option.
-
On Nov 07, 2001 14:56 -0800, Andrew Morton wrote:
> Mike Fedyk wrote:
> > Does that work for non-root ext3 mounts also? ie, will ext3 default to
> > data=journaled mode for future mounts?
>
> Nope. You specify the option to other filesystems in /etc/fstab.
Maybe it should be possible to specify the journaling mode in the journal
superblock? A mount option would override it, but it would at least set
the default mode.
Cheers, Andreas
--
Andreas Dilger
http://sourceforge.net/projects/ext2resize/
http://www-mddsp.enel.ucalgary.ca/People/adilger/
On November 7, 2001 12:25, Andreas Dilger wrote:
> If both ext2 and ext3 are compiled into the kernel, then ext3 will try
> first to mount the root fs. If there is no journal on this fs (check this
> with tune2fs -l <dev>, and look for "has_journal" feature), then it will be
> mounted as ext2. If you are doing strange things with initrd and modules,
Is there any particular reason why the ext3 driver can't handle mounting both
ext2 and ext3 filesystems?
-Ryan
Andrew Morton wrote:
>
> Mike Fedyk wrote:
> >
> > On Wed, Nov 07, 2001 at 02:00:53PM -0800, Andrew Morton wrote:
> > > Mike Fedyk wrote:
> > > >
> > > > I have a switch "data=journal" that ext2 will choke on when I boot into an
> > > > ext2 only kernel.
> > > >
> > > > Is there another way to change the journaling mode besides modifying
> > > > /etc/fstab?
> > >
> > > Try adding `rootflags=data=journal' to your kernel boot
> > > commandline.
> > >
> >
> > Oh, JOY!
> >
> > adding that line to an ext2 only kernel will make it kernel panic when it
> > tries to mount root because it doesn't understand the option!
> >
>
> It's dumb that an unrecognised option be a fatal error. Same
> problem with modules, actually. If you add a new module option
> to modules.conf and then go back to an older kernel your module
> won't load (here's where kaos pokes me with the rtfm stick).
It might be interesting if modules.conf had a scheme similar to
versioning for System.map. E.G., search first for
/etc/modules.conf-2.4.9-6, and if not found, go for /etc/modules.conf
(as a fallback in case version-specific didn't exist).
D. Stimits, [email protected]
>
> You can create a second entry in lilo.conf which refers to the same
> kernel image, but which doesn't have the rootflags option.
>
> -
> -
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to [email protected]
> More majordomo info at http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at http://www.tux.org/lkml/
On Wed, Nov 07, 2001 at 02:52:29PM -0800, Mike Fedyk wrote:
> On Wed, Nov 07, 2001 at 02:00:53PM -0800, Andrew Morton wrote:
> > Try adding `rootflags=data=journal' to your kernel boot
> > commandline.
>
> adding that line to an ext2 only kernel will make it kernel panic when it
> tries to mount root because it doesn't understand the option!
So set that option only for ext3 enabled kernels. If you're using lilo,
instead of using a global append= setting, use a local one for that ext3
kernel, and leave it off for the ext2-only kernel.
mrc
--
Mike Castle [email protected] http://www.netcom.com/~dalgoda/
We are all of us living in the shadow of Manhattan. -- Watchmen
fatal ("You are in a maze of twisty compiler features, all different"); -- gcc
On Wed, Nov 07, 2001 at 03:38:05PM -0800, Mike Castle wrote:
> On Wed, Nov 07, 2001 at 02:52:29PM -0800, Mike Fedyk wrote:
> > On Wed, Nov 07, 2001 at 02:00:53PM -0800, Andrew Morton wrote:
> > > Try adding `rootflags=data=journal' to your kernel boot
> > > commandline.
> >
> > adding that line to an ext2 only kernel will make it kernel panic when it
> > tries to mount root because it doesn't understand the option!
>
>
> So set that option only for ext3 enabled kernels. If you're using lilo,
> instead of using a global append= setting, use a local one for that ext3
> kernel, and leave it off for the ext2-only kernel.
>
Yep, I know how to work around the problem.
The question is: why do I *need* to have to do that???
One of the features of ext3 is the backwards compatibility with ext2, but if
you choose to take advantage of ext3 (non default journal mode) to its full
capabilities, ext2 borks on those settings.
With careful consideration, this problem can be avoided with everything the
way it is now, but it is a bit of a hassle...
Though, with non ext3 you wouldn't even have the possibility of mounting the
FS without the correct FS driver loaded...
I think the easiest way to avoid this problem would be a compile time option
to set the default journal mode. But, that would add another question the ext3
developers would have to ask... "what is your default journal mode"... But
they probably already have to ask that since it's settable from kernel
command line, and /etc/fstab...
Mike
On Wed, Nov 07, 2001 at 04:36:13PM -0700, D. Stimits wrote:
> It might be interesting if modules.conf had a scheme similar to
> versioning for System.map. E.G., search first for
> /etc/modules.conf-2.4.9-6, and if not found, go for /etc/modules.conf
> (as a fallback in case version-specific didn't exist).
It does, more or less, if you use the if directives:
if -f /etc/modules.conf-2.4.9-6
include /etc/modules.conf-2.4.9-6
else
[regular stuff here
endif
Or better yet, something like
option foo one=this two=that
if `uname -4` > 2.4.x
add option foo three=blah
endif
mrc
--
Mike Castle [email protected] http://www.netcom.com/~dalgoda/
We are all of us living in the shadow of Manhattan. -- Watchmen
fatal ("You are in a maze of twisty compiler features, all different"); -- gcc
On Wednesday 07 November 2001 9:11 pm, Andreas Dilger wrote:
> On Nov 07, 2001 20:44 +0000, James A Sutherland wrote:
> > On Wednesday 07 November 2001 7:38 pm, Ville Herva wrote:
> > > On Wed, Nov 07, 2001 at 04:31:24PM +0000, you [James A Sutherland]
claimed:
> > > > Hm.. after a decidedly unclean shutdown, I decided to force an fsck
> > > > here and my ext3 partition DID have two inode errors on fsck...
> > > > (Having said that, the last entry in syslog was from the SCSI driver,
> > > > and ext3's journalling probably doesn't help much when the disk it's
> > > > on goes AWOL...)
> > >
> > > A stupid question: does ext3 replay the journal before fsck? If not,
> > > the inode errors would be expected...
> >
> > Yes, it does: this was AFTER the journal replay. And yes, it was ext3 not
> > ext2 mounting it (well, either that or ext2 has learned to do journal
> > replays...).
>
> Actuall, e2fsck can also do the journal replay, so depending on whether
> this is the root fs or not, it may be that you get a journal replay and
> still mount it as ext2...
The journal replay occurred on mount, well before fsck was invoked.
> > So, AFTER a journal replay, there were still two damaged inodes
> > - which sounds like Anton's problem. Maybe ext3 just hates Cambridge? :-)
>
> Well, if you had a SCSI error, then it may be that the fs marked an error
> in the superblock, which would force a full fsck also.
>
> Note also, that it is often normal to have "orphaned inodes" cleaned up
> when the journal is cleaned up. This is not an error. I normally have
> these on my system because of PCMCIA cardmgr creating device inodes in /tmp
> and then unlinking them immediately after opening them.
They were not orphaned inodes, they were inodes with incorrect size & block
values...
> If you have an open but unlinked file, then ext3 will delete this file at
> mount/fsck time (unlike reiserfs which leaves it around wasting space).
> Did you actually get files in lost+found, or only the orphaned inode
> message?
Nothing in l&f, just the familiar (from ext2!) scenario of automatic fsck
finding errors, then dropping me to a single-user login to run fsck manually.
James.
Hi all,
Initrd did it! I was not using initrd. I generated the relevant initrd.img and
added the line to my grub.conf configuration, and the problem is solved.
System crashes are now easily recovered.
The only mystery is, why RedHat has ext3fs compiled as a module?
Lot of thanks,
Zvi.
On Wed, 7 Nov 2001 [email protected] wrote:
> In article <Pine.GSO.4.33.0111072302460.12525-100000@leeor.math.technion.ac.il> you wrote:
> > On Wed, 7 Nov 2001, Andreas Dilger wrote:
>
> > /dev/root / ext2 rw 0 0
>
> ext2!
>
> > /dev/hda6 /home ext3 rw 0 0
>
> > How do fix the situation at this stage? I am using Redhat 7.2 with kernel
> > 2.4.9-13
>
> Be sure to use the initrd as used by default in when you install the kernel.
> Are you using lilo ? If so add
>
> initrd /boot/initrd-2.4.9-13.img
>
> to the lilo.conf in the relevant kernel section.
>
> Greetings,
> Arjan van de Ven
>
--
Dr. Zvi Har'El mailto:[email protected] Department of Mathematics
tel:+972-54-227607 Technion - Israel Institute of Technology
fax:+972-4-8324654 http://www.math.technion.ac.il/~rl/ Haifa 32000, ISRAEL
"If you can't say somethin' nice, don't say nothin' at all." -- Thumper (1942)
Thursday, 22 Heshvan 5762, 8 November 2001, 9:03AM
>>>>> "andrew" == Andrew Morton <[email protected]> writes:
andrew> Mike Fedyk wrote:
>>
>> I have a switch "data=journal" that ext2 will choke on when I boot into an
>> ext2 only kernel.
>>
>> Is there another way to change the journaling mode besides modifying
>> /etc/fstab?
andrew> Try adding `rootflags=data=journal' to your kernel boot
andrew> commandline.
That normally fails if you are using ext3 as a module :(
Later, Juan.
--
In theory, practice and theory are the same, but in practice they
are different -- Larry McVoy
Zvi Har'El wrote:
>
> Hi all,
>
> Initrd did it! I was not using initrd. I generated the relevant initrd.img and
> added the line to my grub.conf configuration, and the problem is solved.
> System crashes are now easily recovered.
>
> The only mystery is, why RedHat has ext3fs compiled as a module?
The basic idea is "everything which can be a module will be a module",
even scsi is a module. And if you use grub, it's 100% transparent as the
initrd
will be automatically added to the grub config when you install the RH
kernel rpm;
even if you use lilo the initrd is supposed to be made for you
automatically.
Greetings,
Arjan van de Ven
When I remove files from a ramfs the space is not reclaimed?
What am I doing wrong? Details below.
thanks,
Padraig.
------------
host:/root# uname -a
Linux host 2.4.12-ac3 #5 Fri Oct 19 12:52:10 IST 2001 i686 unknown
host:/root# df
Filesystem 1k-blocks Used Available Use% Mounted on
/dev/root 58997 47112 8839 84% /
ramfs 63524 3360 60164 5% /var
host:/root# dd if=/dev/zero count=20000 bs=1024 of=/tmp/leak
20000+0 records in
20000+0 records out
host:/root# df
Filesystem 1k-blocks Used Available Use% Mounted on
/dev/root 58997 47112 8839 84% /
ramfs 63524 23360 40164 37% /var
host:/root# rm /tmp/leak
host:/root# df
Filesystem 1k-blocks Used Available Use% Mounted on
/dev/root 58997 47112 8839 84% /
ramfs 63524 23360 40164 37% /var
host:/root# mount
/dev/root on / type ext2 (ro)
proc on /proc type proc (rw)
ramfs on /var type ramfs (rw,noexec)
host:/root# cat /proc/meminfo
total: used: free: shared: buffers: cached:
Mem: 130097152 48156672 81940480 49152 2990080 16277504
Swap: 0 0 0
MemTotal: 127048 kB
MemFree: 80020 kB
MemShared: 48 kB
Buffers: 2920 kB
Cached: 15896 kB
SwapCached: 0 kB
Active: 1760 kB
Inact_dirty: 17104 kB
Inact_clean: 0 kB
Inact_target: 26200 kB
HighTotal: 0 kB
HighFree: 0 kB
LowTotal: 127048 kB
LowFree: 80020 kB
SwapTotal: 0 kB
SwapFree: 0 kB
On Thu, 8 Nov 2001, Arjan van de Ven wrote:
>
> The basic idea is "everything which can be a module will be a module",
> even scsi is a module. And if you use grub, it's 100% transparent as the
> initrd
> will be automatically added to the grub config when you install the RH
> kernel rpm;
> even if you use lilo the initrd is supposed to be made for you
Is there no overhead (except in boot time) in using initrd? If there is, and
ext3fs becomes the normative fs, IMHO ext3 should be part of the kernel, and
not an add-on.
Thanks,
Zvi.
--
Dr. Zvi Har'El mailto:[email protected] Department of Mathematics
tel:+972-54-227607 Technion - Israel Institute of Technology
fax:+972-4-8324654 http://www.math.technion.ac.il/~rl/ Haifa 32000, ISRAEL
"If you can't say somethin' nice, don't say nothin' at all." -- Thumper (1942)
Thursday, 22 Heshvan 5762, 8 November 2001, 2:07PM
On Thu, Nov 08, 2001 at 02:10:58PM +0200, Zvi Har'El wrote:
> On Thu, 8 Nov 2001, Arjan van de Ven wrote:
>
> >
> > The basic idea is "everything which can be a module will be a module",
> > even scsi is a module. And if you use grub, it's 100% transparent as the
> > initrd
> > will be automatically added to the grub config when you install the RH
> > kernel rpm;
> > even if you use lilo the initrd is supposed to be made for you
>
> Is there no overhead (except in boot time) in using initrd?
The initrd memory is freed during the initial boot so there's no overhead.
On Nov 07, 2001 15:33 -0800, Ryan Cumming wrote:
> On November 7, 2001 12:25, Andreas Dilger wrote:
> > If both ext2 and ext3 are compiled into the kernel, then ext3 will try
> > first to mount the root fs. If there is no journal on this fs (check this
> > with tune2fs -l <dev>, and look for "has_journal" feature), then it will be
> > mounted as ext2. If you are doing strange things with initrd and modules,
>
> Is there any particular reason why the ext3 driver can't handle mounting both
> ext2 and ext3 filesystems?
Not really - just an implementation issue. At one point (long ago) I had
started putting in support for this. However, the consensus is that some
people will still want to use the less complex ext2 code instead of ext3
that pretends to be ext2. I imagine that eventually support for mounting
unjournaled ext2 filesystems with the ext3 driver will be added, but there
is no pressing need - you can always use the ext2 driver. Yes, it takes
a bit more memory to have both loaded, but most people who switch to ext3
don't use ext2 filesystems anymore anyways.
Cheers, Andreas
--
Andreas Dilger
http://sourceforge.net/projects/ext2resize/
http://www-mddsp.enel.ucalgary.ca/People/adilger/
Padraig Brady writes:
> When I remove files from a ramfs the space is not reclaimed?
> What am I doing wrong? Details below.
Nothing. We've noticed the same thing. It's a bug and was
first reported back in July, but no one has provided a fix yet.
I've had a brief look at the source code, but nothing obvious
pops out at me.
As you mention, this problem is trivially reproducable by
creating and then deleting a file. Doing that over and over
eventually leads to the ramfs becoming full. Only a reboot
(or perhaps a umount/mount) makes it usable again.
Chris Martin
Catnap Consultants
Hello,
At Fri, 9 Nov 2001 15:40:43 -0500 (EST),
W Christopher Martin wrote:
>
> Padraig Brady writes:
> > When I remove files from a ramfs the space is not reclaimed?
> > What am I doing wrong? Details below.
>
> Nothing. We've noticed the same thing. It's a bug and was
> first reported back in July, but no one has provided a fix yet.
> I've had a brief look at the source code, but nothing obvious
> pops out at me.
I think you should use tmpfs instead of ramfs, but if you really want to use ramfs,
the patch below may fix the problem.
diff -Nur linux-2.4.13-ac7.org/fs/ramfs/inode.c linux-2.4.13-ac7/fs/ramfs/inode.c
--- linux-2.4.13-ac7.org/fs/ramfs/inode.c Mon Nov 12 11:00:47 2001
+++ linux-2.4.13-ac7/fs/ramfs/inode.c Mon Nov 12 11:26:40 2001
@@ -182,12 +182,9 @@
{
struct ramfs_sb_info *rsb = RAMFS_SB(inode->i_sb);
- if (! Page_Uptodate(page))
- return;
-
lock_rsb(rsb);
-
- ClearPageDirty(page);
+ if (Page_Uptodate(page))
+ ClearPageDirty(page);
rsb->free_pages++;
inode->i_blocks -= IBLOCKS_PER_PAGE;
Tachino Nobuhiro wrote:
> Hello,
>
> At Fri, 9 Nov 2001 15:40:43 -0500 (EST),
> W Christopher Martin wrote:
>
>>Padraig Brady writes:
>>
>>>When I remove files from a ramfs the space is not reclaimed?
>>>What am I doing wrong? Details below.
>>>
>>Nothing. We've noticed the same thing. It's a bug and was
>>first reported back in July, but no one has provided a fix yet.
>>I've had a brief look at the source code, but nothing obvious
>>pops out at me.
>>
>
> I think you should use tmpfs instead of ramfs, but if you really want to use ramfs,
> the patch below may fix the problem.
>
> diff -Nur linux-2.4.13-ac7.org/fs/ramfs/inode.c linux-2.4.13-ac7/fs/ramfs/inode.c
> --- linux-2.4.13-ac7.org/fs/ramfs/inode.c Mon Nov 12 11:00:47 2001
> +++ linux-2.4.13-ac7/fs/ramfs/inode.c Mon Nov 12 11:26:40 2001
> @@ -182,12 +182,9 @@
> {
> struct ramfs_sb_info *rsb = RAMFS_SB(inode->i_sb);
>
> - if (! Page_Uptodate(page))
> - return;
> -
> lock_rsb(rsb);
> -
> - ClearPageDirty(page);
> + if (Page_Uptodate(page))
> + ClearPageDirty(page);
>
> rsb->free_pages++;
> inode->i_blocks -= IBLOCKS_PER_PAGE;
>
Cool, this fixes it,
and I was just getting to the bottom of it myself :-)
None of this accounting stuff is in 2.4.15-pre3, so Alan
can you apply this?
cheers,
Padraig.
> and I was just getting to the bottom of it myself :-)
> None of this accounting stuff is in 2.4.15-pre3, so Alan
> can you apply this?
RAMfs is 2.4.16 stuff I think