Forums | Mahara Community

Support /
Installation Issue


anonymous profile picture
Account deleted
Posts: 4

05 December 2014, 6:43

Hi All,

I'm attempting to install mahara-1.10.1 that I've downloaded from the main site as a .tar.gz. I'm attempting to install this on a Linux box running Red Hat 4.4.7-4. I'm using lighttpd rather than apache to an existing moodle install that was accessing a remote database. As a result of that, I installed postgresql via yum.

yum install postgresql

yum install postgresql-server

I followed the instructions I found online (can't post the URL)

I'm running PHP version 5.5.14

I was following the Mahara installation steps and made it through to "Run the Installer". When I go to the local mahara site, I get the following:

Mahara: Site unavailable

Your server configuration does not include the pgsql extension. Mahara requires this in order to store data in a relational database. Please make sure that it is loaded in php.ini or install it if it is not installed.

I've found a few matches for that error, but nothing that has helped so far. My config.php file looks like this:

/**
 * database connection details
 * valid values for dbtype are 'postgres' and 'mysql'
 */
$cfg->dbtype   = 'postgres';
$cfg->dbhost   = 'localhost';
$cfg->dbport   = null;
$cfg->dbname   = 'maharadb';
$cfg->dbuser   = 'xxxxxx';
$cfg->dbpass   = 'xxxxxx';

My php.ini file looks like this (I added these lines in):

extension=/usr/lib64/pgsql/pgsql.so
extension=/usr/lib64/pgsql/plpgsql.so

plpgsql.so existed after installing Postgresql, I created a symlink pointing pgsql.so to it.

# ls -l /usr/lib64/pgsql/pgsql.so
lrwxrwxrwx. 1 root root 10 Dec  4 10:16 /usr/lib64/pgsql/pgsql.so -> plpgsql.so

But so far no luck. Any ideas? Thank you.

anonymous profile picture
Account deleted
Posts: 4

05 December 2014, 7:28

A bit more information if this helps. From /var/log/lighttpd/error.log:

 

2014-12-04 12:21:12: (mod_fastcgi.c.2695) FastCGI-stderr: [WAR] 6c (lib/mahara.php:35) Your server configuration does not include the pgsql extension. Mahara requires this in order to store data in a relational database. Please make sure that it is loaded in php.ini or install it if it is not installed.
2014-12-04 12:21:12: (mod_fastcgi.c.2695) FastCGI-stderr: Call stack (most recent first):
2014-12-04 12:21:12: (mod_fastcgi.c.2695) FastCGI-stderr:   * ensure_sanity() at /var/www/lighttpd/mahara/init.php:106
2014-12-04 12:21:12: (mod_fastcgi.c.2695) FastCGI-stderr:   * require("/var/www/lighttpd/mahara/init.php") at /var/www/lighttpd/mahara/index.php:16

Aaron Wells's profile picture
Posts: 896

10 December 2014, 16:39

Sorry Jeremy, I don't know anything about lighttpd and FastCGI. But from that error message it sounds like the PHP extension that lets PHP access Postgres isn't installed or isn't accessible to the PHP setup that lighttpd is using. Perhaps it uses a different php.ini than the one you're looking at? Sometimes operating systems can have more than one, for different PHP setups. Try running a phpinfo() script and see what the path to php.ini is.

What database type is your Moodle site using? Mahara supports MySQL as well as Postgres, so if you're successfully using MySQL with Moodle, you could switch Mahara over to that as well.

Cheers,

Aaron

anonymous profile picture
Account deleted
Posts: 4

11 December 2014, 3:26

Hi Aaron,

Thanks for the reply. I looked for other php.ini files, didn't find any that I didn't expect to find though.

[root@elrn07:/etc]# locate php.ini
/etc/php.ini
/etc/php.ini.2014-12-04
/etc/php.ini.original
/etc/php.ini.rpmnew
/usr/share/doc/php55w-common-5.5.14/php.ini-development
/usr/share/doc/php55w-common-5.5.14/php.ini-production

The phpinfo() script confirmed /etc was the file in use.

Loaded Configuration File /etc/php.ini

 

I'm using Postgres as Moodle is using MSSQL hosted on another machine. There was not a DB package installed prior to trying to set up Mahara. I suppose I could try installing MySQL and using that.

Thanks,

Jeremy

Aaron Wells's profile picture
Posts: 896

11 December 2014, 15:43

Good luck! You might also try asking for help on Postgres or Lighttpd forums, because the problem you're experiencing is with those systems rather than specific to Mahara.

Cheers,

Aaron

anonymous profile picture
Account deleted
Posts: 4

15 January 2015, 8:55

I installed MySQL and changed up my config.php and php.ini but ended up with the same error. Eventually I think I found the one package I didn't have installed. Ultimately once I ran "yum install php-mysqli" I was able to access the setup screen. I believe I have Mahara up and running now.

6 results