> Running bacula 1.38.3 with bacula-web 1.2 and a postgresql DB.
> 
> The user configured can access the db with psql from both 
> localhost and remotely over tcpip. The test.php shows all OK 
> (except .bmp images).
> 
> http error.log shows:
> 
> PHP Fatal error:  Call to undefined function:  numrows() in 
> /var/www/html/bacula-web/classes.inc on line 158

You need to change the query before that one (two lines up) to:
 $dbsize = $this->link->query("select pg_database_size('bacula')")


database_size() is an addon module in previous versions of PostgreSQL.
It has since been accepted into core and at that point it was renamed to
follow the standard conventino for system functions.


If you don't want to edit the source, you can create a custom function
per:

CREATE FUNCTION database_size(name) RETURNS bigint AS
'SELECT pg_database_size($1)'
LANGUAGE 'sql'

With that, the current code should work fine.

//Magnus


-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid3432&bid#0486&dat1642
_______________________________________________
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users

Reply via email to