Re: [PATCH] Btrfs: get more accurate output in fd command.

2014-12-11 Thread Dongsheng Yang
On 12/11/2014 03:05 AM, Goffredo Baroncelli wrote: On 12/10/2014 04:02 PM, Dongsheng Yang wrote: On Wed, Dec 10, 2014 at 9:21 PM, Duncan 1i5t5.dun...@cox.net wrote: Robert White posted on Wed, 10 Dec 2014 02:53:40 -0800 as excerpted: [...] And in the example, the mkfs was supplied with two

Re: [PATCH] Btrfs: get more accurate output in fd command.

2014-12-11 Thread Dongsheng Yang
On 12/11/2014 11:53 AM, Duncan wrote: Dongsheng Yang posted on Wed, 10 Dec 2014 23:02:15 +0800 as excerpted: And in the example, the mkfs was supplied with two devices, so there's no dup metadata remaining from a formerly single-device filesystem, either. (Tho there will be the small

Re: [PATCH] Btrfs: get more accurate output in fd command.

2014-12-11 Thread Dongsheng Yang
On 12/11/2014 02:25 AM, Goffredo Baroncelli wrote: On 12/10/2014 11:53 AM, Robert White wrote: On 12/09/2014 05:08 PM, Dongsheng Yang wrote: On 12/10/2014 02:47 AM, Goffredo Baroncelli wrote: Hi Dongsheng On 12/09/2014 12:20 PM, Dongsheng Yang wrote: When function btrfs_statfs() calculate

Re: [PATCH] Btrfs: get more accurate output in fd command.

2014-12-10 Thread Robert White
On 12/09/2014 05:08 PM, Dongsheng Yang wrote: On 12/10/2014 02:47 AM, Goffredo Baroncelli wrote: Hi Dongsheng On 12/09/2014 12:20 PM, Dongsheng Yang wrote: When function btrfs_statfs() calculate the tatol size of fs, it is calculating the total size of disks and then dividing it by a factor.

Re: [PATCH] Btrfs: get more accurate output in fd command.

2014-12-10 Thread Duncan
Robert White posted on Wed, 10 Dec 2014 02:53:40 -0800 as excerpted: On 12/09/2014 05:08 PM, Dongsheng Yang wrote: On 12/10/2014 02:47 AM, Goffredo Baroncelli wrote: Hi Dongsheng On 12/09/2014 12:20 PM, Dongsheng Yang wrote: When function btrfs_statfs() calculate the tatol size of fs, it is

Re: [PATCH] Btrfs: get more accurate output in fd command.

2014-12-10 Thread Shriramana Sharma
On Tue, Dec 9, 2014 at 4:50 PM, Dongsheng Yang yangds.f...@cn.fujitsu.com wrote: # df -h /mnt Filesystem Size Used Avail Use% Mounted on /dev/vdf1 3.0G 1018M 1.3G 45% /mnt LOL -- not being a user of RAID I can't comment on the patch, but I was somewhat wondering what the

Re: [PATCH] Btrfs: get more accurate output in fd command.

2014-12-10 Thread Dongsheng Yang
On Wed, Dec 10, 2014 at 6:53 PM, Robert White rwh...@pobox.com wrote: On 12/09/2014 05:08 PM, Dongsheng Yang wrote: On 12/10/2014 02:47 AM, Goffredo Baroncelli wrote: Hi Dongsheng On 12/09/2014 12:20 PM, Dongsheng Yang wrote: When function btrfs_statfs() calculate the tatol size of fs, it

Re: [PATCH] Btrfs: get more accurate output in fd command.

2014-12-10 Thread Dongsheng Yang
On Wed, Dec 10, 2014 at 9:59 PM, Shriramana Sharma samj...@gmail.com wrote: On Tue, Dec 9, 2014 at 4:50 PM, Dongsheng Yang yangds.f...@cn.fujitsu.com wrote: # df -h /mnt Filesystem Size Used Avail Use% Mounted on /dev/vdf1 3.0G 1018M 1.3G 45% /mnt LOL -- not being a

Re: [PATCH] Btrfs: get more accurate output in fd command.

2014-12-10 Thread Dongsheng Yang
On Wed, Dec 10, 2014 at 9:21 PM, Duncan 1i5t5.dun...@cox.net wrote: Robert White posted on Wed, 10 Dec 2014 02:53:40 -0800 as excerpted: On 12/09/2014 05:08 PM, Dongsheng Yang wrote: On 12/10/2014 02:47 AM, Goffredo Baroncelli wrote: Hi Dongsheng On 12/09/2014 12:20 PM, Dongsheng Yang wrote:

Re: [PATCH] Btrfs: get more accurate output in fd command.

2014-12-10 Thread Goffredo Baroncelli
On 12/10/2014 11:53 AM, Robert White wrote: On 12/09/2014 05:08 PM, Dongsheng Yang wrote: On 12/10/2014 02:47 AM, Goffredo Baroncelli wrote: Hi Dongsheng On 12/09/2014 12:20 PM, Dongsheng Yang wrote: When function btrfs_statfs() calculate the tatol size of fs, it is calculating the total size

Re: [PATCH] Btrfs: get more accurate output in fd command.

2014-12-10 Thread Goffredo Baroncelli
On 12/10/2014 04:02 PM, Dongsheng Yang wrote: On Wed, Dec 10, 2014 at 9:21 PM, Duncan 1i5t5.dun...@cox.net wrote: Robert White posted on Wed, 10 Dec 2014 02:53:40 -0800 as excerpted: [...] And in the example, the mkfs was supplied with two devices, so there's no dup metadata remaining from a

Re: [PATCH] Btrfs: get more accurate output in fd command.

2014-12-10 Thread Robert White
On 12/10/2014 05:21 AM, Duncan wrote: Robert White posted on Wed, 10 Dec 2014 02:53:40 -0800 as excerpted: On 12/09/2014 05:08 PM, Dongsheng Yang wrote: On 12/10/2014 02:47 AM, Goffredo Baroncelli wrote: Hi Dongsheng On 12/09/2014 12:20 PM, Dongsheng Yang wrote: When function btrfs_statfs()

Re: [PATCH] Btrfs: get more accurate output in fd command.

2014-12-10 Thread Goffredo Baroncelli
On 12/10/2014 09:36 PM, Robert White wrote: [...] I tested it and sure enough, it's RAID1... I also noticed that the default for data goes from single to RAID0 in a two slice build. I generally don't expect defaults to change in undocumented ways. Particularly since that makes

Re: [PATCH] Btrfs: get more accurate output in fd command.

2014-12-10 Thread Duncan
Dongsheng Yang posted on Wed, 10 Dec 2014 23:02:15 +0800 as excerpted: And in the example, the mkfs was supplied with two devices, so there's no dup metadata remaining from a formerly single-device filesystem, either. (Tho there will be the small single-mode stubs, empty, remaining from the

[PATCH] Btrfs: get more accurate output in fd command.

2014-12-09 Thread Dongsheng Yang
When function btrfs_statfs() calculate the tatol size of fs, it is calculating the total size of disks and then dividing it by a factor. But in some usecase, the result is not good to user. Example: # mkfs.btrfs -f /dev/vdf1 /dev/vdf2 -d raid1 # mount /dev/vdf1 /mnt # dd

Re: [PATCH] Btrfs: get more accurate output in fd command.

2014-12-09 Thread Goffredo Baroncelli
Hi Dongsheng On 12/09/2014 12:20 PM, Dongsheng Yang wrote: When function btrfs_statfs() calculate the tatol size of fs, it is calculating the total size of disks and then dividing it by a factor. But in some usecase, the result is not good to user. Example: # mkfs.btrfs -f /dev/vdf1

Re: [PATCH] Btrfs: get more accurate output in fd command.

2014-12-09 Thread Dongsheng Yang
On 12/10/2014 02:47 AM, Goffredo Baroncelli wrote: Hi Dongsheng On 12/09/2014 12:20 PM, Dongsheng Yang wrote: When function btrfs_statfs() calculate the tatol size of fs, it is calculating the total size of disks and then dividing it by a factor. But in some usecase, the result is not good to