Useful Python Scripts for HANA

All python scripts can be found in exe/python_support directory.

These scripts can affect the system therefore it’s better to check with ‘-help’ switch before executing the scripts.

Useful Python Scripts for HANA

systemOverview.py

You can get system information with this script like Instance, Services, Memory, Disk, Memory etc.

python systemOverview.py

Example;

Useful Python Scripts for HANA

landscapeHostConfiguration.py

It gives the host , group roles and status of the landscape.

python landscapeHostConfiguration.py

Example ;

Useful Python Scripts for HANA

HanaHwCheck.py

Check and list complete HW information of the related system.

python HanaHwCheck.py –v

Example;

Useful Python Scripts for HANA

getParameter.py

Checks the values from the file which you execute for.

python getParameter.py –key=<filename>

Example;

Useful Python Scripts for HANA

fullSystemInfoDump.py

Collects diagnosis information from the SAP HANA database

Some options:
-F FROMDATE, –fromDate=FROMDATE
Collects trace files starting from the specified date
(format: YYYY-MM-DD)
-T TODATE, –toDate=TODATE
Collects trace files up to the specified date (format:
YYYY-MM-DD)
-e EXPORTPATH, –exportPath=EXPORTPATH
Path to exported tables/views
-t TENANT, –tenant=TENANT
Specifies the tenant where the files are to be collected

Example;

Useful Python Scripts for HANA

Other some scripts ;

recoverSys.py

You can start the recovery on your database or cancel the active process

HDBSettings.sh recoverSys.py [<parameters>]

Example;

HDBSettings.sh recoverSys.py –command=”RECOVER DATABASE UNTIL TIMESTAMP ‘2018-02-01 09:30:00′”
HDBSettings.sh recoverSys.py –command=”RECOVER DATABASE UNTIL TIMESTAMP ‘2018-02-01 09:30:00’ USING LOG PATH (‘/system/backup/TST/log’) USING BACKUP_ID 1588445415345 CHECK ACCESS USING FILE”

mergeDeltaTable.py

Delta merge on a column table

python mergeDeltaTable.py [options] tableName

memorySizing.py

Analyzes the memory consumption of the system.

memorySizing.py [options]

Measurement Options:
-l LOADTABLES, –loadTables=LOADTABLES
if yes (no), (do not) load tables before sizing
[default: yes]
-i IMMEDIATEUNLOAD, –immediateUnload=IMMEDIATEUNLOAD
immediately unload a table after loading (possible
values: no, unloaded, partially_loaded, all) – only
relevant together with –loadTables yes [default: no]
-m MERGECOMPRESS, –mergeCompress=MERGECOMPRESS
if yes (no), (do not) merge and compress tables before
sizing [default: yes]

Example;

HDBSettings.sh memorySizing.py -a localhost:30015 -u SYSTEM -p ******* -l LOADTABLES

 

 

 

 

 

 

Leave a Reply


six + 9 =

Blogroll