Bug 1529768 - Disk size is incorrect according to df when an arbiter brick and data brick live on the same server
Summary: Disk size is incorrect according to df when an arbiter brick and data brick l...
Keywords:
Status: CLOSED WORKSFORME
Alias: None
Product: GlusterFS
Classification: Community
Component: posix
Version: mainline
Hardware: Unspecified
OS: Unspecified
low
medium
Target Milestone: ---
Assignee: bugs@gluster.org
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-12-29 21:06 UTC by Ben Edgar
Modified: 2019-06-18 09:47 UTC (History)
4 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2019-06-18 09:47:56 UTC
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Embargoed:


Attachments (Terms of Use)

Description Ben Edgar 2017-12-29 21:06:31 UTC
Description of problem:
When this new feature was released in 3.12 (https://github.com/gluster/glusterfs/blob/release-3.12/doc/release-notes/3.12.0.md#enhanced-the-option-to-export-statfs-data-for-bricks-sharing-the-same-backend-filesystem), now the "df" command is incorrect when listing the available disk space on a server that has one data brick and one arbiter brick.

The arbiter brick should not take up as much space as a data brick since it only contains file metadata, so the actual equation for calculating total space on a server should be: total-space / number-of-data-bricks-at-node, instead of total-space / number-of-bricks-at-node.


Version-Release number of selected component (if applicable):
3.12

How reproducible:
Always

Steps to Reproduce:
1. Create a volume with an arbiter brick and data brick on the same server
     gluster volume create <vol-name> transport tcp replica 3 arbiter 1 server1:/data-brick server2:/data-brick server1:/arbiter-brick
2. Mount the volume on any server
     mount -t glusterfs server1:/<vol-name> /mounted-volume-path
3. Run "df -h" and see that the "Size" column is only half of the total underlying filesystem size instead of the entire underlying filesystem size because a data brick and an arbiter brick reside on the same server.

Actual results:
The Size column shows half of the total size of the underlying filesystem when an arbiter brick and data brick live on the same server.

Expected results:
The Size column should show the total size of the underlying filesystem when an arbiter brick and data brick live on the same server.

Additional info:

Comment 1 Shyamsundar 2018-10-23 14:55:07 UTC
Release 3.12 has been EOLd and this bug was still found to be in the NEW state, hence moving the version to mainline, to triage the same and take appropriate actions.

Comment 2 Ravishankar N 2018-11-19 08:20:51 UTC
AFR does not wind the statfs call to the arbiter brick(s)(http://review.gluster.org/11857). This seems to be something posix_statfs() is doing during accounting when multiple bricks are sharing the same partition/mount-point, irrespective of whether the brick actually received the statfs fop or not. Changing the component to posix for further investigation.

Comment 3 Amar Tumballi 2019-06-18 09:47:56 UTC
Hi Ben,

When the feature got introduced, and later when we upgraded, we found that there were multiple issues with 'shared-brick-count' option. We did fix them up by glusterfs-5.x timeframe, and haven't faced any issue ever since. Closing this as WORKSFORME to highlight that we have not seen it in newer releases. 

Please upgrade to glusterfs-6.x and beyond and see if things are working for you. (Feel free to reopen if not).


Note You need to log in before you can comment on or make changes to this bug.