REFS - to defag or not to defrag... that's the question?

Availability for the Always-On Enterprise

REFS - to defag or not to defrag... that's the question?

Veeam Logoby enoch » Sun Jun 04, 2017 4:41 pm

Hi all,

Defrag Tool in Windows 2016 pretty quicky shows 70%+ and defragmentation needed.

Should this be done on a daily or weekly basis?

With "large" REFS 3.1 volumes 40 TB+, will a defragmentation run ever be "finished"?
enoch
Service Provider
 
Posts: 114
Liked: 8 times
Joined: Sat Jun 29, 2013 12:14 pm
Full Name: Peter Enoch

Re: REFS - to defag or not to defrag... that's the question?

Veeam Logoby dellock6 » Mon Jun 05, 2017 7:26 am

I have some doubts about defragging a REFS filesystem, especially if blockclone is used. If a block is used by more than one file, how defrag is going to choose where to place the block? Say the blocks of a file are 1-2-3-4 for file1, and 5-2-6-7 for file2. If I defrag blocks to optimize file1, chances are that the same block will not be optimized for file2.
Luca Dell'Oca
EMEA Cloud Architect @ Veeam Software

@dellock6
http://www.virtualtothecore.com
vExpert 2011-2012-2013-2014-2015-2016
Veeam VMCE #1
dellock6
Veeam Software
 
Posts: 4989
Liked: 1308 times
Joined: Sun Jul 26, 2009 3:39 pm
Location: Varese, Italy
Full Name: Luca Dell'Oca

Re: REFS - to defag or not to defrag... that's the question?

Veeam Logoby enoch » Mon Jun 05, 2017 7:54 am

Thanks for the reply, would be nice for a complete "best practice" for REFS and Veeam.

So I should deactivate defrag for all REFS volumes being used with Veeam and Block Cloning?
enoch
Service Provider
 
Posts: 114
Liked: 8 times
Joined: Sat Jun 29, 2013 12:14 pm
Full Name: Peter Enoch

Re: REFS - to defag or not to defrag... that's the question?

Veeam Logoby enoch » Mon Jun 05, 2017 10:26 am

Luca, can Veeam test/get back if running defrag on REFS with Veeam (using Block cloning) is recommended or not?

Tried with the blockstat.exe / blockcomparerefs.ps1 script and it still after running defrag shows "savings"

Link: http://dewin.me/refs/
enoch
Service Provider
 
Posts: 114
Liked: 8 times
Joined: Sat Jun 29, 2013 12:14 pm
Full Name: Peter Enoch

Re: REFS - to defag or not to defrag... that's the question?

Veeam Logoby tsightler » Mon Jun 05, 2017 1:18 pm

Luca's point was that defrag is unlikely to be useful for ReFS when block cloning is in use simply because it's impossible for a single block to be in an optimal location for more than one file. Simple example:

File1 -- |Block1|Block2|Block3|Block4|
File2 -- |Block5|Block2|Block6|Block4|

In this example, File1 has four blocks of 64K each (cluster size) laid out in order on the disk, so 0% fragmentation. File2 is sharing two blocks from File1, so it is immediately 50% fragmented. There's simply no way to avoid this when cloning the same blocks between files, there's nothing defragmentation can do about this, if I defragmented File2 then File1 would be fragemented.

At this point I'm not recommending file system defragmentation runs on ReFS until more testing is complete (I haven't found it to cause any issues, but so far also no benefit, just wasted I/O). However, if you are using one of the forever modes, such as reverse incremental or forward incremental without synthetic/active fulls, then using the Veeam settings for defrag and compact can still be useful to clean unsused space and reorganize the metadata within the VBK file.
tsightler
Veeam Software
 
Posts: 4737
Liked: 1728 times
Joined: Fri Jun 05, 2009 12:57 pm
Full Name: Tom Sightler

Re: REFS - to defag or not to defrag... that's the question?

Veeam Logoby enoch » Mon Jun 05, 2017 1:24 pm

Thanks for the answer :D
enoch
Service Provider
 
Posts: 114
Liked: 8 times
Joined: Sat Jun 29, 2013 12:14 pm
Full Name: Peter Enoch


Return to Veeam Backup & Replication



Who is online

Users browsing this forum: Bing [Bot] and 26 guests