AlmaLinux9にntopngをインストールしたときの記録です。
普段はcactiでネットワーク機器からトラフィック情報を可視化しておりますが、流量までしか見えず、どのIPがどれだけ流しているかまでは見ることができません。これでは少々不便なので、それも可視化できるntopngをインストールしようと思いました。
以下、インストール手順です。まず、事前のアップデートやリポジトリの追加を行います。
# dnf update # more /etc/redhat-release AlmaLinux release 9.5 (Teal Serval) # curl https://packages.ntop.org/centos/ntop.repo > /etc/yum.repos.d/ntop.repo # dnf install epel-release -y # rpm -ivh http://rpms.remirepo.net/enterprise/remi-release-9.rpm # dnf install dnf-plugins-core -y # dnf config-manager --set-enabled remi # dnf config-manager --set-enabled crb # dnf update |
ntopngおよび周辺のパッケージを合わせてインストールします。
# dnf install pfring-dkms n2disk nprobe ntopng cento # dnf install pfring-drivers-zc-dkms |
ここまできたらntopngを起動します。
# systemctl enable ntopng # systemctl start ntopng # systemctl status ntopng ● ntopng.service - ntopng high-speed web-based traffic monitoring and analysis tool Loaded: loaded (/usr/lib/systemd/system/ntopng.service; enabled; preset: disabled) Active: active (running) since Fri 2025-05-09 11:57:18 JST; 6s ago Process: 1597279 ExecStartPre=/bin/sh -c /usr/bin/ntopng-utils-manage-config -a check-restore && /usr/bin/ntopng-u> Process: 1597293 ExecStartPre=/bin/sh -c /bin/cat /etc/ntopng/ntopng.conf > /run/ntopng.conf.raw (code=exited, stat> Process: 1597295 ExecStartPre=/bin/sh -c /bin/cat /etc/ntopng/ntopng.conf.d/*.conf >> /run/ntopng.conf.raw 2>/dev/n> Process: 1597297 ExecStartPre=/bin/sh -c /bin/sed "/^[ ]*-e.*$\|^[ ]*-G.*\|^[ ]*--daemon.*\|[ ]*--pid.*/s/^/#/" /ru> Main PID: 1597299 (ntopng) Tasks: 21 (limit: 96864) Memory: 138.3M CPU: 1.327s CGroup: /system.slice/ntopng.service mq1597299 /usr/bin/ntopng /run/ntopng.conf |
ログインはhttp://ip-address:3000でアクセスできます。画面に表示されているようにデフォルトはadmin / adminで入れます。
最初のログイン時にはパスワードを変えるよう以下の画面が表示されます。合わせて言語を選択することが可能です。
ログイン後のトップ画面は以下のようになります。
以上で一通りのインストールは完了です。