p-alik / nfsen

Attention! This repository contains inofficial copy of NfSen. The official site of the NfSen project: http://nfsen.sourceforge.net/
Other
17 stars 10 forks source link

Nfsen in centOS8 cant make install #16

Closed jamezbond13 closed 4 years ago

jamezbond13 commented 4 years ago

Im stuck? please help me solve this issue When iam trying to install nfsen i get this:

[]# ./install.pl etc/nfsen-dist.conf Check for required Perl modules: All modules found. do "etc/nfsen-dist.conf" failed, '.' is no longer in @INC; did you mean do "./etc/nfsen-dist.conf"? at libexec/NfConf.pm line 169. Setup NfSen: Version: 1.3.8: $Id: install.pl 71 2017-01-19 16:16:21Z peter $

Perl to use: [/usr/bin/perl] Missing Variable $BINDIR in Config File Missing Variable $LIBEXECDIR in Config File Missing Variable $CONFDIR in Config File Missing Variable $DOCDIR in Config File Missing Variable $PROFILESTATDIR in Config File Missing Variable $PROFILEDATADIR in Config File Missing Variable $BACKEND_PLUGINDIR in Config File Missing Variable $FRONTEND_PLUGINDIR in Config File

Some variables are missing in your config file. If you upgrade from an older version of NfSen please check nfsen-dist.conf for required variables.

missing variables and thats all i see... Please give me some points on where to look and how ia can fix this issue

tryed to install nfsen 1.3.6-1.3.7and1-3.8 everywhere the same error and one more thing i had to six file NfsenRRD.pm $rrd_version >= 1.2 && $rrd_version < 1.7 ) ---- was 1.6 and rrd wasnt working now it seems to be fine

p-alik commented 4 years ago

Ensure the mentioned variables are in ./etc/nfsen-dist.conf and try to run ./install.pl ./etc/nfsen-dist.conf as error message suggests.

jamezbond13 commented 4 years ago

I have done 2 things First ive tryied to change values in libexec/Nfconf.pm i wrote everything and then my install worked but when im trying to start nfsen from /bin/nfsen start i get e error: [bin]# nfsen start ERR No NFSEN config file found. but it is in etc/nfsen.conf

Second Ive deleted everithing and try to do this: Ensure the mentioned variables are in ./etc/nfsen-dist.conf and try to run ./install.pl ./etc/nfsen-dist.conf as error message suggests. it worked too login as: root root@192.168.0.1's password: nfsen]# ./install.pl ./nfsen.conf Check for required Perl modules: All modules found. Setup NfSen: Version: 1.3.8: $Id: install.pl 71 2017-01-19 16:16:21Z peter $

Perl to use: [/usr/bin/perl] Setup php and html files. mkdir /var/www/nfsen/

Copy NfSen dirs etc bin libexec plugins doc ... Copy config file './nfsen.conf'

In directory: /data/nfsen/libexec ... Update script: Log.pm Update script: Lookup.pm Update script: NfAlert.pm Update script: Nfcomm.pm Update script: NfConf.pm Update script: NfProfile.pm Update script: NfSen.pm Update script: NfSenRC.pm Update script: NfSenRRD.pm Update script: NfSenSim.pm Update script: Nfsources.pm Update script: Nfsync.pm Update script: Notification.pm In directory: /data/nfsen/bin ... Update script: nfsend Update script: RebuildHierarchy.pl Update script: testPlugin

Cleanup old files ...

Setup diretories:

Use UID/GID 1012 48 Creating: mkdir /data/nfsen/var /data/nfsen/var Creating: mkdir /data/nfsen/var/tmp /data/nfsen/var/tmp Creating: mkdir /data/nfsen/var/run /data/nfsen/var/run Creating: mkdir /data/nfsen/var/filters /data/nfsen/var/filters Creating: mkdir /data/nfsen/var/fmt /data/nfsen/var/fmt Creating: mkdir /data/nfsen/profiles-stat /data/nfsen/profiles-stat Creating: mkdir /data/nfsen/profiles-stat/live /data/nfsen/profiles-stat/live Creating: mkdir /data/nfsen/profiles-data /data/nfsen/profiles-data Creating: mkdir /data/nfsen/profiles-data/live /data/nfsen/profiles-data/live

Profile live: spool directories: Creating: mkdir /data/nfsen/profiles-data/live/server server Rename gif RRDfiles ... done. Create profile info for profile 'live'

Rebuilding profile stats for './live' Can't use string ("live") as a HASH ref while "strict refs" in use at libexec/NfProfile.pm line 1238. [nfsen]# [bin]# nfsen start ERR No NFSEN config file found.

jamezbond13 commented 4 years ago

in CentOS I easilly install netflow nfdump and nfsen and everithing works fine. But in CentOS 8 ive got many problems in every package im trying to install=)

p-alik commented 4 years ago

Can't use string ("live") as a HASH ref while "strict refs" in use at libexec/NfProfile.pm line 1238.

Actually this shouldn't happen. See the issue #1

[bin]# nfsen start ERR No NFSEN config file found.

Check $CONFDIR in your nfsen.conf. Is nfsen.conf in the directory $CONFDIR refers to?

jamezbond13 commented 4 years ago

After i made a pach (А можно на русском тут писать, а то почта то явно русская=)?) [root@uz nfsen]# ./install.pl ./nfsen.conf Check for required Perl modules: All modules found. Setup NfSen: Version: 1.3.8: $Id: install.pl 71 2017-01-19 16:16:21Z peter $

Perl to use: [/usr/bin/perl] Setup php and html files. mkdir /var/www/nfsen/

Copy NfSen dirs etc bin libexec plugins doc ... Copy config file './nfsen.conf'

In directory: /data/nfsen/libexec ... Update script: Lookup.pm Update script: NfAlert.pm Update script: Nfcomm.pm Update script: NfConf.pm Update script: NfProfile.pm Update script: NfSen.pm Update script: NfSenRC.pm Update script: NfSenRRD.pm Update script: NfSenSim.pm Update script: Nfsources.pm Update script: Nfsync.pm Update script: Notification.pm In directory: /data/nfsen/bin ... Update script: nfsen Update script: RebuildHierarchy.pl Update script: testPlugin

Cleanup old files ...

Setup diretories:

Use UID/GID 1012 48 Exists: /data/nfsen/var Exists: /data/nfsen/var/tmp Exists: /data/nfsen/var/run Exists: /data/nfsen/var/filters Exists: /data/nfsen/var/fmt Creating: mkdir /data/nfsen/profiles-stat /data/nfsen/profiles-stat Creating: mkdir /data/nfsen/profiles-stat/live /data/nfsen/profiles-stat/live Creating: mkdir /data/nfsen/profiles-data /data/nfsen/profiles-data Creating: mkdir /data/nfsen/profiles-data/live /data/nfsen/profiles-data/live

Profile live: spool directories: Creating: mkdir /data/nfsen/profiles-data/live/server server Rename gif RRDfiles ... done. Create profile info for profile 'live'

Rebuilding profile stats for './live' Reconfig: No changes found! Setup done.

Everything done clear with no error BUT i still got one problem [root@uz bin]# nfsen start ERR No NFSEN config file found.

in my nfsen.conf

#
# Required for default layout
$BASEDIR = "/data/nfsen";

#
# Where to install the NfSen binaries
$BINDIR="${BASEDIR}/bin";

#
# Where to install the NfSen Perl modules
$LIBEXECDIR="${BASEDIR}/libexec";

#
# Where to install the config files
$CONFDIR="${BASEDIR}/etc";

#
# NfSen html pages directory:
# All php scripts will be installed here.
# URL: Entry point for nfsen: http://<webserver>/nfsen/nfsen.php
$HTMLDIR    = "/var/www/nfsen/";

#
# Where to install the docs
$DOCDIR="${HTMLDIR}/doc";

#
# Var space for NfSen
$VARDIR="${BASEDIR}/var";

# directory for all pid files
# $PIDDIR="$VARDIR/run";
#
# Filter directory
# FILTERDIR="${VARDIR}/filters";
#

# FORMATDIR for custom printing formats
# FORMATDIR="${VARDIR}/fmt";
#

Причем самого файла в /etc нету, там пусто после инсталла файл появляется там но при попытке запуска nfsen ругается что нет конфига. Голову сломал уже

p-alik commented 4 years ago

Я отвечу на английском, тк не все понимают русский.

In your case $BASEDIR = "/data/nfsen"; $CONFDIR="${BASEDIR}/etc";? $BINDIR="/data/nfsen/bin";

but when im trying to start nfsen from /bin/nfsen start i get e error:

Why /bin/nfsen? Based on aforementioned nfsen.conf content you've to run /data/nfsen/bin/nfsen start

p-alik commented 4 years ago

With the assumption you haven't any further questions I'm closing the issue.