準備環境c++
CentOS6.4 和ntopng-1.2.1.tgz下載 提取碼:2142 首先換爲國內的源redis
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-6.repo yum update yum install gcc gcc-c++ -y #配置gcc環境 #下載安裝 EPEL 安裝源 wget http://download.fedoraproject.org/pub/epel/5/x86_64/epel-release-5-4.noarch.rpm rpm -ivh epel-release-5-4.noarch.rpm yum groupinstall "Development Tools" #這裏存在報錯 Error: Package: perl-Git-1.8.2.3-1.el5.x86_64 (epel)經過下面的命令解決 wget http://mirror.umd.edu/fedora/epel/6/i386/epel-release-6-8.noarch.rpm yum remove epel-release rpm -ivh epel-release-6-8.noarch.rpm --test rpm -ivh epel-release-6-8.noarch.rpm yum update yum install libpcap-devel glib2-devel GeoIP-devel libxml2-devel redis autoconf automake sqlite-devel 安裝必要的包 rz #上傳咱們開始下載的ntopng-1.2.1.tgz包解壓 cd ntopng-1.2.1 ./autogen.sh make&make install 編寫配置文件 [root@host-10-0-10-16 ntopng-1.2.1]# mkdir /etc/ntopng [root@host-10-0-10-16 ntopng-1.2.1]# vim /etc/ntopng/ntopng.conf -G=/var/tmp/ntopng.pid --local-networks=10.0.10.0/24 --interface=eth0 --http-port=3000 [root@host-10-0-10-16 ntopng-1.2.1]# /etc/init.d/redis start #先啓動redis Starting redis-server: [ OK ] [root@host-10-0-10-16 ntopng-1.2.1]# /usr/local/bin/ntopng /etc/ntopng/ntopng.conf & #在啓動ntopng lsof -i :3000 #檢查服務 登錄 http://192.168.1.208:3000 Username: admin Password : admin