mahara-contributors team mailing list archive
-
mahara-contributors team
-
Mailing list archive
-
Message #00236
[Bug 556972] Re: 1.2.2->1.2.4 upgrade fails with "Failed to upgrade!" error on core in upgrade.php
Adding irc log for more information:
[11:54] < gchaix> Huh. Anyone reporting problems going from 1.2.2 to 1.2.4? I'm getting a very uninformative "Failed to
upgrade!" error on core in upgrade.php
[11:55] < gchaix> Not quite sure where to look for details :-)
[12:05] <@richardm> gchaix: is there anything in the error log?
[12:05] < gchaix> apache error log?
[12:05] <@richardm> yeah
[12:06] < gchaix> I don't think so ... I'll look again
[12:06] < gchaix> it's on a pretty busy webhost, so I could have missed it in the noise
[12:07] < gchaix> nope, doesn't appear to be any errors there
[12:09] < gchaix> aha .. found something in syslog: PHP Fatal error: Call to undefined function mime_content_type() in
/var/www/mahara/mahara-1.2.4/htdocs/lib/db/upgrade.php on line 1317
[12:10] <@richardm> gchaix: what version of php are you running?
[12:11] < gchaix> checking
[12:11] < gchaix> 5.2.12 gentoo (suhosin)
[12:12] <@fmarier> gchaix, is the "mime_magic.magicfile" variable defined in your php.ini?
[12:12] <@richardm> hm, that's not good, we should be checking whether that function exists before calling it
[12:12] <@fmarier> (reading from http://nz.php.net/manual/en/function.mime-content-type.php#77429)
[12:12] < gchaix> fmarier: one sec .. checking
[12:13] < gchaix> fmarier: no, it's not defined in php.ini
[12:14] < gchaix> for that matter that file dosn't exist on my system outside a Drupal module
[12:15] <@richardm> maybe mime_magic.magicfile can be added in .htaccess
[12:16] < gchaix> richardm: what would ship that magicfile? Mahara? Or should I be pulling it from somewhere global?
[12:23] <@richardm> gchaix: mahara doesn't ship one
[12:24] < gchaix> so I see :-) More importantly, is it a requirement? I can certainly add one if needed
[12:26] <@richardm> Well I guess you've found out that it's a requirement to do the upgrade unless you hack the mahara code
:(
[12:26] <@richardm> I'm not sure where the best place to get one is though
[12:26] <@richardm> I thought it'd be available in your os somewhere but maybe not
[12:27] < gchaix> I see one in /etc/apache2/magic that looks like it might work
[12:27] * gchaix tries
[12:30] < gchaix> Hm. The error disappeared in /var/log/messages, but I'm still getting the failed to upgrade error on
upgrade.php
[12:31] <@richardm> And still nothing in the apache log?
[12:33] < gchaix> no ... but apparently something is buffering my messages log (weird) it finally showed up. Same undefined
function mime_content_type() error
[12:35] < gchaix> maybe php isn't happy with the .htaccess config. I'll try it in php.ini
[12:40] < gchaix> No luck. I did notice that the apache mod_mime_magic module is loaded, but PHP seems to be ignoring
mime_magic.magicfile = "/etc/apache2/magic"
[13:13] < gchaix> richardm: I need to get my site back online, so I'm going to revert to 1.2.2 for now. I did file a bug on
it, though: https://bugs.launchpad.net/mahara/+bug/556972
[13:24] <@richardm> gchaix: sorry about that, if your problem is common I guess we might need to do another release
[13:24] * gchaix nods ... no problem
[13:24] <@richardm> if you have self-registration turned on I'd definitely recommend patching with this:
http://gitorious.org/mahara/mahara/commit/f507e3831640ad104c59d4febc72b605acfa9fc9
[13:24] <@richardm> That's the most important thing in the upgrade
[13:25] < gchaix> ok, that's simple enough
[13:25] < gchaix> thx
--
1.2.2->1.2.4 upgrade fails with "Failed to upgrade!" error on core in upgrade.php
https://bugs.launchpad.net/bugs/556972
You received this bug notification because you are a member of Mahara
Contributors, which is subscribed to Mahara.
Status in Mahara ePortfolio: New
Bug description:
Upgrading from 1.2.2 to 1.2.4
Gentoo Linux
Apache 2.2.11
PHP 5.2.12
Suhosin 0.9.29
Postgres 8.2.7
When running upgrade.php, the first item - core - reports "Failed to upgrade!"
Process to reproduce:
1) un-tar mahara-1.2.4
2) "close" site
3) copy config.php & 3rd party artefacts over to 1.2.4
4) point apache at the new 1.2.4 webroot
5) run /admin/upgrade.php
/var/log/messages shows the following error:
PHP Fatal error: Call to undefined function mime_content_type() in /var/www/mahara/mahara-1.2.4/htdocs/lib/db/upgrade.php on line 1317
References