0% found this document useful (0 votes)
172 views5 pages

Blogs Sap Com 2020 09 11 How To Reclaim Fragmented Space at Os Level From Hana D

how-to-reclaim-fragmented-space-at-os-level-from-hana

Uploaded by

Prasad Boddapati
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
172 views5 pages

Blogs Sap Com 2020 09 11 How To Reclaim Fragmented Space at Os Level From Hana D

how-to-reclaim-fragmented-space-at-os-level-from-hana

Uploaded by

Prasad Boddapati
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

A New Home in New Year for SAP Community: Exciting times ahead for the SAP 

Community!
Not yet a member on the new home? Join today and start participating in the discussions!

Read about the migration and join SAP Community Groups!

Ask a Question Write a Blog Post Login / Sign-up

Technical Articles

Rajarajeswari Kaliyaperumal
September 11, 2020 | 2 minute read

How to reclaim fragmented space at OS level from HANA Data


volume

 2  8  25,627

DATA VOLUME DEFRAGMENTATION:

In this blog we can learn about how to run a de-fragmentation data volume to claim unused space from data
volumes.

Why do we have fragmented space in data volume?

In HANA if we have run a mass cleanup, though the relevant tables entries that were deleted will be removed
and the size reduction will get re ected in M_TABLE_PERSISTENCE_STATISTICS for all the involved tables,
it takes time to get re ected at OS level.

Is this operation needs downtime?

No.This is an ONLINE operation and does not need a downtime. However , it is recommended to perform
this when we have a reduced load in the HANA DB.

This
How tosite uses cookies
determine andHANA
if our relatedDB
technologies,
is su eringas described
from huge in our privacy
unused statement, fordate
fragmented purposes thatvolume?
in data may include site
operation, analytics, enhanced user experience, or advertising. You may choose to consent to our use of these
technologies, or manage your own preferences.
To determine the amount of space that is fragmented , we can use below SQL.

Manage Settings Accept All Reject All


select * from
Cookie SYS.M_VOLUME_FILES WHERE FILE_TYPEManage
Statement Settings
= ‘DATA’ Accept All Reject All

Sample output: Each of the le system is allocate with a 6TB of space.

To reclaim the fragmented space below is the command to be used :

ALTER SYSTEM RECLAIM DATAVOLUME 120 DEFRAGMENT;=>Our nal data volume size will be payload +
20% fragmented space =>Can be used normally

If we want to run defragment only on speci c node the we can use the below command:

ALTER SYSTEM RECLAIM DATAVOLUME ‘<node server name>:3<nn>03’ 120 DEFRAGMENT; =>Our nal
data volume size will be payload + 20% fragmented space =>Can be used normally

NOTE:
If the fragmentation percentage is really huge, it will take a lot of time and performance issue if we try to
defragment our data volume to 120% . In this case , it is recommended to run the same command in pieces
like below . It is better to ensure that we are reclaiming only 250GB per defragment command.

You can also refer below link


https://kb.netapp.com/app/answers/answer_view/a_id/1001534/~/reduction-of-sap-hana-database-
volume-using-the-alter-system-reclaim

Below is the sample output for disk defragmentation which was run from HANACLeaner:

Refer below to use HANACleaner to automate this process

https://blogs.sap.com/2020/09/16/how-to-implement-hanacleaner/

Thanks for reading!!

Please leave your comments and questions here!!

Follow  Like  RSS Feed


Alert Moderator

Assigned Tags

SAP HANA, express edition

Basis Technology

SAP HANA

SAP HANA, platform edition

cleanup

DataVolume

fragmentation

View more... 

Similar Blog Posts 


Did you know that running a reorganization or mass cleanup in HANA will increase data volume usage at FS
by minimum of 25%-50%
By Rajarajeswari Kaliyaperumal Sep 13, 2020

Collected information about reclaim / shrink / defragmentation topic in context of SAP HANA persistence
(with example)
By Laszlo Thoma Jan 17, 2023

Refreshing HANA systems involving XSA tenants


By Rajarajeswari Kaliyaperumal May 12, 2021

Related Questions 
EC2 and VM - File systems creation from AWS and Azure portal directly
By Daniel basis Jul 14, 2023

SAP HANA Backup Catalog


By K Hari Govind Jan 08, 2020

SAP HANA, express edition + Apps, with Docker - XSA - xs create space
By Alexandr Poslovskiy Oct 23, 2020

2 Comments

You must be Logged on to comment or reply to a post.

Shrikant Pakhale
December 22, 2022 at 3:28 am

after reclaim datavolume, size of data backup was reduced ... How athese are related ?

Like 1 | Share

Bimila W J
October 9, 2023 at 4:34 am

After performing data volume reclaim (2 times) also fragmentation is not reducing . Hana version is
"2.00.059.04.1655794895" kindly suggest . db is replicated

Like 0 | Share

Find us on

Privacy Terms of Use

Legal Disclosure Copyright

Trademark Cookie Preferences

Newsletter Support

You might also like