March 22, 2020, 9:38 p.m.

Installation of ntop-ng

ntop – High-speed web-based traffic analysis.

Installation method:

Using the stable package (not bleeding edge release):

$ sudo apt install ntopng


Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following additional packages will be installed:
  fonts-font-awesome libhiredis0.14 libjemalloc2 libjs-d3 libjs-jquery-form libjs-jquery-metadata libjs-jquery-tablesorter
  libjs-rickshaw libndpi2.6 lua-bitop lua-cjson node-html5shiv ntopng-data redis-server redis-tools
Suggested packages:
  geoip-database-contrib ruby-redis
The following NEW packages will be installed:
  fonts-font-awesome libhiredis0.14 libjemalloc2 libjs-d3 libjs-jquery-form libjs-jquery-metadata libjs-jquery-tablesorter
  libjs-rickshaw libndpi2.6 lua-bitop lua-cjson node-html5shiv ntopng ntopng-data redis-server redis-tools
0 upgraded, 16 newly installed, 0 to remove and 0 not upgraded.
Need to get 4,839 kB of archives.
After this operation, 18.9 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://httpredir.debian.org/debian buster/main amd64 libhiredis0.14 amd64 0.14.0-3 [33.8 kB]
Get:2 http://httpredir.debian.org/debian buster/main amd64 libjemalloc2 amd64 5.1.0-3 [225 kB]
Get:3 http://httpredir.debian.org/debian buster/main amd64 lua-bitop amd64 1.0.2-5 [6,936 B]
Get:4 http://httpredir.debian.org/debian buster/main amd64 lua-cjson amd64 2.1.0+dfsg-2.1 [17.5 kB]
Get:5 http://httpredir.debian.org/debian buster/main amd64 redis-tools amd64 5:5.0.3-4+deb10u1 [523 kB]
Get:6 http://httpredir.debian.org/debian buster/main amd64 redis-server amd64 5:5.0.3-4+deb10u1 [78.4 kB]
Get:7 http://httpredir.debian.org/debian buster/main amd64 fonts-font-awesome all 5.0.10+really4.7.0~dfsg-1 [515 kB]
Get:8 http://httpredir.debian.org/debian buster/main amd64 libjs-d3 all 3.5.17-2 [132 kB]
Get:9 http://httpredir.debian.org/debian buster/main amd64 libjs-jquery-form all 12-1.1 [19.3 kB]
Get:10 http://httpredir.debian.org/debian buster/main amd64 libjs-jquery-metadata all 12-1.1 [7,420 B]
Get:11 http://httpredir.debian.org/debian buster/main amd64 libjs-jquery-tablesorter all 1:2.31.1+dfsg1-1 [176 kB]
Get:12 http://httpredir.debian.org/debian buster/main amd64 libjs-rickshaw all 1.5.1.dfsg-2 [710 kB]
Get:13 http://httpredir.debian.org/debian buster/main amd64 libndpi2.6 amd64 2.6-3 [162 kB]
Get:14 http://httpredir.debian.org/debian buster/main amd64 node-html5shiv all 3.7.3+dfsg-2 [12.7 kB]
Get:15 http://httpredir.debian.org/debian buster/main amd64 ntopng-data all 3.8+dfsg1-2.1 [1,868 kB]
Get:16 http://httpredir.debian.org/debian buster/main amd64 ntopng amd64 3.8+dfsg1-2.1 [353 kB]
Fetched 4,839 kB in 4s (1,322 kB/s)
Selecting previously unselected package libhiredis0.14:amd64.
(Reading database ... 561515 files and directories currently installed.)
Preparing to unpack .../00-libhiredis0.14_0.14.0-3_amd64.deb ...
Unpacking libhiredis0.14:amd64 (0.14.0-3) ...
Selecting previously unselected package libjemalloc2:amd64.
Preparing to unpack .../01-libjemalloc2_5.1.0-3_amd64.deb ...
Unpacking libjemalloc2:amd64 (5.1.0-3) ...
Selecting previously unselected package lua-bitop:amd64.
Preparing to unpack .../02-lua-bitop_1.0.2-5_amd64.deb ...
Unpacking lua-bitop:amd64 (1.0.2-5) ...
Selecting previously unselected package lua-cjson:amd64.
Preparing to unpack .../03-lua-cjson_2.1.0+dfsg-2.1_amd64.deb ...
Unpacking lua-cjson:amd64 (2.1.0+dfsg-2.1) ...
Selecting previously unselected package redis-tools.
Preparing to unpack .../04-redis-tools_5%3a5.0.3-4+deb10u1_amd64.deb ...
Unpacking redis-tools (5:5.0.3-4+deb10u1) ...
Selecting previously unselected package redis-server.
Preparing to unpack .../05-redis-server_5%3a5.0.3-4+deb10u1_amd64.deb ...
Unpacking redis-server (5:5.0.3-4+deb10u1) ...
Selecting previously unselected package fonts-font-awesome.
Preparing to unpack .../06-fonts-font-awesome_5.0.10+really4.7.0~dfsg-1_all.deb ...
Unpacking fonts-font-awesome (5.0.10+really4.7.0~dfsg-1) ...
Selecting previously unselected package libjs-d3.
Preparing to unpack .../07-libjs-d3_3.5.17-2_all.deb ...
Unpacking libjs-d3 (3.5.17-2) ...
Selecting previously unselected package libjs-jquery-form.
Preparing to unpack .../08-libjs-jquery-form_12-1.1_all.deb ...
Unpacking libjs-jquery-form (12-1.1) ...
Selecting previously unselected package libjs-jquery-metadata.
Preparing to unpack .../09-libjs-jquery-metadata_12-1.1_all.deb ...
Unpacking libjs-jquery-metadata (12-1.1) ...
Selecting previously unselected package libjs-jquery-tablesorter.
Preparing to unpack .../10-libjs-jquery-tablesorter_1%3a2.31.1+dfsg1-1_all.deb ...
Unpacking libjs-jquery-tablesorter (1:2.31.1+dfsg1-1) ...
Selecting previously unselected package libjs-rickshaw.
Preparing to unpack .../11-libjs-rickshaw_1.5.1.dfsg-2_all.deb ...
Unpacking libjs-rickshaw (1.5.1.dfsg-2) ...
Selecting previously unselected package libndpi2.6:amd64.
Preparing to unpack .../12-libndpi2.6_2.6-3_amd64.deb ...
Unpacking libndpi2.6:amd64 (2.6-3) ...
Selecting previously unselected package node-html5shiv.
Preparing to unpack .../13-node-html5shiv_3.7.3+dfsg-2_all.deb ...
Unpacking node-html5shiv (3.7.3+dfsg-2) ...
Selecting previously unselected package ntopng-data.
Preparing to unpack .../14-ntopng-data_3.8+dfsg1-2.1_all.deb ...
Unpacking ntopng-data (3.8+dfsg1-2.1) ...
Selecting previously unselected package ntopng.
Preparing to unpack .../15-ntopng_3.8+dfsg1-2.1_amd64.deb ...
Unpacking ntopng (3.8+dfsg1-2.1) ...
Setting up libndpi2.6:amd64 (2.6-3) ...
Setting up libjs-jquery-form (12-1.1) ...
Setting up node-html5shiv (3.7.3+dfsg-2) ...
Setting up libjemalloc2:amd64 (5.1.0-3) ...
Setting up lua-cjson:amd64 (2.1.0+dfsg-2.1) ...
Setting up libjs-jquery-metadata (12-1.1) ...
Setting up libjs-d3 (3.5.17-2) ...
Setting up lua-bitop:amd64 (1.0.2-5) ...
Setting up libjs-jquery-tablesorter (1:2.31.1+dfsg1-1) ...
Setting up fonts-font-awesome (5.0.10+really4.7.0~dfsg-1) ...
Setting up libhiredis0.14:amd64 (0.14.0-3) ...
Setting up libjs-rickshaw (1.5.1.dfsg-2) ...
Setting up redis-tools (5:5.0.3-4+deb10u1) ...
Setting up ntopng-data (3.8+dfsg1-2.1) ...
Setting up redis-server (5:5.0.3-4+deb10u1) ...
Created symlink /etc/systemd/system/redis.service → /lib/systemd/system/redis-server.service.
Created symlink /etc/systemd/system/multi-user.target.wants/redis-server.service → /lib/systemd/system/redis-server.service.
Setting up ntopng (3.8+dfsg1-2.1) ...
Created symlink /etc/systemd/system/multi-user.target.wants/ntopng.service → /lib/systemd/system/ntopng.service.
Processing triggers for man-db (2.8.5-2) ...
Processing triggers for fontconfig (2.13.1-2) ...
Processing triggers for libc-bin (2.28-10) ...
Processing triggers for systemd (241-7~deb10u3) .

Using the stable from the official ntop package:
Instructions can be found at http://packages.ntop.org/apt-stable/

Visit http://localhost:3000, login as admin for the username and password.
ntop can be a resource hog, you can run out of RAM depending on the number of interfaces that you are monitoring. I would suggest that you edit the file: /etc/ntopng.conf and add only the interfaces that you need to monitor.

$ sudo nano /etc/ntopng.conf


# This configuration file is similar to the command line, with the exception
# that an equal sign '=' must be used between key and value. Example: -i=p1p2
# or --interface=p1p2 For options with no value (e.g. -v) the equal is also
# necessary. Example: "-v=" must be used.
#
# DO NOT REMOVE the following option, required for daemonization.
-e=

# * Interfaces to sniff on: one interface per line, prefix with -i=
# E.g.
-i=eth0
-i=wlan0
# If none is specified, ntopng will try to auto-detect the best interface.
#
# * Port on which ntopng will listen for the web-UI.
-w=3000

For some reason, apt does not detect the newer ntopng package from ntopng.org. I will be reporting this as a bug.

UPDATE: It appears that that version of ntopng is not yet available, I just used the nightly build (dev version). But it has some bugs, and I don’t want to update it everyday.