Capturing Solaris 11.4 (12) Analytics By Using Remote Administration Daemon (RAD) – Part 5

1 Star2 Stars3 Stars4 Stars5 Stars (1 votes, average: 5.00 out of 5)
Loading...

Capturing Your Own Solaris 11.4 (12) Analytics By Using Remote Administration Daemon (RAD) – Part 5

Note: The full code is available in a GitHub repository. to play with the code, feel free to clone the Solaris Analytics Publisher Repository.

This is part 5 out of a series of articles on how to use Oracle Solaris Analytics with your own custom application(s).

  • part 1 how to configure analytics
  • part 2 how to configure the client capture stat process
  • part 3 how to publish the client captured stats.
  • part 4 Configuring / Accessing the Web Dashboard / UI.
  • part 5 Capturing Solaris 11.4 (12) Analytics By Using Remote Administration Daemon (RAD).

Below is an updated on Capturing Solaris 11.4+ Analytics.
In part 1-4 my configuration used a SQLite Database to store local Stats/Analytics data. I then used a Python HTTP daemon to publish and make the results available for a remote Stats store host.

In this update, the capture / publish process is greatly enhanced, I completely eliminated the need for a SQLite DB and or a Python HTTP server. while the need for SQLite and Python HTTP is still required on pre Solaris 11.4 hosts, its now totally unnecessary on Solaris 11.4+ hosts.

Lets jump right in to the details.
All the latest code is available on the GitHub Repository page.

Capturing Stats – Version 0.2

This update significantly enhances Analytics collection on Solaris 11.4+(12).

  1. Removed the need for an extra Python HTTP server to gather remote analytics (this is still needed for pre s11.4 clients).
  2. Removed the need for a local SQLite Database (this is still needed for pre s11.4 clients).
  3. Updated all REST API calls to use Solars Remote Administration Demon(RAD) Authentication.

The new version only needs one service/demon to run on the remote node.
All data captured is stored in the local Stats Store.
The remote Stats Store central server queries / pulls from all the remote client.

The install adds two new SMF services and two new Python applications.

Configuration Example

First Copy the Stats Store (sstore) custom json files to the stats directory.

Now, restart the Stats Store service for the new stats to be available.

There are two applications included, a client and a server.

  • The client process:
    The client process is used to collect / capture Analytics data, this data will be stored in the local Stats Store.
  • The server process:
    The server process will fetch Analytics/Stats Store data from a list of remote clients and publish the results in the local central Stats Store.

Note: I am not posting any of the code below, because all the code is available on Github.

Now, to use Analytics sample application, follow the steps below.

  1. Clone the git repository in to /opt/sys_monitor with git clone. for example, git clone https://github.com/elik1001/solaris-analytics-publisher
  2. Modify /opt/sys_monitor/bin/capture_from_local-s11_4.py, replace disks1/sd1 and disk2/sd4 with your sd device – you can find your device(s) with iostat -xc (left col).
  3. Modify /opt/sys_monitor/bin/capture_from_local-s11_4.py, replace net1/interface1 and disk2/interface2 with your network device – you can find your device(s) with ipadm.
  4. Modify /opt/sys_monitor/bin/pull_from_remote-s11_4.py, replace user and password with your remote host user and password
  5. Modify/add you host to /opt/sys_monitor/conf/s12-links.txt, this file contains a list of hosts to fetch data from, the data will then be published to the local central Analytics Stats Store.
  6. Add/replace password in /opt/sys_monitor/conf/chk_db1_apps-ses.sh and /opt/sys_monitor/conf/test_db1_apps.sh with your MySQL DB password (or if you allow localhost without a password, just remove -p option)
  7. Optional: Add any (MySQL) required variables to /opt/sys_monitor/conf/set_env

To use the application, you will need to import the SMF services, by running the below..

  1. Used for local capture:
    svccfg import /opt/sys_monitor/services/s11_4-capture_service.xml
  2. Used for pulling the remote host analytics:
    svccfg import /opt/sys_monitor/services/s11_4-pull_from_remote.xml

Note: You can run both Solaris 11.4 and pre Solaris 11.4 services simultaneously (this is only needed if you have s11.4+ and pre s11.4 hosts).

Make sure the services are up and running, by running the below.

You are now ready to setup stats on the Solaris BUI/GUI dashboard.
Login to https://localhost:6787/

The rest of the process is the same as in part 4.
For a full walkthrue and how to configure the Solaris BUI/GUI dashboard, please check out part 4.

You might also like – Articles related to Oracle Solaris 11.4/Solaris 12.

Like what you’re reading? please provide feedback, any feedback is appreciated.

Leave a Reply

avatar
  Subscribe  
Notify of