2001-11-28 06:20:12

by Nathan G. Grennan

[permalink] [raw]
Subject: Unresponiveness of 2.4.16 revisited

Well I tried your patch Andrew. It seemed to have absolutely no effect
on my problem. I used the am-response.patch someone posted the url to
eariler in the first thread, which was just a file of your patch. I
really suggest you try a mozilla source rpm. Not only does it do the
unarchiving, but also patches and rm -rf. I often see a second pause
during the patching after the unarchving. I use

rpm --rebuild mozilla-2001112602_trunk-0_rh7.src.rpm


I also tried Redhat's latest rawhide kernel, 2.4.16-0.1 and it had to
had time same problem. So it isn't fixed by one of their patchs. It is
most likely just a difference between Linus's 2.4.9 and 2.4.16.


2001-11-29 06:31:57

by Andrew Morton

[permalink] [raw]
Subject: Re: Unresponiveness of 2.4.16 revisited

"Nathan G. Grennan" wrote:
>
> Well I tried your patch Andrew. It seemed to have absolutely no effect
> on my problem. I used the am-response.patch someone posted the url to
> eariler in the first thread, which was just a file of your patch. I
> really suggest you try a mozilla source rpm. Not only does it do the
> unarchiving, but also patches and rm -rf. I often see a second pause
> during the patching after the unarchving. I use
>
> rpm --rebuild mozilla-2001112602_trunk-0_rh7.src.rpm
>
> I also tried Redhat's latest rawhide kernel, 2.4.16-0.1 and it had to
> had time same problem. So it isn't fixed by one of their patchs. It is
> most likely just a difference between Linus's 2.4.9 and 2.4.16.

Nathan,

I can reproduce the 30 second stall on ext3. It is due to
ext3's journalling of atime updates. Even though everything
is in cache, running an application requires a write to the
inode. If there's a lot of write activity going on, this can
occasionally cause the seemingly-read-only caller to get stuck
on the queue behind a huge amount of writes. So of course the
read-latency improvements don't help.

The 2.2 kernel's version of ext3 didn't journal atime updates,
and this may be a reason for going back to that scheme. Needs
thought and more testing.

However I can't reproduce the stalls on ext2, and I would expect
the 2.4.9 kernel's ext3 to be demonstrating the same stalls.

Could you please confirm that the stalls happen with ext2 as well,
and could you please test ext2 and ext3 with the `noatime' mount
option?

Thanks.

2001-11-29 09:07:47

by Nathan G. Grennan

[permalink] [raw]
Subject: Re: Unresponiveness of 2.4.16 revisited

On Thu, 2001-11-29 at 02:14, Andrew Morton wrote:

>
> If you can generate hard numbers (just time the RP command, for a start)
> and they show regression, then go ahead and post!
>
> Let's put the atime thing down as a known ext3 problem for a
> while. (does it happen with ext2? You sure?).
>
> Running noatime won't hurt a thing. It just prevents the kernel
> from recording when a file was last accessed, within the file's
> inode. It's a feature whichis used by backup/archiving programs,
> and probably by mailbox monitoring programs (xbiff, etc). People
> turn it off all the time...

ok, I doubled checked things. It seems mounting an ext3 filesystem as
ext2 is somewhat a myth. If the kernel supports ext3 it still mounts it
as ext3 even if /etc/fstab says ext2. When I tried 2.4.16 with ext3
support, but with the journal exactly removed to make it a ext2
filesystem the --rebuild worked just like it does in 2.4.9-13. So it
does seem to be a problem with just ext3, and I guess they changed the
journaling of atimes between the version in 2.4.9-13 and 2.4.16. It all
now makes sense. Thank you for your help.

As for my comment before and Rik's VM vs AA's VM on cache agressiveness,
it looks like I was off. It just seems to vary on some dynamic. I
thought I checked them at the same points after boot, but between
different boots seemed to get different results, who knows.

2001-11-29 09:32:49

by Oktay Akbal

[permalink] [raw]
Subject: Re: Unresponiveness of 2.4.16 revisited

On 29 Nov 2001, Nathan G. Grennan wrote:

> ok, I doubled checked things. It seems mounting an ext3 filesystem as
> ext2 is somewhat a myth. If the kernel supports ext3 it still mounts it
> as ext3 even if /etc/fstab says ext2.

really on other partitions than root-fs ?

--
Oktay Akbal

2001-11-29 16:49:30

by Nathan G. Grennan

[permalink] [raw]
Subject: Re: Unresponiveness of 2.4.16 revisited

On Thu, 2001-11-29 at 03:32, Oktay Akbal wrote:
> On 29 Nov 2001, Nathan G. Grennan wrote:
>
> > ok, I doubled checked things. It seems mounting an ext3 filesystem as
> > ext2 is somewhat a myth. If the kernel supports ext3 it still mounts it
> > as ext3 even if /etc/fstab says ext2.
>
> really on other partitions than root-fs ?
>
> --
> Oktay Akbal

I am not positive about mounting non-root filesystems. I would suspect
it is just a problem with root filesystems.

2001-11-29 18:10:07

by Oktay Akbal

[permalink] [raw]
Subject: Re: Unresponiveness of 2.4.16 revisited

> > > ok, I doubled checked things. It seems mounting an ext3 filesystem as
> > > ext2 is somewhat a myth. If the kernel supports ext3 it still mounts it
> > > as ext3 even if /etc/fstab says ext2.
> >
> > really on other partitions than root-fs ?
> >
> > --
> > Oktay Akbal
>
> I am not positive about mounting non-root filesystems. I would suspect
> it is just a problem with root filesystems.

Why do you think that fstab matters for root-fs ? root-fs needs to be
mounted to read fstab. So autodetection must be done for root-fs.
And if the fs has a journal it is ext3. If you do not want that behaviour
you might use a option to lilo, but I don't know of any option to specify
the root-fs-tyoe. Or you need to use an initrd to mount explicit as ext2
and pivot-root it to / ?

--
Oktay Akbal

2001-11-29 18:16:56

by Nathan G. Grennan

[permalink] [raw]
Subject: Re: Unresponiveness of 2.4.16 revisited

On Thu, 2001-11-29 at 12:09, Oktay Akbal wrote:
> Why do you think that fstab matters for root-fs ? root-fs needs to be
> mounted to read fstab. So autodetection must be done for root-fs.
> And if the fs has a journal it is ext3. If you do not want that behaviour
> you might use a option to lilo, but I don't know of any option to specify
> the root-fs-tyoe. Or you need to use an initrd to mount explicit as ext2
> and pivot-root it to / ?
>
> --
> Oktay Akbal

Actually, I think it should respect fstab. It does mount it, then fsck
it while mounted read-only, then remounts(key point) read-write. IMHO it
should remount it with whatever fstab says. I realize this could be a
little tricky, but I bet doable.

2001-11-29 18:37:25

by Andreas Dilger

[permalink] [raw]
Subject: Re: Unresponiveness of 2.4.16 revisited

On Nov 29, 2001 12:16 -0600, Nathan G. Grennan wrote:
> On Thu, 2001-11-29 at 12:09, Oktay Akbal wrote:
> > Why do you think that fstab matters for root-fs ? root-fs needs to be
> > mounted to read fstab. So autodetection must be done for root-fs.
> > And if the fs has a journal it is ext3.
>
> Actually, I think it should respect fstab. It does mount it, then fsck
> it while mounted read-only, then remounts(key point) read-write. IMHO it
> should remount it with whatever fstab says. I realize this could be a
> little tricky, but I bet doable.

Well, then you would be wrong. The only case where this really matters
is if you are using ext3/ext2 because all other cases will be autodetected
as only a single fs type (OK, maybe msdos/vfat, but who would use that as
root, I don't know, and it still has the same issues).

Once the root filesystem is mounted, and init (+ rc.sysinit or whatever
your startup scripts are) is run, your filesystem is in use. How do you
expect to remount it as a different filesystem while it is in use? Note
that _today's_ ext2 and ext3 are totally separate drivers, so you cannot
"remount" from one driver to another. Maybe in the future it would be
possible for the ext3 filesystem driver to support ext2 (i.e. unjournaled),
but not today, and it would be even less likely to allow stopping journaling
on the filesystem once it is started (journaling is complex business).

> > If you do not want that behaviour
> > you might use a option to lilo, but I don't know of any option to specify
> > the root-fs-tyoe. Or you need to use an initrd to mount explicit as ext2
> > and pivot-root it to / ?

Well, the lilo option you want is "rootfstype=ext2". It is part of 2.4.15.
Put it into an "append=" statement in lilo (per kernel, or global). Even
so, 99.9% of people who can use ext3 do not want to go back to ext2.

Cheers, Andreas
--
Andreas Dilger
http://sourceforge.net/projects/ext2resize/
http://www-mddsp.enel.ucalgary.ca/People/adilger/

2001-11-29 21:12:44

by Mike Fedyk

[permalink] [raw]
Subject: Re: Unresponiveness of 2.4.16 revisited

On Wed, Nov 28, 2001 at 10:30:32PM -0800, Andrew Morton wrote:
> "Nathan G. Grennan" wrote:
> >
> > Well I tried your patch Andrew. It seemed to have absolutely no effect
> > on my problem. I used the am-response.patch someone posted the url to
> > eariler in the first thread, which was just a file of your patch. I
> > really suggest you try a mozilla source rpm. Not only does it do the
> > unarchiving, but also patches and rm -rf. I often see a second pause
> > during the patching after the unarchving. I use
> >
> > rpm --rebuild mozilla-2001112602_trunk-0_rh7.src.rpm
> >
> > I also tried Redhat's latest rawhide kernel, 2.4.16-0.1 and it had to
> > had time same problem. So it isn't fixed by one of their patchs. It is
> > most likely just a difference between Linus's 2.4.9 and 2.4.16.
>
> Nathan,
>
> I can reproduce the 30 second stall on ext3. It is due to

Just recently I had to run badblocks -ws on a scsi hard drive. It was on
its own scsi controller. During the write portions, I was able to see
pauses of 1-5 seconds. Mouse didn't move, nothing. During the read
(compare) portion, there were no such pauses.

This was on vanilla 2.4.16. 2x366 celeron, and 256MB ram. Only reading with
mutt, and irc. gkrellm showed the pauses.

00:00.0 Host bridge: Intel Corp. 440LX/EX - 82443LX/EX Host bridge (rev 03)
00:01.0 PCI bridge: Intel Corp. 440LX/EX - 82443LX/EX AGP bridge (rev 03)
00:07.0 ISA bridge: Intel Corp. 82371AB PIIX4 ISA (rev 01)
00:07.1 IDE interface: Intel Corp. 82371AB PIIX4 IDE (rev 01)
00:07.2 USB Controller: Intel Corp. 82371AB PIIX4 USB (rev 01)
00:07.3 Bridge: Intel Corp. 82371AB PIIX4 ACPI (rev 01)
00:08.0 SCSI storage controller: Adaptec AIC-7881U (rev 01)
00:0a.0 Ethernet controller: Digital Equipment Corporation DECchip 21041 [Tulip Pass 3] (rev 21)
00:0b.0 Ethernet controller: Intel Corp. 82557 [Ethernet Pro 100] (rev 08)
01:00.0 VGA compatible controller: Matrox Graphics, Inc. MGA G100 [Productiva] AGP (rev 01)

mf

2001-12-01 12:18:01

by Bill Davidsen

[permalink] [raw]
Subject: Re: Unresponiveness of 2.4.16 revisited

On Thu, 29 Nov 2001, Nathan G. Grennan wrote:

> On Thu, 2001-11-29 at 12:09, Oktay Akbal wrote:
> > Why do you think that fstab matters for root-fs ? root-fs needs to be
> > mounted to read fstab. So autodetection must be done for root-fs.
> > And if the fs has a journal it is ext3. If you do not want that behaviour
> > you might use a option to lilo, but I don't know of any option to specify
> > the root-fs-tyoe. Or you need to use an initrd to mount explicit as ext2
> > and pivot-root it to / ?

> Actually, I think it should respect fstab. It does mount it, then fsck
> it while mounted read-only, then remounts(key point) read-write. IMHO it
> should remount it with whatever fstab says. I realize this could be a
> little tricky, but I bet doable.

Using the precognition() system call no doubt. It can't read fstab without
mounting, how can kernel use fstab to mount to read fstab? Original
response was correct, you need to learn to use initrd.

--
bill davidsen <[email protected]>
CTO, TMR Associates, Inc
Doing interesting things with little computers since 1979.