Closed p-alik closed 6 years ago
nfsen is the project of @phaag. With regard to the install message:
* You may want to subscribe to the nfsen-discuss mailing list:
* http://lists.sourceforge.net/lists/listinfo/nfsen-discuss
* Please send bug reports back to me: phaag@sourceforge.net
I tried unfortunately without success to report the issue.
There is the patch about it, ref: https://sourceforge.net/p/nfsen/mailman/message/35850749/
diff --git a/install.pl b/install.pl
index 5ce265e..2a213db 100755
--- a/install.pl
+++ b/install.pl
@@ -553,7 +553,7 @@ sub UpgradeProfiles {
if( ! -f "$NfConf::PROFILEDATADIR/$profilepath/$channel/.nfstat") {
# no shadow profile, but missing channel stat
print "Rebuilding profile stats for '$profilegroup/$profilename'\n";
- NfProfile::DoRebuild(\%profileinfo, $profilename, $profilegroup, $profilepath, 1, 0);
+ NfProfile::DoRebuild(*STDOUT, \%profileinfo, $profilename, $profilegroup, $profilepath, 1, 0);
NfProfile::WriteProfile(\%profileinfo);
}
# make sure it's own by nfsen_uid after the rebuild
diff --git a/libexec/NfProfile.pm b/libexec/NfProfile.pm
index 1ca7436..d58fcd2 100644
--- a/libexec/NfProfile.pm
+++ b/libexec/NfProfile.pm
@@ -3441,7 +3441,7 @@ sub CheckProfiles {
} else {
$profileinfo{'type'} = 1;
}
- my $status = DoRebuild(\%profileinfo, $profile, $profilegroup, $profilepath, 0, 0);
+ my $status = DoRebuild(*STDOUT, \%profileinfo, $profile, $profilegroup, $profilepath, 0, 0);
syslog('err', "Rebuilded profile '$profile' in group '$profilegroup': $status ");
}
if ( -f "$NfConf::PROFILESTATDIR/$profilepath/.CANCELED" ) {
@@ -3453,7 +3453,7 @@ sub CheckProfiles {
} else {
$profileinfo{'type'} = 1;
}
- my $status = DoRebuild(\%profileinfo, $profile, $profilegroup, $profilepath, 0, 0);
+ my $status = DoRebuild(*STDOUT, \%profileinfo, $profile, $profilegroup, $profilepath, 0, 0);
syslog('err', "Rebuilded profile '$profile' in group '$profilegroup': $status ");
}
if ( $profileinfo{'locked'} ) {
Indeed, but the issue was reported 2016 for 1.3.7. https://sourceforge.net/p/nfsen/mailman/message/35147369/
Im having this issue on CentOS 7 with stable 1.3.8, how do I fix it?
@aiso-net, did you tried to apply the patch?
sorry, not familiar with that, any info on how to?
thanks, but that didnt work: [root@nms nfsen-1.3.8]# patch libexec/NfProfile.pm NfProfile.pm-patch patching file libexec/NfProfile.pm Hunk #1 FAILED at 3441. Hunk #2 FAILED at 3453. 2 out of 2 hunks FAILED -- saving rejects to file libexec/NfProfile.pm.rej [root@nms nfsen-1.3.8]# >install.pl-patch [root@nms nfsen-1.3.8]# vi install.pl-patch [root@nms nfsen-1.3.8]# patch install.pl install.pl-patch patching file install.pl Hunk #1 FAILED at 553. 1 out of 1 hunk FAILED -- saving rejects to file install.pl.rej
Applied the patch manually and that fixed it, thanks
This one works:
patch -p 1 -i fix.patch
patching file install.pl Hunk #1 succeeded at 553 with fuzz 1. patching file libexec/NfProfile.pm
Ps: the fix.patch contains content as posted by t0d0r above
https://github.com/p-alik/nfsen/releases/tag/nfsen-1.3.8 based on origin nfsen-1.3.8 but includes the patch 98bf068eb78cf8e5acdfdb2ebdd3cdf11d164869 for the issue.
actually it's not a new issue.
Steps to reproduce:
sudo ./install.pl /PATH-TO/nfsen.conf
ends in exception: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