Forums | Mahara Community

Support /
Installation stops with database error


anonymous profile picture
Account deleted
Posts: 2

31 December 2008, 10:30

 Could anyone help me with this? The install goes fine until this appears while it is performing installs and upgrades:

:(Could not execute command: CREATE TABLE mahconfig ( field VARCHAR(255) NOT NULL, value TEXT, CONSTRAINT PRIMARY KEY (field) )TYPE=innodb

Call stack (most recent first):
  • execute_sql() at /home/rule213/public_html/mahara/lib/dml.php:1339
  • execute_sql_arr() at /home/rule213/public_html/mahara/lib/ddl.php:570
  • install_from_xmldb_file() at /home/rule213/public_html/mahara/lib/upgrade.php:257
  • upgrade_core("CREATE TABLE mahconfig (
    field VARCHAR(255) NO...", true
    ) at /home/rule213/public_html/mahara/admin/upgrade.json.php:71
This is a new install, not an upgrade.
What I know about databases could be written on an orange pip, so please spell it out slowly! 
Thanks in anticipation. 
anonymous profile picture
Account deleted
Posts: 1643

31 December 2008, 18:09

Hi, To help you with this we will need some information:

  • What database type and version are you using?
  • Wha version of Mahara?
  • Can you please check your apache error log, you will find a backtrace with more information about the error - could you please paste that here?
anonymous profile picture
Account deleted
Posts: 2

01 January 2009, 6:16

Thanks for your quick reply. Have solved that problem by using PostgreSQL database, instead of MySQL. All tables set up correctly now. Installed Mahara latest version 1.0.7.

Next problem is getting rid of the messages about magic quotes.  I looked at my host provider's (Siteground) help files and they sugested making a php.ini file and putting it in the mahara directory. Did that, no difference. It is using PHP version 5.2.5.

here is an example:

[ENV] 21 You have dangerous PHP settings, magic_quotes_gpc is on. Mahara is trying to work around this, but you should really fix it
[X]
Call stack (most recent first):
  • log_message("You have dangerous PHP settings, magic_quotes_gpc ...", 1, true, true) at /home/rule213/public_html/mahara/lib/errors.php:102
  • log_environ("You have dangerous PHP settings, magic_quotes_gpc ...") at /home/rule213/public_html/mahara/lib/mahara.php:86
  • ensure_sanity() at /home/rule213/public_html/mahara/init.php:77
  • require("/home/rule213/public_html/mahara/init.php") at /home/rule213/public_html/mahara/view/index.php:34

 My php.ini file reads:

 register_globals = off
magic_quotes_gpc = off

 The error log is clear now, no apparent problems as far as I can see.

I made a php.info report and can send it as a pdf. It shows magic quotes as being off!

I will keep going - may solve it with enough fiddling.

Thanks for your patience. Happy New Year.

P.S.  Ha! Five minutes later, found a kind of answer - by putting a copy of the php.ini file in every folder of mahara. There must be a better way!

anonymous profile picture
Account deleted
Posts: 1643

04 January 2009, 19:06

You can also solve that problem with reference to the 'troubleshooting' section of the installation instructions.
4 results