Skip to contentSkip to conversation

Loop devices act strangely in 2.6.35

Bug 16380 [email protected] 1 participant 13 messages Mar 22, 2011 – Feb 7, 2015 1 message not in the archive

lore
Share & tools
lore
#1 lore raw
In reply to a message not in the archive

https://bugzilla.kernel.org/show_bug.cgi?id=16380

Artem S. Tashkinov <[email protected]> changed:

What |Removed |Added
----------------------------------------------------------------------------

          Component|Block Layer                 |ext2
         AssignedTo|[email protected]             |[email protected]
                   |                            |g
            Product|IO/Storage                  |File System

--- Comment #8 from Artem S. Tashkinov <[email protected]> 2011-03-22 22:02:54 --- This is an ext2 fs bug.

Signature · 3 lines
Configure bugmail: https://bugzilla.kernel.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching the assignee of the bug.
#2 lore raw

[Bug 16380] ext2 driver "hangs" for a few seconds when trying to write a lot of data to a freshly RW mounted FS

In reply to a message not in the archive

https://bugzilla.kernel.org/show_bug.cgi?id=16380

Artem S. Tashkinov <[email protected]> changed:

What |Removed |Added
----------------------------------------------------------------------------

            Summary|Loop devices act strangely  |ext2 driver "hangs" for a
                   |in 2.6.35                   |few seconds when trying to
                   |                            |write a lot of data to a
                   |                            |freshly RW mounted FS
Signature · 3 lines
Configure bugmail: https://bugzilla.kernel.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching the assignee of the bug.
#3 lore raw

[Bug 16380] ext2/ext4 filesystem "hangs" for a few seconds when trying to write a lot of data to a freshly RW mounted FS

In reply to a message not in the archive

https://bugzilla.kernel.org/show_bug.cgi?id=16380

Artem S. Tashkinov <[email protected]> changed:

What |Removed |Added
----------------------------------------------------------------------------

          Component|ext2                        |ext4
         AssignedTo|[email protected] |[email protected]
                   |g                           |g
            Summary|ext2 driver "hangs" for a   |ext2/ext4 filesystem
                   |few seconds when trying to  |"hangs" for a few seconds
                   |write a lot of data to a    |when trying to write a lot
                   |freshly RW mounted FS       |of data to a freshly RW
                   |                            |mounted FS
Signature · 3 lines
Configure bugmail: https://bugzilla.kernel.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching the assignee of the bug.
#4 lore raw

[Bug 16380] ext2/ext4 filesystem "hangs" for a few seconds when trying to write a lot of data to a freshly RW mounted FS

In reply to a message not in the archive

https://bugzilla.kernel.org/show_bug.cgi?id=16380

--- Comment #9 from Artem S. Tashkinov <[email protected]> 2012-08-04 11:19:36 --- It's reproducible with ext4fs as well under Linux 3.5.

Signature · 3 lines
Configure bugmail: https://bugzilla.kernel.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching the assignee of the bug.
#5 lore raw

[Bug 16380] ext2/ext4 filesystem "hangs" for a few seconds when trying to write a lot of data to a freshly RW mounted FS

In reply to a message not in the archive

https://bugzilla.kernel.org/show_bug.cgi?id=16380

Prashant Shah <[email protected]> changed:

What |Removed |Added
----------------------------------------------------------------------------
CC| |[email protected]

--- Comment #10 from Prashant Shah <[email protected]> 2012-08-04 11:53:19 --- Didnt face this issue with 3.2.0-23-generic - 64 bit.

Signature · 3 lines
Configure bugmail: https://bugzilla.kernel.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching the assignee of the bug.
#6 lore raw

[Bug 16380] ext2/ext4 filesystem "hangs" for a few seconds when trying to write a lot of data to a freshly RW mounted FS

In reply to a message not in the archive

https://bugzilla.kernel.org/show_bug.cgi?id=16380

--- Comment #11 from Prashant Shah <[email protected]> 2012-08-04 12:16:16 --- (In reply to comment #10)

Quoted 1 line

Didnt face this issue with 3.2.0-23-generic - 64 bit.

Sorry I was able to reproduce it under 3.2.0-23-generic - 64 bit

Signature · 3 lines
Configure bugmail: https://bugzilla.kernel.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching the assignee of the bug.
#7 lore raw

[Bug 16380] ext2/ext4 filesystem "hangs" for a few seconds when trying to write a lot of data to a freshly RW mounted FS

In reply to a message not in the archive

https://bugzilla.kernel.org/show_bug.cgi?id=16380

Artem S. Tashkinov <[email protected]> changed:

What |Removed |Added
----------------------------------------------------------------------------

     Kernel Version|2.6.35                      |2.6.x 3.x
         Regression|Yes                         |No
Signature · 3 lines
Configure bugmail: https://bugzilla.kernel.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching the assignee of the bug.
#8 lore raw

[Bug 16380] ext2/ext4 filesystem "hangs" for a few seconds when trying to write a lot of data to a freshly RW mounted FS

In reply to a message not in the archive

https://bugzilla.kernel.org/show_bug.cgi?id=16380

--- Comment #12 from Theodore Tso <[email protected]> 2012-08-04 18:13:20 --- I wasn't able to duplicate this with an underlying ext4 file system, with the loop file system being ext2, using a 3.5 kernel on a system with 16G.

I tried both using a variety of small and medium sized files, as well as one very large file, and I didn't see any unexplained stuttering in write
bandwidth. (There were times when cp -r was clearly writing to the in-memory
page cache, and the writeback hadn't begone yet. There were also times when
we couldn't do any more writing, because we were busy reading from the source drive. But it all looked pretty normal to me.)

Signature · 3 lines
Configure bugmail: https://bugzilla.kernel.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching the assignee of the bug.
#9 lore raw

[Bug 16380] ext2/ext4 filesystem "hangs" for a few seconds when trying to write a lot of data to a freshly RW mounted FS

In reply to a message not in the archive

https://bugzilla.kernel.org/show_bug.cgi?id=16380

--- Comment #13 from Theodore Tso <[email protected]> 2012-08-04 18:14:08 --- BTW, I was using iostat 1 to measure I/O activity. Call me old-school; I don't exactly trust GUI tools. :-)

Signature · 3 lines
Configure bugmail: https://bugzilla.kernel.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching the assignee of the bug.
#10 lore raw

[Bug 16380] ext2/ext4 filesystem "hangs" for a few seconds when trying to write a lot of data to a freshly RW mounted FS

In reply to a message not in the archive

https://bugzilla.kernel.org/show_bug.cgi?id=16380

--- Comment #14 from Artem S. Tashkinov <[email protected]> 2012-08-04 18:51:24 --- (In reply to comment #12)

Quoted 9 lines

I wasn't able to duplicate this with an underlying ext4 file system, with the loop file system being ext2, using a 3.5 kernel on a system with 16G.

I tried both using a variety of small and medium sized files, as well as one very large file, and I didn't see any unexplained stuttering in write
bandwidth. (There were times when cp -r was clearly writing to the in-memory
page cache, and the writeback hadn't begone yet. There were also times when
we couldn't do any more writing, because we were busy reading from the source drive. But it all looked pretty normal to me.)

Hm, I cannot reproduce the problem with a loop device on top of tmpfs either, but I've just checked my 250GB ext4 partition and the bug is still there:

When I try to copy a 3GB file (residing in tmpfs so it's all cached) to it, there's a 4 (four) seconds delay before a single byte gets written to the destination partition. After that all consequent files get written without any delays.

Signature · 3 lines
Configure bugmail: https://bugzilla.kernel.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching the assignee of the bug.
#11 lore raw

[Bug 16380] ext2/ext4 filesystem "hangs" for a few seconds when trying to write a lot of data to a freshly RW mounted FS

In reply to a message not in the archive

https://bugzilla.kernel.org/show_bug.cgi?id=16380

--- Comment #15 from Theodore Tso <[email protected]> 2012-08-04 19:51:51 --- The delay before the write starts is normal; that's encoded in how the writeback code handles dirty pages. We don't start writes the instant that pages are dirtied in the buffer cache.

In any case, if you have arguments about how the writeback code makes its choices, it's kinda of pointless to be complaining on a bug targetted at the ext4 developers, since we start the writeback when the VM system asks us to start write pages belonging to a particular inode....

See /usr/src/linux/Documentation/sysctl/vm.txt for more information.

Signature · 3 lines
Configure bugmail: https://bugzilla.kernel.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching the assignee of the bug.
#12 lore raw

[Bug 16380] ext2/ext4 filesystem "hangs" for a few seconds when trying to write a lot of data to a freshly RW mounted FS

In reply to a message not in the archive

https://bugzilla.kernel.org/show_bug.cgi?id=16380

Artem S. Tashkinov <[email protected]> changed:

What |Removed |Added
----------------------------------------------------------------------------

             Status|NEW                         |RESOLVED
         Resolution|                            |INVALID

--- Comment #16 from Artem S. Tashkinov <[email protected]> 2012-08-04 20:00:28 --- (In reply to comment #15)

Quoted 10 lines

The delay before the write starts is normal; that's encoded in how the writeback code handles dirty pages. We don't start writes the instant that pages are dirtied in the buffer cache.

In any case, if you have arguments about how the writeback code makes its choices, it's kinda of pointless to be complaining on a bug targetted at the ext4 developers, since we start the writeback when the VM system asks us to start write pages belonging to a particular inode....

See /usr/src/linux/Documentation/sysctl/vm.txt for more information.

Thanks for letting us know, probably what I perceived as a regression in ext4fs was in fact a change in the VM writeback code.

It's still weird and terribly counter intuitive as no other OS exhibit this behavior, but now that I know why it happens I need to file a different bug report.

Signature · 3 lines
Configure bugmail: https://bugzilla.kernel.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching the assignee of the bug.
#13 lore raw

[Bug 16380] ext2/ext4 filesystem "hangs" for a few seconds when trying to write a lot of data to a freshly RW mounted FS

In reply to a message not in the archive

https://bugzilla.kernel.org/show_bug.cgi?id=16380

--- Comment #17 from Artem S. Tashkinov <[email protected]> --- Created attachment 166031
--> https://bugzilla.kernel.org/attachment.cgi?id=166031&action=edit
Video demonstration

I'm NOT reopening this bug report. I'm merely adding a video clip which pertains to it.

Signature · 2 lines
You are receiving this mail because:
You are watching the assignee of the bug.