Author: greg
Description:
I just checked out a clean copy of 1.6 via SVN using the following command:
svn co http://svn.wikimedia.org/svnroot/mediawiki/branches/REL1_6/phase3
I then copied across my LocalSettings.php file and moved the directory into place on the server.
No matter what I do, I am unable to run the update.php script from the command line. It always fails with some kind of error no matter which options I
supply.
php -cli ./maintenance/update.php
(fails: tries to connect to database without a password as the user running the script)
sudo -u apache php -cli ./maintenance/update.php
(fails: claims safe mode restriction in effect and cannot write to counter.php)
sudo -u apache php -cli -d safe_mode=0 ./maintenance/update.php
(fails: tries to connect to database without a password as user running the script)
sudo php -cli -d safe_mode=0 ./maintenance/update.php
(fails: tries to connect to database without a password as root)
sudo php -d safe_mode=0 ./maintenance/update.php
(fails: tries to connect to database without a password as root)
chown -R apache:apache .
sudo -u apache php -cli ./maintenance/update.php
(fails: longer complains about unwriteable counter.php but still tries connecting without a password as the user running the script)
sudo -u apache php -cli -d safe_mode=0 -d open_basedir=/ ./maintenance/update.php
(fails: tries to connect as user running the script)
I tried that last one because it was complaining a about a safe mode restriction and not being able to access the file where I store my database username
and password (which I've moved outside of the webroot for security reasons). When I add the "open_basedir=/" option it evidently reads the file, but it
ignores the settings inside and tries to connect as the user running the script, not the user specified in the settings. I tried copying the database username
and password into the LocalSettings.php file and it *still* tried connecting as the user running the script, so in all cases it is ignoring the settings in
LocalSettings.php.
I don't know why it is complaining about safe mode when I run this stuff from the command line. I know of no reason why that restriction would be in
effect. I doubt it has any effect on the command line, but safe mode is definitely turned off in my httpd.conf for my MediaWiki directory.
I don't really understand why it is so fiendishly difficult to upgrade. Sounds like a bug in the update procedure (possible) or a bug in the release/upgrade
instructions.
Version: 1.6.x
Severity: normal
OS: Linux