On Mon, Apr 9, 2012 at 10:53 AM, Calvin Walton <calvin.wal...@kepstin.ca> wrote:
>
> Hi,
>
> I have a system that's using a dracut-generated initramfs to mount a
> btrfs root. After upgrading to kernel 3.4.0-rc2 to test it out, I've
> noticed that the process of mounting the root filesystem takes much
> longer with 3.4.0-rc2 than it did with 3.3.1 - nearly 30 seconds slower!
>
> Does anyone have any ideas? I'm going to try bisecting the issue to see
> if I can narrow down the cause. I've included excerpts from dmesg of the
> bad and good kernels here, and attached the complete dmesg from the bad
> kernel, in case it has anything interesting that I've trimmed out here.
>
> slow:
> [    0.000000] Linux version 3.4.0-rc2 (cwalton@ayu) (gcc version 4.6.3
> (Exherbo gcc-4.6.3) ) #57 SMP PREEMPT Mon Apr 9 11:19:43 EDT 2012
> [    0.000000] Command line:
> root=UUID=43969cd0-4aca-4297-bfbe-952a692f7d55
> rootflags=subvolid=262,compress=lzo,autodefrag,space_cache,inode_cache,noatime
> mtrr_chunk_size=512M quiet
> <snip>
> [    1.058257] udevd[701]: starting version 182
> [    1.389606] device label Linux data devid 1 transid 611923 /dev/sda4
> [    1.498659] dracut: Checking, if btrfs device complete
> [    1.644808] device label Linux data devid 1 transid 611923 /dev/sda4
> [    1.647993] btrfs: disk space caching is enabled
> [    2.180836] device label Linux data devid 1 transid 611923 /dev/sda4
> [    2.181663] btrfs: use lzo compression
> [    2.181667] btrfs: enabling auto defrag
> [    2.181670] btrfs: enabling inode map caching
> [    2.181672] btrfs: disk space caching is enabled
> [    2.697845] dracut: Checking btrfs:
> /dev/disk/by-uuid/43969cd0-4aca-4297-bfbe-952a692f7d55
> [    2.699999] dracut: trying to mount
> /dev/disk/by-uuid/43969cd0-4aca-4297-bfbe-952a692f7d55
> [    2.702637] device label Linux data devid 1 transid 611923 /dev/sda4
> [    2.704376] btrfs: disk space caching is enabled
> [    3.081720] dracut: btrfs:
> /dev/disk/by-uuid/43969cd0-4aca-4297-bfbe-952a692f7d55 is clean
> [   29.934639] dracut: Remounting
> /dev/disk/by-uuid/43969cd0-4aca-4297-bfbe-952a692f7d55 with -o
> subvolid=262,compress=lzo,autodefrag,space_cache,inode_cache,noatime,ro
> [   29.936810] device label Linux data devid 1 transid 611926 /dev/sda4
> [   29.937720] btrfs: use lzo compression
> [   29.937726] btrfs: enabling auto defrag
> [   29.937733] btrfs: enabling inode map caching
> [   29.937735] btrfs: disk space caching is enabled
> [   30.388066] dracut: Mounted root filesystem /dev/sda4
> [   30.461884] dracut: Switching root
> [   31.241729] udevd[1322]: starting version 182
> [   31.422905] btrfs: use lzo compression
> [   31.422909] btrfs: enabling auto defrag
> [   31.422913] btrfs: enabling inode map caching
> [   31.422915] btrfs: disk space caching is enabled
>
> vs fast:
> [    0.000000] Linux version 3.3.1 (cwalton@ayu) (gcc version 4.6.3
> (Exherbo gcc-4.6.3) ) #53 SMP PREEMPT Wed Apr 4 01:20:47 EDT 2012
> [    0.000000] Command line:
> root=UUID=43969cd0-4aca-4297-bfbe-952a692f7d55
> rootflags=subvolid=262,compress=lzo,autodefrag,space_cache,inode_cache,noatime

Calvin, I noticed that you have the space_cache mount option set. I
remember josef saying that it is a one-time option where it's a
permanent change after mounting for the first time, therefore each
subsequent mount will not require the option. In fact, if the option
is specified again, the space_cache is reset.

Is this still up-to-date info?


> mtrr_chunk_size=512M quiet
> <snip>
> [    1.060117] udevd[695]: starting version 182
> [    1.344328] device label Linux data devid 1 transid 611917 /dev/sda4
> [    1.384888] dracut: Checking, if btrfs device complete
> [    1.405121] device label Linux data devid 1 transid 611917 /dev/sda4
> [    1.405905] btrfs: disk space caching is enabled
> [    1.971953] device label Linux data devid 1 transid 611917 /dev/sda4
> [    1.972519] btrfs: use lzo compression
> [    1.972523] btrfs: enabling auto defrag
> [    1.972526] btrfs: enabling inode map caching
> [    1.972528] btrfs: disk space caching is enabled
> [    2.528540] dracut: Checking btrfs:
> /dev/disk/by-uuid/43969cd0-4aca-4297-bfbe-952a692f7d55
> [    2.530725] dracut: trying to mount
> /dev/disk/by-uuid/43969cd0-4aca-4297-bfbe-952a692f7d55
> [    2.558285] device label Linux data devid 1 transid 611917 /dev/sda4
> [    2.559087] btrfs: disk space caching is enabled
> [    3.013103] dracut: btrfs:
> /dev/disk/by-uuid/43969cd0-4aca-4297-bfbe-952a692f7d55 is clean
> [    3.518807] dracut: Remounting
> /dev/disk/by-uuid/43969cd0-4aca-4297-bfbe-952a692f7d55 with -o
> subvolid=262,compress=lzo,autodefrag,space_cache,inode_cache,noatime,ro
> [    3.520031] device label Linux data devid 1 transid 611920 /dev/sda4
> [    3.520680] btrfs: use lzo compression
> [    3.520684] btrfs: enabling auto defrag
> [    3.520688] btrfs: enabling inode map caching
> [    3.520689] btrfs: disk space caching is enabled
> [    4.066285] dracut: Mounted root filesystem /dev/sda4
> [    4.120861] dracut: Switching root
> [    4.995934] btrfs: use lzo compression
> [    4.995938] btrfs: enabling auto defrag
> [    4.995942] btrfs: enabling inode map caching
> [    4.995943] btrfs: disk space caching is enabled
> [    5.010473] udevd[1330]: starting version 182
>
> --
> Calvin Walton <calvin.wal...@kepstin.ca>
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to