Red Hat Training

A Red Hat training course is available for Red Hat Ceph Storage

第3章 ネットワークの問題のトラブルシューティング

本章では、ネットワークおよび Network Time Protocol(NTP)に接続しているトラブルシューティング手順を説明します。

3.1. 基本的なネットワークのトラブルシューティング

Red Hat Ceph Storage は、信頼性の高いネットワーク接続によって大きく依存します。Red Hat Ceph Storage ノードは、ネットワークを使用して相互に通信します。ネットワークの問題が発生すると、Ceph OSD のフラッピングなどの多くの問題が発生するか、またはダウンとして誤って報告される可能性があります。また、ネットワークの問題により Ceph Monitor のクロックの誤差エラーが引き起こされる可能性があります。さらに、パケットロス、レイテンシーが高い、または制限された帯域幅が、クラスターのパフォーマンスと安定性に影響を与える可能性があります。

手順: 基本的なネットワーキングのトラブルシューティング

  1. net-tools パッケージをインストールすると、Ceph Storage クラスターで発生する可能性のあるネットワーク問題のトラブルシューティングに役立ちます。

    [root@mon ~]# yum install net-tools
    [root@mon ~]# yum install telnet

  2. Ceph 設定ファイルの cluster_network および public_network パラメーターに正しい値が含まれていることを確認します。

    [root@mon ~]# cat /etc/ceph/ceph.conf | grep net
    cluster_network = 192.168.1.0/24
    public_network = 192.168.0.0/24

  3. ネットワークインターフェースが起動していることを確認します。

    [root@mon ~]# ip link list
    1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default qlen 1000
        link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    2: enp22s0f0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP mode DEFAULT group default qlen 1000
        link/ether 40:f2:e9:b8:a0:48 brd ff:ff:ff:ff:ff:ff

  4. Ceph ノードは、短縮ホスト名を使用して相互に通信できることを確認します。ストレージクラスターの各ノードでこれを確認します。

    構文

    ping SHORT_HOST_NAME

    [root@mon ~]# ping osd01

  5. ファイアウォールを使用する場合、Ceph ノードが適切なポートで他のノードにアクセスできることを確認します。firewall-cmd ツールと telnet ツールは、ポートのステータスを検証して、ポートが開いているかどうかを確認できます。

    構文

    firewall-cmd --info-zone=ZONE
    telnet IP_ADDRESS PORT

    [root@mon ~]# firewall-cmd --info-zone=public
    public (active)
      target: default
      icmp-block-inversion: no
      interfaces: enp1s0
      sources: 192.168.0.0/24
      services: ceph ceph-mon cockpit dhcpv6-client ssh
      ports: 9100/tcp 8443/tcp 9283/tcp 3000/tcp 9092/tcp 9093/tcp 9094/tcp 9094/udp
      protocols:
      masquerade: no
      forward-ports:
      source-ports:
      icmp-blocks:
      rich rules:
    
    [root@mon ~]# telnet 192.168.0.22 9100

  6. インターフェースカウンターにエラーがないことを確認します。ノード間のネットワーク接続がレイテンシーが予想され、パケットロスがないことを確認します。

    1. ethtool コマンドの使用:

      構文

      ethtool -S INTERFACE

      [root@mon ~]# ethtool -S enp22s0f0 | grep errors
      NIC statistics:
           rx_fcs_errors: 0
           rx_align_errors: 0
           rx_frame_too_long_errors: 0
           rx_in_length_errors: 0
           rx_out_length_errors: 0
           tx_mac_errors: 0
           tx_carrier_sense_errors: 0
           tx_errors: 0
           rx_errors: 0

    2. ifconfig コマンドの使用:

      [root@mon ~]# ifconfig
      enp22s0f0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
      inet 10.8.222.13  netmask 255.255.254.0  broadcast 10.8.223.255
      inet6 2620:52:0:8de:42f2:e9ff:feb8:a048  prefixlen 64  scopeid 0x0<global>
      inet6 fe80::42f2:e9ff:feb8:a048  prefixlen 64  scopeid 0x20<link>
      ether 40:f2:e9:b8:a0:48  txqueuelen 1000  (Ethernet)
      RX packets 4219130  bytes 2704255777 (2.5 GiB)
      RX errors 0  dropped 0  overruns 0  frame 0 1
      TX packets 1418329  bytes 738664259 (704.4 MiB)
      TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0 2
      device interrupt 16

    3. netstat コマンドの使用:

      [root@mon ~]# netstat -ai
      Kernel Interface table
      Iface          MTU   RX-OK RX-ERR RX-DRP RX-OVR  TX-OK TX-ERR TX-DRP TX-OVR Flg
      docker0       1500       0      0      0 0           0      0      0      0 BMU
      eno2          1500       0      0      0 0           0      0      0      0 BMU
      eno3          1500       0      0      0 0           0      0      0      0 BMU
      eno4          1500       0      0      0 0           0      0      0      0 BMU
      enp0s20u13u5  1500  253277      0      0 0           0      0      0      0 BMRU
      enp22s0f0     9000  234160      0      0 0      432326      0      0      0 BMRU 1
      lo           65536   10366      0      0 0       10366      0      0      0 LRU

  7. パフォーマンスの問題は、レイテンシーの確認や、ストレージクラスターのすべてのノード間のネットワーク帯域幅を検証するため、iperf3 ツールを使用します。iperf3 ツールは、サーバーとクライアント間のシンプルなポイントツーポイントネットワーク帯域幅テストを実行します。

    1. 帯域幅を確認する Red Hat Ceph Storage ノードに iperf3 パッケージをインストールします。

      [root@mon ~]# yum install iperf3

    2. Red Hat Ceph Storage ノードで、iperf3 サーバーを起動します。

      [root@mon ~]# iperf3 -s
      -----------------------------------------------------------
      Server listening on 5201
      -----------------------------------------------------------

      注記

      デフォルトのポートは 5201 ですが、-P コマンド引数を使用して設定できます

    3. 別の Red Hat Ceph Storage ノードで、iperf3 クライアントを起動します。

      [root@osd ~]# iperf3 -c mon
      Connecting to host mon, port 5201
      [  4] local xx.x.xxx.xx port 52270 connected to xx.x.xxx.xx port 5201
      [ ID] Interval           Transfer     Bandwidth       Retr  Cwnd
      [  4]   0.00-1.00   sec   114 MBytes   954 Mbits/sec    0    409 KBytes
      [  4]   1.00-2.00   sec   113 MBytes   945 Mbits/sec    0    409 KBytes
      [  4]   2.00-3.00   sec   112 MBytes   943 Mbits/sec    0    454 KBytes
      [  4]   3.00-4.00   sec   112 MBytes   941 Mbits/sec    0    471 KBytes
      [  4]   4.00-5.00   sec   112 MBytes   940 Mbits/sec    0    471 KBytes
      [  4]   5.00-6.00   sec   113 MBytes   945 Mbits/sec    0    471 KBytes
      [  4]   6.00-7.00   sec   112 MBytes   937 Mbits/sec    0    488 KBytes
      [  4]   7.00-8.00   sec   113 MBytes   947 Mbits/sec    0    520 KBytes
      [  4]   8.00-9.00   sec   112 MBytes   939 Mbits/sec    0    520 KBytes
      [  4]   9.00-10.00  sec   112 MBytes   939 Mbits/sec    0    520 KBytes
      - - - - - - - - - - - - - - - - - - - - - - - - -
      [ ID] Interval           Transfer     Bandwidth       Retr
      [  4]   0.00-10.00  sec  1.10 GBytes   943 Mbits/sec    0             sender
      [  4]   0.00-10.00  sec  1.10 GBytes   941 Mbits/sec                  receiver
      
      iperf Done.

      この出力には、Red Hat Ceph Storage ノード間の 1.1 Gbits/秒のネットワーク帯域幅と、テスト中の再送信なしが表示されます

      Red Hat は、ストレージクラスター内のすべてのノード間のネットワーク帯域幅を検証することを推奨します。

  8. 全ノードに同じネットワーク相互接続速度があることを確認します。割り当てられているノードの速度が遅くなると、接続速度が遅くなる可能性があります。また、相互スイッチリンクがアタッチされたノードの集約された帯域幅を処理できることを確認します。

    構文

    ethtool INTERFACE

    [root@mon ~]# ethtool enp22s0f0
    Settings for enp22s0f0:
    Supported ports: [ TP ]
    Supported link modes:   10baseT/Half 10baseT/Full
                            100baseT/Half 100baseT/Full
                            1000baseT/Half 1000baseT/Full
    Supported pause frame use: No
    Supports auto-negotiation: Yes
    Supported FEC modes: Not reported
    Advertised link modes:  10baseT/Half 10baseT/Full
                            100baseT/Half 100baseT/Full
                            1000baseT/Half 1000baseT/Full
    Advertised pause frame use: Symmetric
    Advertised auto-negotiation: Yes
    Advertised FEC modes: Not reported
    Link partner advertised link modes:  10baseT/Half 10baseT/Full
                                         100baseT/Half 100baseT/Full
                                         1000baseT/Full
    Link partner advertised pause frame use: Symmetric
    Link partner advertised auto-negotiation: Yes
    Link partner advertised FEC modes: Not reported
    Speed: 1000Mb/s 1
    Duplex: Full 2
    Port: Twisted Pair
    PHYAD: 1
    Transceiver: internal
    Auto-negotiation: on
    MDI-X: off
    Supports Wake-on: g
    Wake-on: d
    Current message level: 0x000000ff (255)
           drv probe link timer ifdown ifup rx_err tx_err
    Link detected: yes 3

関連項目