Skip to content

Commit 2edc006

Browse files
authored
Merge pull request #230 from NetApp/synchronize_docker_compose
Synchronize docker compose
2 parents 63be888 + e05936f commit 2edc006

File tree

15 files changed

+254
-79
lines changed

15 files changed

+254
-79
lines changed

Monitoring/monitor_fsxn_with_harvest_on_ec2/README-Manual.md

Lines changed: 41 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -110,12 +110,25 @@ If your exiting ec2 instance already had an instance profile, then simply add th
110110
To install Docker use the following commands if you are running an Red Hat based Linux:
111111
```sh
112112
sudo yum install docker
113-
sudo curl -L https://download.docker.com/linux/centos/7/x86_64/stable/Packages/docker-compose-plugin-2.6.0-3.el7.x86_64.rpm -o ./compose-plugin.rpm
114-
sudo yum install ./compose-plugin.rpm -y
115113
sudo systemctl start docker
114+
sudo systemctl enable docker
116115
```
117116
If you aren't running a Red Hat based Linux, you can follow the instructions [here](https://docs.docker.com/engine/install/).
118117

118+
Install Docker Compose:
119+
```text
120+
LATEST_COMPOSE_VERSION=$(curl -s https://api.github.com/repos/docker/compose/releases/latest | jq -r '.tag_name')
121+
ARCH=$(uname -m)
122+
if [ -z "$ARCH" -o -z "$LATEST_COMPOSE_VERSION" ]; then
123+
echo "Error: Unable to determine latest version or architecture."
124+
else
125+
sudo curl -s -L "https://github.com/docker/compose/releases/download/$LATEST_COMPOSE_VERSION/docker-compose-linux-$ARCH" -o /usr/local/bin/docker-compose
126+
sudo chmod +x /usr/local/bin/docker-compose
127+
# Create a symlink in /usr/bin for more accessibility.
128+
[ ! -L /usr/bin/docker-compose ] && sudo ln -s /usr/local/bin/docker-compose /usr/bin/docker-compose
129+
fi
130+
```
131+
119132
To confirm that docker has been installed correctly, run the following command:
120133

121134
```sh
@@ -145,6 +158,7 @@ Share images, automate workflows, and more with a free Docker ID:
145158
For more examples and ideas, visit:
146159
https://docs.docker.com/get-started/
147160
```
161+
148162
### 5. Install Harvest on EC2
149163

150164
Preform the following steps to install Harvest on your EC2 instance:
@@ -154,6 +168,8 @@ Preform the following steps to install Harvest on your EC2 instance:
154168
Modify the `harvest.yml` found in this repo with your clusters details. You should just have to change the `<FSxN_ip_X>` with the IP addresses of your FSxNs.
155169
Add as many pollers as you need to monitor all your FSxNs. There should be an AWS Secrets Manager secret for each FSxN.
156170

171+
Note in the example below, it has places for two FSxN. If you only have one, remove the "fsx02" section.
172+
157173
```yaml
158174
Exporters:
159175
prometheus1:
@@ -312,7 +328,7 @@ sudo sed -i -e "\$a\- job_name: 'yace'" -e "\$a\ static_configs:" -e "\$a\ -
312328
##### 6. Bring Everything Up
313329

314330
```sh
315-
sudo docker compose -f prom-stack.yml -f harvest-compose.yml up -d --remove-orphans
331+
sudo docker-compose -f prom-stack.yml -f harvest-compose.yml up -d --remove-orphans
316332
```
317333

318334
After bringing up the prom-stack.yml compose file, you can access Grafana at
@@ -323,3 +339,25 @@ You will be prompted to create a new password the first time you log in. Grafana
323339
username: admin
324340
password: admin
325341
```
342+
343+
## Adding additional FSx for ONTAP file systems.
344+
If you need to add additional FSxN file systems to monitor after the initial installation,
345+
you can do so by following the steps mentioned at the bottom of the [CloudFormation deployment](README.md) version of this read me file.
346+
347+
---
348+
349+
## Author Information
350+
351+
This repository is maintained by the contributors listed on [GitHub](https://github.com/NetApp/FSx-ONTAP-utils/graphs/contributors).
352+
353+
## License
354+
355+
Licensed under the Apache License, Version 2.0 (the "License").
356+
357+
You may obtain a copy of the License at [apache.org/licenses/LICENSE-2.0](http://www.apache.org/licenses/LICENSE-2.0).
358+
359+
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an _"AS IS"_ basis, without WARRANTIES or conditions of any kind, either express or implied.
360+
361+
See the License for the specific language governing permissions and limitations under the License.
362+
363+
© 2025 NetApp, Inc. All Rights Reserved.

Monitoring/monitor_fsxn_with_harvest_on_ec2/README.md

Lines changed: 32 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,26 @@ Go and uses the official AWS SDK. YACE supports auto-discovery of resources via
77
filtering monitored resources via regex, and more. You can read more about YACE capabilities from its
88
[Documentation](https://github.com/prometheus-community/yet-another-cloudwatch-exporter).
99

10+
Here are some screenshots of a couple of the dashboards that are included to visualize the metrics collected by Harvest and YACE.
11+
12+
![Screenshot-01](images/grafana-dashboard-01.png)
13+
14+
![Screenshot-02](images/grafana-dashboard-02.png)
15+
1016
## Prerequisites
1117
The only prerequisite is an FSx for ONTAP file system running in your AWS account.
1218

13-
## Overview
19+
## Architectural Overview
20+
21+
This solution uses several components to collect and display all the pertinent metrics from your FSx for ONTAP file system.
22+
Instead of trying to describe them in words, the following architectural diagram does a great job of showing the components and how they interact with each other:
23+
![Architectural Diagram](images/FSxN-MonitoringStack-EC2.png)
24+
25+
## Deployment Overview
1426

1527
There are two methods to deploy this solution, either via the AWS CloudFormation template or manually.
16-
The steps below are geared towrad the CloudFormation deployment method. If you want to deploy manually,
17-
please refer to these [instructions](README-Manual.md).
28+
The steps below are geared towards the CloudFormation deployment method. If you want to deploy manually,
29+
please refer to these [Manual Deployment Instructions](README-Manual.md).
1830

1931
This deployment includes:
2032
- **Harvest**: Collects ONTAP metrics.[Documentation](https://github.com/NetApp/harvest).
@@ -163,4 +175,21 @@ To monitor additional FSxN resources, follow these steps:
163175
```bash
164176
docker-compose -f prom-stack.yml -f harvest-compose.yml up -d --remove-orphans
165177
```
178+
166179
---
180+
181+
## Author Information
182+
183+
This repository is maintained by the contributors listed on [GitHub](https://github.com/NetApp/FSx-ONTAP-samples-scripts/graphs/contributors).
184+
185+
## License
186+
187+
Licensed under the Apache License, Version 2.0 (the "License").
188+
189+
You may obtain a copy of the License at [apache.org/licenses/LICENSE-2.0](http://www.apache.org/licenses/LICENSE-2.0).
190+
191+
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an _"AS IS"_ basis, without WARRANTIES or conditions of any kind, either express or implied.
192+
193+
See the License for the specific language governing permissions and limitations under the License.
194+
195+
© 2025 NetApp, Inc. All Rights Reserved.
173 KB
Loading
161 KB
Loading
247 KB
Loading

Monitoring/monitor_fsxn_with_harvest_on_eks/README.md

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,20 @@ into an AWS EKS cluster to monitor multiple FSx for ONTAP file systems using the
55
Grafana + Prometheus stack. It uses the AWS Secrets Manager to obtain
66
credentials for each of the FSxN file systems so those credentials aren't insecurely stored.
77

8+
Here are some screenshots of a couple of the dashboards that are included to visualize the metrics collected by Harvest and YACE.
9+
10+
![Screenshot-01](images/grafana-dashboard-01.png)
11+
12+
![Screenshot-02](images/grafana-dashboard-02.png)
13+
814
## Introduction
915

16+
### Architectural Overview
17+
18+
This solution uses several components to collect and display all the pertinent metrics from your FSx for ONTAP file system.
19+
Instead of trying to describe them in words, the following architectural diagram does a great job of showing the components and how they interact with each other:
20+
![Architectural Diagram](images/FSxN-MonitoringStack-EKS.png)
21+
1022
### What to expect
1123

1224
Harvest Helm chart installation will result the following:
@@ -20,7 +32,7 @@ The format of the secret string should to be a json structure with a `username`
2032
```json
2133
{
2234
"username": "fsxadmin",
23-
"password": "fsxadmin-password"
35+
"password": "fsxadmin's_password"
2436
}
2537
```
2638
A service account should be created during the installation of Harvest with the sufficient permissions to fetch the secrets.
@@ -347,7 +359,7 @@ Once you have access to Grafana, you can log in using the default credentials:
347359

348360
### Adding Grafana dashboards and visualize your FSxN metrics on Grafana
349361
Once you login, you'll want to import some dashboards to visualize the metrics collected by Harvest and YACE. You will find
350-
some example dashboards in the `dashboards` folder in this repository. You can import these dashboards into Grafana by following these steps:
362+
some example dashboards in the [dashboards](dashboards) folder in this repository. You can import these dashboards into Grafana by following these steps:
351363
1. Download the dashboards from the `dashboards` folder in this repository to your local PC.
352364
1. Log in to your Grafana instance.
353365
1. Click on the "+" icon on the left-hand side menu and select "Import Dashboard".
@@ -362,6 +374,8 @@ Only consider the dashboards in the `cmode` and `cmode-details` directories.
362374
:memo: **NOTE:** Since the special 'fsxadmin' account doesn't have access to all the metrics that a traditional ONTAP 'admin' account would have,
363375
some of the metrics and dashboards may not be fully applicable or available. The ones with 'fsx' tag are more relevant for FSxN.
364376

377+
---
378+
365379
## Author Information
366380

367381
This repository is maintained by the contributors listed on [GitHub](https://github.com/NetApp/FSx-ONTAP-samples-scripts/graphs/contributors).
@@ -376,4 +390,4 @@ Unless required by applicable law or agreed to in writing, software distributed
376390

377391
See the License for the specific language governing permissions and limitations under the License.
378392

379-
© 2024 NetApp, Inc. All Rights Reserved.
393+
© 2025 NetApp, Inc. All Rights Reserved.

0 commit comments

Comments
 (0)