ntop / ntopng

Web-based Traffic and Security Network Traffic Monitoring
http://www.ntop.org
GNU General Public License v3.0
6.27k stars 656 forks source link

ntop is not loading bootstrap #7905

Closed MarshalCurrier closed 1 year ago

MarshalCurrier commented 1 year ago

Environment: PRETTY_NAME="Ubuntu 22.04.3 LTS" NAME="Ubuntu" VERSION_ID="22.04" VERSION="22.04.3 LTS (Jammy Jellyfish)" VERSION_CODENAME=jammy

What happened: When using the applicaiton through both Chrome and Firefox the bootstrap doesnt load.

How did you reproduce it? Login and look at the console in Chrome or Firefox

Debug Information:

MarshalCurrier commented 1 year ago

That didnt add the screenshot or the copy/paste...

I will add here:

jquery.js:3841 jQuery.Deferred exception: $(...).selectpicker is not a function TypeError: $(...).selectpicker is not a function at HTMLDocument. (http://192.168.0.15:3001/js/pages/components/ifaces-dropdown.js?1697144833:4:31)

http://192.168.0.15:3001/bootstrap/js/bootstrap.bundle.min.js? net::ERR_ABORTED 404 (Not Found)

There's a few of those. I have uninstalled and reinstalled with no success. I am unsure where the bootstrap stuff is supposed to be located but there's a symlink in "/usr/share/ntopng/httpdocs" from "bootstrap -> ../../javascript/bootstrap"

I tried to figure it out. No luck.

MatteoBiscosi commented 1 year ago

Hi @MarshalCurrier sorry but we can help you only if you have the latest 2 ntopng versions (5.6 or 5.7). So if possible update and let me know

KarimGeiger commented 1 year ago

Having the same issue on Ubuntu 22.04, with the ntopng package updated to the latest version. Interestingly, the versions seem to not match between apt and web/cli:

apt:

$ apt show ntopng
Package: ntopng
Version: 5.6.230920-21625

Web, footer:

ntopng Community v.5.2.220414

CLI:

$ ntopng --version
Version:        5.2.220414 [Community build]
GIT rev:        :5.2.220414

As for the Bootstrap error - Seems like the file in question, bootstrap.bundle.min.js is not present:

$ ls /usr/share/ntopng/httpdocs/bootstrap/js
bootstrap.js  bootstrap.min.js
lucaderi commented 1 year ago

Can you please deinstall all the ntopng packages and reinstall the one we build (from https://packages.ntop.org)

I believe you have both the ntop packaged ntopng, and the one that comes with Ubuntu

KarimGeiger commented 1 year ago

That's it, thanks! I did follow the guide on that page, but I probably forgot to run an apt update after adding the repository. Didn't know Ubuntu shipped with its on version. After removing the old version and installing the correct version, this issue is now gone.