CentOS 安裝 ntop


安裝ntop步驟:

  1. 下載ntop [這裡]
  2. 解壓縮
    [root@localhost ~]#tar -zxvf ntop.xx.xx.tar.gz
    [root@localhost ~]# cd ntop.x.xx
  3. 先安裝ntop所需的相關軟體
    [root@localhost ~]# yum -y install gcc gcc-c++ libpcap-devel libpcap  libtool  automake  autoconf  gdbm  gdbm-devel libevent libevent-devel rrdtool rrdtool-devel zlib zlib-devel GeoIP GeoIP-devel
  4. make
  5. make install
  6. 新增user與變更權限
    [root@localhost ~]# useradd -M -s /sbin/nologin -r ntop
    [root@localhost ~]# chown -R ntop:ntop /usr/local/share/ntop
    [root@localhost ~]# chown -R ntop:root /usr/local/var/ntop
  7. 初始化ntop與設定admin密碼:
    [root@localhost ~]# ntop -A
    Fri Aug 31 10:00:37 2012  Initializing gdbm databases
    Fri Aug 31 10:00:37 2012  Setting administrator password…
    ntop startup – waiting for user response!
    Please enter the password for the admin user:
    Please enter the password again:
    Fri Aug 31 10:01:50 2012  Admin user password has been set
    Fri Aug 31 10:01:50 2012  Admin password set…
  8. 啟動ntop
    [root@localhost ~]# /usr/local/bin/ntop -d -L -u ntop -P /usr/local/var/ntop –skip-version-check –use-syslog=daemon
    開啟瀏覽器網址輸入 http://localhost:3000

    成功!
  9. 開機時自動啟動ntop,將/usr/local/bin/ntop -d -L -u ntop -P /usr/local/var/ntop –skip-version-check –use-syslog=daemon 加入到rc.local
    [root@localhost ~]# vi /etc/rc.local

Leave a Comment