> > 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.
Hmm. Forgot to say, that one assumes PostgreSQL 8.1. If you're doing an RPM install on an old OS (actually probably on most current ones, since 8.1 has only been out a couple of months) that's not going to be your problem. Instead, you need to register the contrib module (it's not registered by default) as you noticed in a different mail (that I didn't find until now, sorry). But this is the way for 8.1+. //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