Last modified: 2010-05-15 15:33:25 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 1734 - granting db permissions fails
granting db permissions fails
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
Installer (Other open bugs)
1.4.x
All All
: Normal normal (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2005-03-23 01:16 UTC by Johannes Stezenbach
Modified: 2010-05-15 15:33 UTC (History)
0 users

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Johannes Stezenbach 2005-03-23 01:16:12 UTC
MediaWiki 1.4.0 installation

Please include all of the lines below when reporting installation problems.
Checking environment...

    * PHP 4.3.10-2: ok
    * PHP server API is apache; ok, using pretty URLs (index.php/Page_Title)
    * Have XML / Latin1-UTF-8 conversion support.
    * PHP's memory_limit is 8M. If this is too low, installation may fail!
Attempting to raise limit to 20M... ok.
    * Have zlib support; enabling output compression.
    * Turck MMCache installed
    * Found ImageMagick: /usr/bin/convert; image thumbnailing will be enabled if
you enable uploads.
    * Installation directory: /var/www/v4lwiki
    * Script URI path: /v4lwiki
    * Connected as root (automatic)
    * Connected to database... 4.0.23_Debian-4; enabling MySQL 4 enhancements
    * Created database v4l-wikidb
    * Creating tables... done.
    * Initializing data...
    * Granting user permissions...
      Query "GRANT DELETE,INSERT,SELECT,UPDATE ON `v4l-wikidb`.* TO
v4l-wikiuser@'%' IDENTIFIED BY '*******'" failed with error code "You have an
error in your SQL syntax. Check the manual that corresponds to your MySQL server
version for the right syntax to use near '-wikiuser@'%' IDENTIFIED BY
'********'' at line 1".

Probably the dash in the db name or db user name is not tolerated?
This worked fine with 1.3.11.
Comment 1 Richard J. Holton 2005-03-23 02:53:56 UTC
Indeed, this appears to be an issue with the special character "-". From the
MySQL reference manual page on GRANT (http://dev.mysql.com/doc/mysql/en/grant.html):

In order to accommodate granting rights to users from arbitrary hosts, MySQL
supports specifying the user value in the form user_name@host_name. If a
user_name or host_name value is legal as an unquoted identifier, you need not
quote it. However, quotes are necessary to specify a user_name string containing
special characters (such as '-'), or a host_name string containing special
characters or wildcard characters (such as '%'); for example,
'test-user'@'test-hostname'. Quote the username and hostname separately.

In this case, I'm guessing that v4l-wikiuser needs to be quoted for the query to
work.
Comment 2 Richard J. Holton 2005-03-23 03:11:41 UTC
Looks like this particular error can be eliminated by changing
maintenance\users.sql to put quotes around {$wgDBuser}:

GRANT DELETE,INSERT,SELECT,UPDATE ON `{$wgDBname}`.*
 TO '{$wgDBuser}'@'%' IDENTIFIED BY '{$wgDBpassword}';
GRANT DELETE,INSERT,SELECT,UPDATE ON `{$wgDBname}`.*
 TO '{$wgDBuser}'@localhost IDENTIFIED BY '{$wgDBpassword}';
GRANT DELETE,INSERT,SELECT,UPDATE ON `{$wgDBname}`.*
 TO '{$wgDBuser}'@localhost.localdomain IDENTIFIED BY '{$wgDBpassword}';

Note that I've not tested this! (I'm not currently set up to do so...). 

Note also that, though this may fix the current bug, there may be related 
issues elsewhere.
Comment 3 Antoine "hashar" Musso (WMF) 2005-08-17 19:54:04 UTC
Fixed the users.sql using Richard J. Holton's patch.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links