Oracle Autonomous Health Framework (Former TFA)

Oracle Autonomous Health Framework is a collection of components that analyzes the diagnostic data collected, and proactively identifies issues before they affect the health of your clusters or your Oracle Real Application Clusters (Oracle RAC) databases. Oracle Autonomous Health Framework contains Oracle ORAchk, Oracle EXAchk, and Oracle Trace File Analyzer.

Install Oracle Autonomous Health Framework as root to obtain the fullest capabilities. Oracle Autonomous Health Framework has reduced capabilities when you install it as a non-root user.AFH can be run in two different modes either as daemon or Non-daemon mode. Both are doing same thing but daemon mode is more preferred.

To install as root:

  1. Down load the Oracle Autonomous Health Framework zipped file and copy it to oracle database server and zip
  2. Run ahf_setup 
[root@roll ~]# ./ahf_setup
 
AHF Installer for Platform Linux Architecture x86_64
 
AHF Installation Log : /tmp/ahf_install_89093_2020_02_13-11_48_11.log
 
Starting Autonomous Health Framework (AHF) Installation
 
AHF Version: 193200 Build Date: 201911251327
 
Default AHF Location : /opt/oracle.ahf
 
Do you want to change AHF Location (/opt/oracle.ahf) ? Y|[N] : N
 
AHF Location : /opt/oracle.ahf
 
AHF Data Directory stores diagnostic collections and metadata.
AHF Data Directory requires at least 5GB (Recommended 10GB) of free space.
 
Choose Data Directory from below options : 
 
1. /opt/oracle.ahf [Free Space : 15811 MB]
2. /u02/app/grid/base [Free Space : 9158 MB]
3. Enter a different Location
 
Choose Option [1 - 3] : 1
 
AHF Data Directory : /opt/oracle.ahf/data
 
Do you want to add AHF Notification Email IDs ? [Y]|N : N
 
AHF will also be installed/upgraded on these Cluster Nodes :
 
1. stone
 
The AHF Location and AHF Data Directory must exist on the above nodes
AHF Location : /opt/oracle.ahf
AHF Data Directory : /opt/oracle.ahf/data
 
Do you want to install/upgrade AHF on Cluster Nodes ? [Y]|N : Y
 
Extracting AHF to /opt/oracle.ahf
 
Configuring TFA Services
 
Discovering Nodes and Oracle Resources
 
Not generating certificates as GI discovered
 
Starting TFA Services
Created symlink from /etc/systemd/system/multi-user.target.wants/oracle-tfa.service to /etc/systemd/system/oracle-tfa.service.
Created symlink from /etc/systemd/system/graphical.target.wants/oracle-tfa.service to /etc/systemd/system/oracle-tfa.service.
 
.-------------------------------------------------------------------------.
| Host | Status of TFA | PID   | Port | Version    | Build ID             |
+------+---------------+-------+------+------------+----------------------+
| roll | RUNNING       | 90373 | 5000 | 19.3.2.0.0 | 19320020191125132721 |
'------+---------------+-------+------+------------+----------------------'
 
Running TFA Inventory...
 
Adding default users to TFA Access list...
 
.---------------------------------------------------.
|            Summary of AHF Configuration           |
+-----------------+---------------------------------+
| Parameter       | Value                           |
+-----------------+---------------------------------+
| AHF Location    | /opt/oracle.ahf                 |
| TFA Location    | /opt/oracle.ahf/tfa             |
| Orachk Location | /opt/oracle.ahf/orachk          |
| Data Directory  | /opt/oracle.ahf/data            |
| Repository      | /opt/oracle.ahf/data/repository |
| Diag Directory  | /opt/oracle.ahf/data/roll/diag  |
'-----------------+---------------------------------'
 
 
Starting orachk daemon from AHF ...
 
AHF install completed on roll
 
Installing AHF on Remote Nodes :
 
AHF will be installed on stone, Please wait.
 
AHF will prompt twice to install/upgrade per Remote Node. So total 2 prompts
 
Do you want to continue Y|[N] : Y
 
AHF will continue with Installing on remote nodes
 
Installing AHF on stone :
 
[stone] Copying AHF Installer
root@stone's password: 
 
[stone] Running AHF Installer
root@stone's password: 
 
AHF binaries are available in /opt/oracle.ahf/bin
 
AHF is successfully installed
 
Moving /tmp/ahf_install_89093_2020_02_13-11_48_11.log to /opt/oracle.ahf/data/roll/diag/ahf/

The installation prompts you to do a local or cluster installation.

Cluster installation requires passwordless SSH user equivalency for root to all cluster nodes. If you have not already configured passwordless SSH user equivalency, then the installation optionally sets up passwordless SSH user equivalency and then removes at the end.

If you do not wish to use passwordless SSH, then you install Oracle Autonomous Health Framework on each host using a local installation. Run the tfactl syncnodes command to generate and deploy relevant SSL certificates.

For some reason, AFH installation was not synchronized between the nodes. You can see the TFA print status only show one node. It is supposed to list both nodes. 

[root@roll ~]# /opt/oracle.ahf/bin/tfactl print status
 
.--------------------------------------------------------------------------------------------.
| Host | Status of TFA | PID   | Port | Version    | Build ID             | Inventory Status |
+------+---------------+-------+------+------------+----------------------+------------------+
| roll | RUNNING       | 90373 | 5000 | 19.3.2.0.0 | 19320020191125132721 | COMPLETE         |
'------+---------------+-------+------+------------+----------------------+------------------'
 
[root@stone ~]# /opt/oracle.ahf/bin/tfactl print status
 
.---------------------------------------------------------------------------------------------.
| Host  | Status of TFA | PID   | Port | Version    | Build ID             | Inventory Status |
+-------+---------------+-------+------+------------+----------------------+------------------+
| stone | RUNNING       | 19158 | 5000 | 19.3.2.0.0 | 19320020191125132721 | COMPLETE         |
| roll  | NOT RUNNING   | -     |      |            |                      |                  |
'-------+---------------+-------+------+------------+----------------------+------------------'
 
I went ahead and did a synctfanodes from roll and it asked me root password 4/5 time and finally it was able to sync.
 
[root@roll ~]# /opt/oracle.ahf/tfa/bin/synctfanodes.sh
 
TFA has not yet generated any certificates on this Node.
 
Do you want to generate new certificates to synchronize across the nodes? [Y|N] [Y]: N
 
Exiting Now...
[root@roll ~]# /opt/oracle.ahf/tfa/bin/synctfanodes.sh
 
TFA has not yet generated any certificates on this Node.
 
Do you want to generate new certificates to synchronize across the nodes? [Y|N] [Y]: Y
 
Generating new TFA Certificates...
 
Restarting TFA on roll...
Shutting down TFA
Removed symlink /etc/systemd/system/multi-user.target.wants/oracle-tfa.service.
Removed symlink /etc/systemd/system/graphical.target.wants/oracle-tfa.service.
. . . . . 
. . . 
Successfully shutdown TFA..
Starting TFA..
Created symlink from /etc/systemd/system/multi-user.target.wants/oracle-tfa.service to /etc/systemd/system/oracle-tfa.service.
Created symlink from /etc/systemd/system/graphical.target.wants/oracle-tfa.service to /etc/systemd/system/oracle-tfa.service.
Waiting up to 100 seconds for TFA to be started..
. . . . . 
. . . . . 
. . . . . 
. . . . . 
. . . . . 
. . . . . 
. . . . . 
. . . . . 
. . . . . 
. . . . . 
. . . . . 
. . . . . 
. . . . . 
Successfully started TFA Process..
. . . . . 
TFA Started and listening for commands
 
Current Node List in TFA : 
1. roll
 
Node List in Cluster :
1. roll
2. stone
 
Node List to sync TFA Certificates : 
     1  stone
 
Do you want to update this node list? [Y|N] [N]: .Y
 
Please enter a valid option [Y|N] [N]
 
Do you want to update this node list? [Y|N] [N]: Y
 
Please Enter all the remote nodes you want to sync...
 
Enter Remote Node List (separated by space) : stone
 
Node List to sync TFA Certificates : 
     1  stone
 
Syncing TFA Certificates on stone :
 
TFA_HOME on stone : /opt/oracle.ahf/tfa
 
DATA_DIR on stone : /opt/oracle.ahf/data/stone/tfa
 
Copying TFA Certificates to stone...
root@stone's password: 
Copying SSL Properties to stone...
root@stone's password: 
 
Restarting TFA on stone...
Restarting TFA on stone...
root@stone's password: 
Restarting TFA..
Killing TFA running with pid 19158
Waiting up to 120 seconds for TFA to be re-started..
. . . . . . . . . . 
. . . . . . . . . . 
. . . . . . . . . . 
. . . . . . . . . . 
Successfully re-started TFA..
 
 
.----------------------------------------------------------------------------------------------.
| Host  | Status of TFA | PID    | Port | Version    | Build ID             | Inventory Status |
+-------+---------------+--------+------+------------+----------------------+------------------+
| roll  | RUNNING       | 122979 | 5000 | 19.3.2.0.0 | 19320020191125132721 | COMPLETE         |
| stone | RUNNING       |  55259 | 5000 | 19.3.2.0.0 | 19320020191125132721 | COMPLETE         |
'-------+---------------+--------+------+------------+----------------------+------------------'

You can see the status and it is listing all the nodes.

Uninstalling Oracle Autonomous Health Framework

To uninstall Oracle Autonomous Health Framework, run the uninstall command as root, or install user.

[root@roll ~]# /opt/oracle.ahf/bin/tfactl uninstall
Starting AHF Uninstall
NOTE : Uninstalling does not return all the space used by the AHF repository
AHF will be uninstalled on: 
roll
 
 
Do you want to continue with AHF uninstall ? [Y]|N : Y
 
Stopping AHF service on local node roll...
Stopping TFA Support Tools...
 
Removed symlink /etc/systemd/system/multi-user.target.wants/oracle-tfa.service.
Removed symlink /etc/systemd/system/graphical.target.wants/oracle-tfa.service.
 
TFA-00002 Oracle Trace File Analyzer (TFA) is not running
Removing AHF setup on roll:
Removing /etc/rc.d/rc0.d/K17init.tfa
Removing /etc/rc.d/rc1.d/K17init.tfa
Removing /etc/rc.d/rc2.d/K17init.tfa
Removing /etc/rc.d/rc4.d/K17init.tfa
Removing /etc/rc.d/rc6.d/K17init.tfa
Removing /etc/init.d/init.tfa...
Removing /opt/oracle.ahf/jre
Removing /opt/oracle.ahf/common
Removing /opt/oracle.ahf/bin
Removing /opt/oracle.ahf/python
Removing /opt/oracle.ahf/analyzer
Removing /opt/oracle.ahf/tfa
Removing /opt/oracle.ahf/orachk
Removing /opt/oracle.ahf/ahf
Removing /opt/oracle.ahf/data/roll
Removing /opt/oracle.ahf/data/work
/bin/sh: /opt/oracle.ahf/data/roll/diag/orachk/orachk_daemon_start_130220_113028.log: No such file or directory
/bin/sh: /opt/oracle.ahf/data/roll/diag/orachk/orachk_daemon_start_130220_113028.log: No such file or directory
Removing /opt/oracle.ahf/install.properties

Leave a Reply

Your email address will not be published. Required fields are marked *