hmci/doc/readme-redhat.md

66 lines
2.3 KiB
Markdown
Raw Normal View History

2022-09-08 06:45:39 +00:00
# Instruction for RedHat / CentOS / AlmaLinux Systems
Please note that the software versions referenced in this document might have changed and might not be available/working unless updated.
2023-03-08 08:49:55 +00:00
Ensure you have **correct date/time** and NTPd running to keep it accurate!
2022-09-08 06:45:39 +00:00
All commands should be run as root or through sudo.
2022-09-08 06:45:39 +00:00
## Install the Java Runtime from repository
```shell
2023-03-08 08:49:55 +00:00
dnf install java-11-openjdk-headless wget
# or
2023-03-08 08:49:55 +00:00
yum install java-11-openjdk-headless wget
2022-09-08 06:45:39 +00:00
```
## Download and Install InfluxDB
```shell
wget https://dl.influxdata.com/influxdb/releases/influxdb-1.8.10.x86_64.rpm
rpm -ivh influxdb-1.8.10.x86_64.rpm
systemctl daemon-reload
systemctl enable influxdb
systemctl start influxdb
2022-09-08 06:45:39 +00:00
```
2023-03-08 08:49:55 +00:00
If you are running Linux on Power, you can find ppc64le InfluxDB packages on the [Power DevOps](https://www.power-devops.com/influxdb) site. Remember to pick the 1.8 or 1.9 version.
2022-09-08 06:45:39 +00:00
Run the ```influx``` cli command and create the *hmci* database.
2023-03-08 08:49:55 +00:00
```sql
CREATE DATABASE "hmci" WITH DURATION 365d REPLICATION 1;
```
2022-09-08 06:45:39 +00:00
## Download and Install Grafana
```shell
2023-03-08 08:49:55 +00:00
wget https://dl.grafana.com/oss/release/grafana-9.1.7-1.x86_64.rpm
rpm -ivh grafana-9.1.7-1.x86_64.rpm
systemctl daemon-reload
systemctl enable grafana-server
systemctl start grafana-server
2022-09-08 06:45:39 +00:00
```
2023-03-08 08:49:55 +00:00
If you are running Linux on Power, you can find ppc64le Grafana packages on the [Power DevOps](https://www.power-devops.com/grafana) site.
2022-09-08 06:45:39 +00:00
When logged in to Grafana (port 3000, admin/admin) create a datasource that points to the local InfluxDB. Now import the provided dashboards.
## Download and Install HMCi
2023-01-18 14:40:58 +00:00
[Download](https://git.data.coop/nellemann/-/packages/generic/hmci/) the latest version of HMCi packaged for rpm.
2022-09-08 06:45:39 +00:00
```shell
2023-03-08 08:49:55 +00:00
wget https://git.data.coop/api/packages/nellemann/generic/hmci/v1.4.2/hmci-1.4.2-1.noarch.rpm
rpm -ivh hmci-1.4.2-1_all.rpm
2022-09-08 06:45:39 +00:00
cp /opt/hmci/doc/hmci.toml /etc/
cp /opt/hmci/doc/hmci.service /etc/systemd/system/
systemctl daemon-reload
systemctl enable hmci
systemctl start hmci
2022-09-08 06:45:39 +00:00
```
2023-03-08 08:49:55 +00:00
Now modify **/etc/hmci.toml** (edit URL and credentials to your HMCs) and test the setup by running ```/opt/hmci/bin/hmci -d``` in the foreground/terminal and look for any errors. Press CTRL+C to stop and then start as a background service with ```systemctl start hmci```. You can see the log/output by running ```journalctl -f -u hmci```.