btrfs replace status over 100%

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi all

I had to replace an 10TiB disk. The replacing works well, but the status shows me values over 100%!

  btrfs replace status -1 /export/backup/group/dphys
  209.5% done, 0 write errs, 0 uncorr. read errs

I use btrfs-progs version 4.0.1 (master) from
git://git.kernel.org/pub/scm/linux/kernel/git/kdave/btrfs-progs.git

and im running a 4.5.0-rc4 kernel from
https://git.kernel.org/cgit/linux/kernel/git/stable/linux-stable.git

I had done some calculations and the deviation of the status value is around factor 4.

This mean 209.5% from the replace status is in real live only around 52.4%.

After source code digging, i stuck on the following kernel code lines:

fs/btrfs/dev-replace.c:674

case BTRFS_IOCTL_DEV_REPLACE_STATE_SUSPENDED:
  srcdev = dev_replace->srcdev;
  args->status.progress_1000 = div_u64(dev_replace->cursor_left,
	div_u64(btrfs_device_get_total_bytes(srcdev), 1000));

is there a possibility that "dev_replace->cursor_left" and "btrfs_device_get_total_bytes(srcdev)" dont have the same unit?

or I'm totally wrong?

Thanks Patrick
--
Patrick Schmid  <schmid@xxxxxxxxxxxx>     support: +41 44 633 2668
IT Services Group, HPT H 8                voice:   +41 44 633 3997
Departement Physik, ETH Zurich
CH-8093 Zurich, Switzerland
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Filesystem Development]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux