Topic on Project:Support desk

updateSearchIndex: Couldn't write to the searchUpdate.MyWiki.pos

5
Summary by Ciencia Al Poder

Documentation of Manual:updateSearchIndex.php updated

Subfader (talkcontribs)

When I run maintenance/updateSearchIndex.php I get the error

<pre>

--- Unlocking --

Done

*** Couldn't write to the searchUpdate.MyWiki.pos!

</pre>

Does the maintenance directory needs some write rights? Atm is has <code>drwxr-xr-x 17 user-mywiki psacln</code>.

MarkAHershberger (talkcontribs)

The maint directory shouldn't need write permissions. The error (Couldn't write to searchUpdate.MyWiki.pos) can be overcome by using the "-p" option to specify a location that is writable. See UpdateSearchIndex.php. Error reporting here could be improved. I've created a task for that.

Subfader (talkcontribs)
Deletedaccount4567435 (talkcontribs)

I got same problem. I build the searchindex by

CREATE TABLE `searchindex` (

  `si_page` int(10) UNSIGNED NOT NULL,

  `si_title` varchar(255) NOT NULL DEFAULT '',

  `si_text` mediumtext NOT NULL

) ENGINE=MyISAM DEFAULT CHARSET=utf8;

ALTER TABLE `searchindex`

  ADD UNIQUE KEY `si_page` (`si_page`);

ALTER TABLE `searchindex` ADD FULLTEXT KEY `si_title` (`si_title`);

ALTER TABLE `searchindex` ADD FULLTEXT KEY `si_text` (`si_text`);

then maintenance/updateSearchIndex.php give me Couldn't write to the searchUpdate.MyWiki.pos! .

/updateSearchIndex.php /tmp/writable give me Couldn't write to the /tmp//writable! .

rebuildtextindex.php successfully ran, but did nothing in Table: searchindex. It's still empty any how....

I got elasticsearch installed. Is the index been wrote to elasticsearch?

194.95.59.150 (talkcontribs)

What worked for me is creating the searchUpdate.MyWiki.pos file first by doing a

"touch /path/to/MyWiki/maintenance/searchUpdate.MyWiki.pos" (on Linux systems), then making sure it's writeble to the user executing the task and then doing

"cd /path/to/MyWiki/maintenance && php updateSearchIndex.php"