我要评分
获取效率
正确性
完整性
易理解

Storing Software Packages

Perform the following operations on the server1 node.

Where,

  • Prometheus is open-source event monitoring system and time series database. It is widely used to manage various infrastructure resources.
  • Node Exporter is a component in the Prometheus ecosystem. It is used to collect and expose machine-level metrics, including but not limited to CPU usage, memory usage, disk I/O, network I/O, and file system information.
  • Grafana obtains cluster load and balancing data from Prometheus, and visualizes the data in charts and dashboards for display on the user interface.
  1. Create the /opt/prometheus directory on the server1 node, download the Go, Node, Prometheus, Node Exporter, and Grafana installation packages (see Table 2), and save them to this directory.
    1
    2
    3
    4
    5
    6
    7
    mkdir -p /opt/prometheus
    cd /opt/prometheus
    wget --no-check-certificate https://go.dev/dl/go1.22.2.linux-arm64.tar.gz
    wget --no-check-certificate https://cdn.npmmirror.com/binaries/node/v19.9.0/node-v19.9.0-linux-arm64.tar.xz
    wget --no-check-certificate https://github.com/prometheus/prometheus/releases/download/v2.45.4/prometheus-2.45.4.linux-arm64.tar.gz
    wget --no-check-certificate https://github.com/prometheus/node_exporter/releases/download/v1.7.0/node_exporter-1.7.0.linux-arm64.tar.gz
    wget --no-check-certificate https://dl.grafana.com/enterprise/release/grafana-enterprise-10.4.2.linux-arm64.tar.gz
    
    After the download is complete, the /opt/prometheus/ directory contains the following packages:
    go1.22.2.linux-arm64.tar.gz
    grafana-enterprise-10.4.2.linux-arm64.tar.gz
    node_exporter-1.7.0.linux-arm64.tar.gz
    node-v19.9.0-linux-arm64.tar.xz
    prometheus-2.45.4.linux-arm64.tar.gz
  2. Extract all the packages.
    tar -zxvf go1.22.2.linux-arm64.tar.gz
    tar -zxvf grafana-enterprise-10.4.2.linux-arm64.tar.gz
    tar -zxvf node_exporter-1.7.0.linux-arm64.tar.gz
    tar -xvf node-v19.9.0-linux-arm64.tar.xz
    tar -zxvf  prometheus-2.45.4.linux-arm64.tar.gz

    After the software packages are extracted, the following directories are generated:

    1
    2
    3
    4
    5
    go
    grafana-v10.4.2
    node_exporter-1.7.0.linux-arm64
    node-v19.9.0-linux-arm64
    prometheus-2.45.4.linux-arm64
    
  3. Copy the Go, Node Exporter, and Node installation directories in the /opt/prometheus/ directory to the /opt/prometheus/ directory on the other nodes. If the /opt/prometheus/ directory does not exist on the other nodes, create it first.
    # Directory List
    node_exporter-1.7.0.linux-arm64
    node-v19.9.0-linux-arm64
    go
    # Copy the directory list to the other nodes.
    scp -r node_exporter-1.7.0.linux-arm64 node-v19.9.0-linux-arm64 go agent1:/opt/prometheus/
    scp -r node_exporter-1.7.0.linux-arm64 node-v19.9.0-linux-arm64 go agent2:/opt/prometheus/
    scp -r node_exporter-1.7.0.linux-arm64 node-v19.9.0-linux-arm64 go agent3:/opt/prometheus/