Hugo wrote: It's a limitation on mysql nothing to do with MediaWiki. Change your 'my.cnf' file to contain at least the following: [mysqld] ft_min_word_len=2 [myisamchk] ft_min_word_len=2 and then even 2-character words should be searchable. Once you change this parameter, you need to rebuild the text index by running maintenance/rebuildtextindex.php
Peter Blaise responds: Thanks, Hugo! But, MySQL v5 has a "my.ini" not a "my.cnf". Same? Anyway, I put those 4 lines into "my.ini". But, I then get the typical "can't do that here" challenges. Is it as simple as supplying a MySQL "root" name and password on the input of the command line or elsewhere? Here's what happens:
(Input) C:\www\apache2\htdocs\mediawiki\maintenance> php rebuildtextindex.php [Enter]
(Result) PHP Notice: Undefined variable: wgDBadminuser in C:\www\apache2\htdocs\mediawik i\maintenance\rebuildtextindex.php on line 15
PHP Notice: Undefined variable: wgDBadminpassword in C:\www\apache2\htdocs\medi awiki\maintenance\rebuildtextindex.php on line 15
DB connection error: Access denied for user 'ODBC'@'localhost' (using password: NO) (localhost)
... can I just put the MySQL user and password hard-wired into the "rebuildtextindex.php" script and try again, or what? Does MySQL need an off/on cycle to see the changes?
Here's line 15, by the way:
$database = Database::newFromParams( $wgDBserver, $wgDBadminuser, $wgDBadminpassword, $wgDBname );
Thanks! -- Peter Blaise
Monahon, Peter B. wrote :
Thanks, Hugo! But, MySQL v5 has a "my.ini" not a "my.cnf". Same? Anyway, I put those 4 lines into "my.ini". But, I then get the typical "can't do that here" challenges. Is it as simple as supplying a MySQL "root" name and password on the input of the command line or elsewhere? Here's what happens:
(Input) C:\www\apache2\htdocs\mediawiki\maintenance> php rebuildtextindex.php [Enter]
(Result) PHP Notice: Undefined variable: wgDBadminuser in C:\www\apache2\htdocs\mediawik i\maintenance\rebuildtextindex.php on line 15
PHP Notice: Undefined variable: wgDBadminpassword in C:\www\apache2\htdocs\medi awiki\maintenance\rebuildtextindex.php on line 15
DB connection error: Access denied for user 'ODBC'@'localhost' (using password: NO) (localhost)
... can I just put the MySQL user and password hard-wired into the "rebuildtextindex.php" script and try again, or what? Does MySQL need an off/on cycle to see the changes?
Here's line 15, by the way:
$database = Database::newFromParams( $wgDBserver, $wgDBadminuser, $wgDBadminpassword, $wgDBname );
Thanks! -- Peter Blaise
have a look at maintenance/README ... (more particularly the line about AdminSettings.php)
Hi Peter,
Yeah, the example is on linux (and i've tried this on mysql v5 only) that's why it's a "my.cnf". If it's in windows it should be "my.ini" indeed.
For the rebuildtextindex.php to work you need to rename AdminSettings.sample to AdminSettings.php (if it's not already) and configure a mysql power user there so it can makes the changes needed.
And if you change anything on the my.ini, yes you need to restart the service for it to "see it".
Best Regards,
Hugo Picão
-----Original Message----- From: mediawiki-l-bounces@lists.wikimedia.org [mailto:mediawiki-l-bounces@lists.wikimedia.org] On Behalf Of Monahon, Peter B. Sent: sexta-feira, 22 de Junho de 2007 13:57 To: mediawiki-l@lists.wikimedia.org Subject: Re: [Mediawiki-l] Using search for a 3 letter word
Hugo wrote: It's a limitation on mysql nothing to do with MediaWiki. Change your 'my.cnf' file to contain at least the following: [mysqld] ft_min_word_len=2 [myisamchk] ft_min_word_len=2 and then even 2-character words should - be searchable. Once you change this parameter, you need to rebuild the text index by running maintenance/rebuildtextindex.php
Peter Blaise responds: Thanks, Hugo! But, MySQL v5 has a "my.ini" not a "my.cnf". Same? Anyway, I put those 4 lines into "my.ini". But, I then get the typical "can't do that here" challenges. Is it as simple as supplying a MySQL "root" name and password on the input of the command line or elsewhere? Here's what happens:
(Input) C:\www\apache2\htdocs\mediawiki\maintenance> php rebuildtextindex.php [Enter]
(Result) PHP Notice: Undefined variable: wgDBadminuser in C:\www\apache2\htdocs\mediawik i\maintenance\rebuildtextindex.php on line 15
PHP Notice: Undefined variable: wgDBadminpassword in C:\www\apache2\htdocs\medi awiki\maintenance\rebuildtextindex.php on line 15
DB connection error: Access denied for user 'ODBC'@'localhost' (using password: NO) (localhost)
... can I just put the MySQL user and password hard-wired into the "rebuildtextindex.php" script and try again, or what? Does MySQL need an off/on cycle to see the changes?
Here's line 15, by the way:
$database = Database::newFromParams( $wgDBserver, $wgDBadminuser, $wgDBadminpassword, $wgDBname );
Thanks! -- Peter Blaise
_______________________________________________ MediaWiki-l mailing list MediaWiki-l@lists.wikimedia.org http://lists.wikimedia.org/mailman/listinfo/mediawiki-l
mediawiki-l@lists.wikimedia.org