Bug 1475133 - Files are not rebalanced if destination brick(available size) is of smaller size than source brick(available size)
Summary: Files are not rebalanced if destination brick(available size) is of smaller s...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Gluster Storage
Classification: Red Hat Storage
Component: distribute
Version: rhgs-3.3
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: RHGS 3.5.0
Assignee: Nithya Balachandran
QA Contact: Sayalee
URL:
Whiteboard:
Depends On:
Blocks: 1290124 1529440 1530455 1696807
TreeView+ depends on / blocked
 
Reported: 2017-07-26 06:52 UTC by Nag Pavan Chilakam
Modified: 2019-10-30 12:20 UTC (History)
4 users (show)

Fixed In Version: glusterfs-6.0-1
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1529440 (view as bug list)
Environment:
Last Closed: 2019-10-30 12:19:37 UTC
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHEA-2019:3249 0 None None None 2019-10-30 12:20:11 UTC

Description Nag Pavan Chilakam 2017-07-26 06:52:42 UTC
Description of problem:
=======================
When we add a brick which is of smaller size, when we trigger rebalance, files are not moved from the src_brick to dst_brick if src_available_space >dst_available_space
Below are the problems due to this situation
1)we must not be checking dst_available_space but , rather see if the file being migrated has sufficient space to fit in the dst_brick or not
2)even though we are not migrating, we scan whole filesystem, everytime a rebalance is triggered. This is waste of cpu cycles. 
Agree, that layout fixing happens, but fixing would have happened as part of first rebalance completion. We don't have to probably try to fix everytime, given that when i am writing new files, they are anyways getting distributed b/w bricks, and it is only old files, which needs to be rebalanced(ie due to add brick), and first rebalance would have ideally done fix layout. yes there can be exceptions, like the layout fixing may not have been compeleted due to abort or stop by user or unexpected events



Version-Release number of selected component (if applicable):
=========
3.8.4-35


How reproducible:
=========
always

Steps to Reproduce:
1.create a distribute(or distrep) volume with all bricks of say 10GB
2.do some IOs
3.now add brick of size lesser than 10gb say 5gb
3.trigger rebalance
4. add new files
5. from backend, add a file of 5gb on old bricks(to make dst_avail_size >src_avail_size)

Actual results:
==========
after step 3, rebalance completes, but no files are migrated
with step4, new files are distributed as per hashing
with step 5, now rebalance will migrate some old files to dst, but it does only till src_avail_size <dst_avail_size

Comment 2 Nag Pavan Chilakam 2017-07-26 06:55:04 UTC
seems to be a day1 issue and anyways we have a work around of using force command if we want to really force the migration, hence not proposing for 3.3.0

Comment 3 Nithya Balachandran 2017-07-26 08:38:54 UTC
Correct. This is a day 1 issue and there is a workaround. Hence moving this to 3.3-beyond

Comment 5 Nithya Balachandran 2018-01-03 05:34:45 UTC
Upstream patch: https://bugzilla.redhat.com/show_bug.cgi?id=1529440

Comment 12 errata-xmlrpc 2019-10-30 12:19:37 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHEA-2019:3249


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