Page 1 of 1

error after ubuntu 11.10 upgrade

Posted: Fri Oct 21, 2011 8:41 pm
by olfax
lo,

After an ubuntu upgrade 11.04 to 11.10 , i've met two differents problems.

* first problem {Solved}
Starting ZoneMinder: Bareword "ZM_PATH_LOGS" not allowed while "strict subs" in use at /usr/local/share/perl/5.12.4/ZoneMinder/Logger.pm line 154.
BEGIN not safe after errors--compilation aborted at /usr/local/share/perl/5.12.4/ZoneMinder/Logger.pm line 169.
Compilation failed in require at /usr/local/share/perl/5.12.4/ZoneMinder.pm line 34.
BEGIN failed--compilation aborted at /usr/local/share/perl/5.12.4/ZoneMinder.pm line 34.
Compilation failed in require at /usr//local/bin/zmpkg.pl line 37.
BEGIN failed--compilation aborted at /usr//local/bin/zmpkg.pl line 37.
failure
This problem has been solved with a fix in Config.pm
I don't know why fetchrow_hashref() so i replaced it by fetchrow ...
90,91c91,92
< my $sql = "select * from Config";
< my $sth = $dbh->prepare_cached( $sql ) or croak( "Can't prepare '$sql': ".$dbh->errstr() );
---
> my $sql = "select Name,Value from Config";
> my $sth = $dbh->prepare( $sql ) or croak( "Can't prepare '$sql': ".$dbh->errstr() );
93c94
< while( my $config = $sth->fetchrow_hashref() )
---
> while( my @row = $sth->fetchrow )
95,96c96,98
< *{$config->{Name}} = sub { $config->{Value} };
< push( @EXPORT_CONFIG, $config->{Name} );
---
> my ($name,$value) = @row;
> *{$name} = sub { $value };
> push( @EXPORT_CONFIG, $name );
2nd problem not solved:
a lot of error message:
Shared data not initialised by capture daemon, some query functions may not be available or produce invalid results

Shared memory is set in launch script :
echo 134217728 >/proc/sys/kernel/shmall
echo 134217728 >/proc/sys/kernel/shmmax
What's wrong ?

Best regards

Philippe