[Bug 826165] [NEW] blkid breaks on large partitions (BLKGETSIZE)

HelgeJensen helge.jensen at slog.dk
Sun Aug 14 08:43:20 UTC 2011


Public bug reported:

Runnning blkid on a raid5 partition of ~3Tb no data is retrieved.
Smaller partitions works fine.

This is cause by a call to ioctl(_, BLKGETSIZE, _) which returns -1
EFBIG (File too large).

root at myth:/# cat /proc/mdstat
Personalities : [linear] [multipath] [raid0] [raid1] [raid6] [raid5] [raid4] [raid10]
md1 : active raid5 sdd1[2] sdc1[1]
      8386528 blocks super 1.2 level 5, 16k chunk, algorithm 2 [3/2] [_UU]

md0 : active raid5 sdd2[2] sdc2[1]
      2921883360 blocks super 1.2 level 5, 16k chunk, algorithm 2 [3/2] [_UU]

unused devices: <none>


root at myth:/# blkid /dev/md0 /dev/md1
/dev/md1: LABEL="x5" UUID="0c4bdd32-aec9-442e-baa1-e8011f970943" UUID_SUB="0363dc7e-f786-4dad-acc6-e52cc7f075c6" TYPE="btrfs"

Here is the relevant part of an strace of the situation. Notice that
stat64 is used, but BLKGETSIZE64 is not :)

root at myth:/# strace blkid /dev/md0 2>&1  | less
...
stat64("/dev/md0", {st_mode=S_IFBLK|0660, st_rdev=makedev(9, 0), ...}) = 0
open("/dev/md0", O_RDONLY|O_LARGEFILE)  = 3
fadvise64_64(3, 0, 0, POSIX_FADV_RANDOM) = 0
fstat64(3, {st_mode=S_IFBLK|0660, st_rdev=makedev(9, 0), ...}) = 0
uname({sys="Linux", node="myth", ...})  = 0
ioctl(3, BLKGETSIZE, 0xbf9616bc)        = -1 EFBIG (File too large)
close(3)                                = 0
...

ProblemType: Bug
DistroRelease: Ubuntu 11.04
Package: util-linux 2.17.2-9.1ubuntu4
ProcVersionSignature: Ubuntu 3.0-2.3-generic 3.0.0-rc4
Uname: Linux 3.0-2-generic i686
NonfreeKernelModules: nvidia
Architecture: i386
Date: Sun Aug 14 10:33:40 2011
InstallationMedia: Ubuntu 11.04 "Natty Narwhal" - Release i386 (20110427.1)
ProcEnviron:
 LANGUAGE=en_US:en
 PATH=(custom, no user)
 LANG=en_US.UTF-8
 SHELL=/bin/bash
SourcePackage: util-linux
UpgradeStatus: No upgrade log present (probably fresh install)

** Affects: util-linux (Ubuntu)
     Importance: Undecided
         Status: New


** Tags: apport-bug i386 natty

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to util-linux in Ubuntu.
https://bugs.launchpad.net/bugs/826165

Title:
  blkid breaks on large partitions (BLKGETSIZE)

Status in “util-linux” package in Ubuntu:
  New

Bug description:
  Runnning blkid on a raid5 partition of ~3Tb no data is retrieved.
  Smaller partitions works fine.

  This is cause by a call to ioctl(_, BLKGETSIZE, _) which returns -1
  EFBIG (File too large).

  root at myth:/# cat /proc/mdstat
  Personalities : [linear] [multipath] [raid0] [raid1] [raid6] [raid5] [raid4] [raid10]
  md1 : active raid5 sdd1[2] sdc1[1]
        8386528 blocks super 1.2 level 5, 16k chunk, algorithm 2 [3/2] [_UU]

  md0 : active raid5 sdd2[2] sdc2[1]
        2921883360 blocks super 1.2 level 5, 16k chunk, algorithm 2 [3/2] [_UU]

  unused devices: <none>

  
  root at myth:/# blkid /dev/md0 /dev/md1
  /dev/md1: LABEL="x5" UUID="0c4bdd32-aec9-442e-baa1-e8011f970943" UUID_SUB="0363dc7e-f786-4dad-acc6-e52cc7f075c6" TYPE="btrfs"

  Here is the relevant part of an strace of the situation. Notice that
  stat64 is used, but BLKGETSIZE64 is not :)

  root at myth:/# strace blkid /dev/md0 2>&1  | less
  ...
  stat64("/dev/md0", {st_mode=S_IFBLK|0660, st_rdev=makedev(9, 0), ...}) = 0
  open("/dev/md0", O_RDONLY|O_LARGEFILE)  = 3
  fadvise64_64(3, 0, 0, POSIX_FADV_RANDOM) = 0
  fstat64(3, {st_mode=S_IFBLK|0660, st_rdev=makedev(9, 0), ...}) = 0
  uname({sys="Linux", node="myth", ...})  = 0
  ioctl(3, BLKGETSIZE, 0xbf9616bc)        = -1 EFBIG (File too large)
  close(3)                                = 0
  ...

  ProblemType: Bug
  DistroRelease: Ubuntu 11.04
  Package: util-linux 2.17.2-9.1ubuntu4
  ProcVersionSignature: Ubuntu 3.0-2.3-generic 3.0.0-rc4
  Uname: Linux 3.0-2-generic i686
  NonfreeKernelModules: nvidia
  Architecture: i386
  Date: Sun Aug 14 10:33:40 2011
  InstallationMedia: Ubuntu 11.04 "Natty Narwhal" - Release i386 (20110427.1)
  ProcEnviron:
   LANGUAGE=en_US:en
   PATH=(custom, no user)
   LANG=en_US.UTF-8
   SHELL=/bin/bash
  SourcePackage: util-linux
  UpgradeStatus: No upgrade log present (probably fresh install)

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/util-linux/+bug/826165/+subscriptions




More information about the foundations-bugs mailing list