Topic on Project:Support desk

Trouble with Categories not Populating

10
HSRobinson (talkcontribs)

Try


cd maintenance

php rebuildall.php


That may help.

IcarusATB (talkcontribs)

Also, of note … down the thread, I mentioned that your later help solved my problem.

But, it's interesting that I did have to use "change directories" as you mention here, after all.

I don't know why it wouldn't accept the command from one folder up, but, it made a difference!

IcarusATB (talkcontribs)

@HSRobinson … thank you for the tip.

Unfortunately, I did already try that, but, also just tried it again, to make sure that running it from that particular directory made a difference. I got the same result, asking for a variable in line47, for whatever it's worth.

Thank you, though.

AhmadF.Cheema (talkcontribs)

Did you recently upgrade MediaWiki?

IcarusATB (talkcontribs)

@AhmadF.Cheema … nope, this is an installation that is scarcely two weeks old. First time installation.

IcarusATB (talkcontribs)

For sake of saying … in the MediaWiki installation, the line that is being questioned when I try to run it (Line47) is in this section:

42       public function execute() {
43          // Rebuild the text index
44          if ( $this->getDB( DB_REPLICA )->getType() != 'postgres' ) {
45               $this->output( "** Rebuilding fulltext search index (if you abort "
46                   . "this will break searching; run this script again to fix):\n" );
47          $rebuildText = $this->runChild( RebuildTextIndex::class, 'rebuildtextindex.php' );
48          $rebuildText->execute();
49        }
2001:16B8:1040:AA00:343F:8B13:F674:9870 (talkcontribs)

The CLI version of PHP does not necessarily have to be the same version as the one the webserver uses.

Please run php --version on the command line and tell us the PHP version you have there. My guess is that the CLI version of PHP, which you are using, is too old.

IcarusATB (talkcontribs)

OMG, OMG , OMG!!! THIS IS SO IT!!! @HSRobinson this was difficult, no doubt! I had to really try hard to figure out what the article (and the answer to the question) was really telling me to do. It wasn't immediately clear that I was altering the code within a file, and that I had to type in the altered code, and save it.

That seems simple, I know, but, once I "got it", the CLI immediately responded that I was now running PHP7.1!!!

And then, once followed the directions of the Help:rebuildall page, the CLI immediately began running the Rebuild!!

It's doing it all RIGHT NOW AS WE SPEAK!!

Thank you, thankyou, thankyou!

I can't thank you enough. I appreciate the help, SO MUCH!!

2001:16B8:10C8:4800:F9B9:FDD5:FA16:F61D (talkcontribs)

You need to do one of two things now: Either find out the command, with which you can run a newer version of PHP on the CLI. That might e.g. be php70 (does php70 --version work?) or something like that.

If however, a newer CLI version of PHP is not currently installed on the server, then it first needs to be installed and then you can use it.

Bawolff (talkcontribs)

Note, categories not updating may be indicative of a problem with the Job queue (which may be a separate issue from your issue running rebuildAll.php)