Project:Support desk

About this board

Welcome to the MediaWiki Support desk, where you can ask MediaWiki questions!

(Read this message in a different language)

See also

Before you post

Post a new question

  1. To help us answer your questions, please indicate which versions you are using, as found on your wiki's Special:Version page:
    • MediaWiki version
    • PHP version
    • Database type and version
  2. Please include the web address (URL) to your wiki if possible. It's often easier for us to identify the source of the problem if we can see the error directly.
  3. To start a new thread, click "Start a new topic".

Wiki site down. Message says: ERR_TOO_MANY_REDIRECTS

4
2A00:23C6:3B82:B601:8DE:ADF3:6127:9046 (talkcontribs)

Hi, I used a MediaWiki setup for my personal website which can be found here: https://mikepomranz.com/index.php/Main_Page

I installed it myself but am not particularly proficient with MediaWiki or programming in general.

A few weeks ago, the site stopped loading and I have no idea why: whether it's an issue with the install (which worked fine for about a year) or with my webhost (which is Bluehost).

I am receiving an error that "ERR_TOO_MANY_REDIRECTS."

Adding "&nocache=" at the end of the URL remedies the issue and gets the site to load again.

Any thoughts on what may be happening? Thanks!

TheDJ (talkcontribs)
2A00:23C6:3B82:B601:8DE:ADF3:6127:9046 (talkcontribs)

Amazing. Thanks for the diagnosis. Any advice on how to fix a shorturl webserver configuration? I'm guessing that's something I need to deal with through my web host?

(Apologies for these novice questions.)

2A00:23C6:3B82:B601:8DE:ADF3:6127:9046 (talkcontribs)

So I'm digging around in my LocalSettings file and clearly I've messed something up. Is there a way to stop using shorturls?

Reply to "Wiki site down. Message says: ERR_TOO_MANY_REDIRECTS"

I am getting an unknown error?

1
Jeffbezoslittlesister (talkcontribs)

I am getting this error message when i imported Template:Button and I can't seem to find anything about it that is right, i checked the permissions and whatnot, and the permissions seem to be in line.


I am using a Plesk web server, using the GIT install of mediawiki. I don't know what else to supply, so if any more information is needed,p lease do feel free to ask.


I don't know what this error means, but here is what it says:


Lua error: Cannot create process: proc_open(/dev/null): failed to open stream: Operation not permitted

No further details are available.


I apologize if this is the wrong place to ask, i am new here. But if someone could help me out, it would be greatly appreciated, thank you.

Reply to "I am getting an unknown error?"

Using a wikibase for interlingual links

1
Sokote zaman (talkcontribs)

Hello I just want to use wikibase to link languages ​​between multiple wikis. I do not need a wiki data. Please help with this. thank you

Reply to "Using a wikibase for interlingual links"

Issue Upgrading from 1.33.4 to 1.34.0

18
Ljkennedy2000 (talkcontribs)

Error when upgrading from MediaWiki 1.33.4 to 1.34 on main page:


Hi all, I wonder if anyone can help?


When trying to upgrade from 1.33.4 to 1.34 I get the following error:


[YizDPmwd53OgEa32QAw-tQAAAAU] /index.php/Main_Page UnexpectedValueException from line 462 of /var/www/mediawiki-1.34.0/includes/libs/rdbms/loadbalancer/LoadBalancer.php: Invalid server index index #DB_SLAVE

Backtrace:

#0 /var/www/mediawiki-1.34.0/includes/libs/rdbms/loadbalancer/LoadBalancer.php(896): Wikimedia\Rdbms\LoadBalancer->getConnectionIndex(string, array, string)

#1 /var/www/mediawiki-1.34.0/includes/libs/rdbms/loadbalancer/LoadBalancer.php(1043): Wikimedia\Rdbms\LoadBalancer->getConnection(string, array, string, integer)

#2 /var/www/mediawiki-1.34.0/includes/GlobalFunctions.php(2576): Wikimedia\Rdbms\LoadBalancer->getMaintenanceConnectionRef(string, array, string)

#3 /var/www/mediawiki-1.34.0/extensions/DynamicArticleList/DynamicArticleList_body.php(31): wfGetDB(string)

#4 /var/www/mediawiki-1.34.0/includes/parser/Parser.php(4293): DynamicArticleList::renderTag(string, array, Parser, PPFrame_Hash)

#5 /var/www/mediawiki-1.34.0/includes/parser/PPFrame_Hash.php(328): Parser->extensionSubstitution(array, PPFrame_Hash)

#6 /var/www/mediawiki-1.34.0/includes/parser/Parser.php(3330): PPFrame_Hash->expand(PPNode_Hash_Tree, integer)

#7 /var/www/mediawiki-1.34.0/includes/parser/Parser.php(1489): Parser->replaceVariables(string)

#8 /var/www/mediawiki-1.34.0/includes/parser/Parser.php(593): Parser->internalParse(string)

#9 /var/www/mediawiki-1.34.0/includes/content/WikitextContent.php(368): Parser->parse(string, Title, ParserOptions, boolean, boolean, integer)

#10 /var/www/mediawiki-1.34.0/includes/content/AbstractContent.php(555): WikitextContent->fillParserOutput(Title, integer, ParserOptions, boolean, ParserOutput)

#11 /var/www/mediawiki-1.34.0/includes/Revision/RenderedRevision.php(264): AbstractContent->getParserOutput(Title, integer, ParserOptions, boolean)

#12 /var/www/mediawiki-1.34.0/includes/Revision/RenderedRevision.php(236): MediaWiki\Revision\RenderedRevision->getSlotParserOutputUncached(WikitextContent, boolean)

#13 /var/www/mediawiki-1.34.0/includes/Revision/RevisionRenderer.php(215): MediaWiki\Revision\RenderedRevision->getSlotParserOutput(string)

#14 /var/www/mediawiki-1.34.0/includes/Revision/RevisionRenderer.php(152): MediaWiki\Revision\RevisionRenderer->combineSlotOutput(MediaWiki\Revision\RenderedRevision, array)

#15 [internal function]: MediaWiki\Revision\RevisionRenderer->MediaWiki\Revision\{closure}(MediaWiki\Revision\RenderedRevision, array)

#16 /var/www/mediawiki-1.34.0/includes/Revision/RenderedRevision.php(198): call_user_func(Closure, MediaWiki\Revision\RenderedRevision, array)

#17 /var/www/mediawiki-1.34.0/includes/poolcounter/PoolWorkArticleView.php(196): MediaWiki\Revision\RenderedRevision->getRevisionParserOutput()

#18 /var/www/mediawiki-1.34.0/includes/poolcounter/PoolCounterWork.php(125): PoolWorkArticleView->doWork()

#19 /var/www/mediawiki-1.34.0/includes/page/Article.php(791): PoolCounterWork->execute()

#20 /var/www/mediawiki-1.34.0/includes/actions/ViewAction.php(63): Article->view()

#21 /var/www/mediawiki-1.34.0/includes/MediaWiki.php(511): ViewAction->show()

#22 /var/www/mediawiki-1.34.0/includes/MediaWiki.php(302): MediaWiki->performAction(Article, Title)

#23 /var/www/mediawiki-1.34.0/includes/MediaWiki.php(900): MediaWiki->performRequest()

#24 /var/www/mediawiki-1.34.0/includes/MediaWiki.php(527): MediaWiki->main()

#25 /var/www/mediawiki-1.34.0/index.php(44): MediaWiki->run()

#26 {main}


I’ve tried adding new extensions for 1.34, upgrading to different versions ‘upto the latest 1.37.1’ and made sure that the LoadBalancer.php has the DB_REPLICA setting enabled. This only seems to appear on the main page from what I can see.


Thanks

Bawolff (talkcontribs)

Are you sure DynamicArticleList is compatible with your version of mediawiki?

Ljkennedy2000 (talkcontribs)

Hi Bawolff,

Thanks for the response.

Unfortunately my Experience is limited with Media Wiki and i've been tasked with updating our current system, is that an extension of some sort and how would I check compatibility?

Thanks again.

Ljkennedy2000 (talkcontribs)

Hi Bawolff,


I've found the DynamicArticleList.php file in extensions and noticed the following on line 24 -

// The callback function for converting the input text to HTML output

function DynamicArticleList( $input ) {

require_once ('CategoryUtil.php');

$dbr =& wfGetDB( DB_SLAVE );

// INVALIDATE CACHE

global $wgTitle;

$wgTitle->invalidateCache();

// Default Values

$listTitle = false;

$listType = 'new';

$listCount = 5;

$categoryRoot = false;


Should this be set to DB_REPLICA instead of DB_SLAVE  ?


Thanks

Ljkennedy2000 (talkcontribs)

Also it's * Dynamic Article List v2.0

Jonathan3 (talkcontribs)
Ljkennedy2000 (talkcontribs)

Hi Jonathan3,


Thanks for the response. To disable Dynamic Article List is this done in the Localsettings.php?


Thanks for you help.

Bawolff (talkcontribs)

Yes. There should be a line that starts with "require". Find the one for this extension and remove it. (Keep backups just in case)

Ljkennedy2000 (talkcontribs)

Hi,

I upgraded to 1.35.5 and disabled Dynamic Article List in the Localsettings.php which seems to let the main page work now apart from one of our side menus which shows the following error:

<dynamicarticlelist>

title=Recently Update Articles

type=update

count=5

</dynamicarticlelist>

<dynamicarticlelist>

title=Most Popular Articles

type=hot

count=5

</dynamicarticlelist>

Is there something else other than dynamic article lists that could be used to get this working or an update for it maybe?

I then tried upgrading to media wiki 1.36.0 to see if this would resolve it but it didn't work - the whole page seems to have lost images and styling it's showing text for everything 'although it lets me login etc'. The images were copied over and the permissions looked okay, I did have to install php-intl to get to 1.36.0 so i'm not sure if this caused it?

Thanks

Ljkennedy2000 (talkcontribs)

Hi Bawolff,


Thanks for your input I will give it a try :)

Ljkennedy2000 (talkcontribs)

Hi,


I upgraded to 1.35.5 and disabled Dynamic Article List in the Localsettings.php which seems to let the main page work now apart from one of our side menus which shows the following error:

<dynamicarticlelist>

title=Recently Update Articles

type=update

count=5

</dynamicarticlelist>

<dynamicarticlelist>

title=Most Popular Articles

type=hot

count=5

</dynamicarticlelist>

Is there something else other than dynamic article lists that could be used to get this working or an update for it maybe?

I then tried upgrading to media wiki 1.36.0 to see if this would resolve it but it didn't work - the whole page seems to have lost images and styling it's showing text for everything 'although it lets me login etc'. The images were copied over and the permissions looked okay, I did have to install php-intl to get to 1.36.0 so i'm not sure if this caused it?


Thanks

Bawolff (talkcontribs)

There are lots of similiar extensions, like DynamicPageList.

Ljkennedy2000 (talkcontribs)

Hi Bawolff,


I've managed to get to version 1.36 now :) but my next issue is all the main_page entries are in text format, I cannot see any of the images or headers etc.. The images files have been copied over into the correct folder. Could this be a php issue?


Thanks

Bawolff (talkcontribs)

What do you mean by headers?


For images, are their image description pages working?

Ljkennedy2000 (talkcontribs)

Hi Bawolff,


Thanks for the response. Apologies i've probably used the wrong terminology but basically the whole main page is in plain text and it doesn't render any images or sidebars etc when i upgrade from 1.35.0 to 1.36.0, if I move the wikimedia folder back to 1.35.0 it works fine. I've checked the skins folder and that looks the same, i've tried copying over the extensions folder and images but still no luck :(


Thanks

Bawolff (talkcontribs)

Is it just missing css (e.g. everything is text but for example headers and page title are still larger than other text?)

Ljkennedy2000 (talkcontribs)

Hi Bawolff,


Text is different sizes on the main page and links are still there so it looks like it could be missing CSS, is it possible that CSS is in a different location for 1.36.0 to what it was in 1.35.0?


Thanks

Ljkennedy2000 (talkcontribs)

Hi Bawolff,


Thanks for the reply I will try and give that a go.

Reply to "Issue Upgrading from 1.33.4 to 1.34.0"

After migrating a wiki to a new server, my subdirectory permissions are essentially all 777...

7
Drewsaur (talkcontribs)

I manually fixed the top-level subdirectory permissions to match those of a fresh install, but is there a script somewhere that can re-establish the expected permissions of the subdirectories recursively for the sub-sub directories and elements? FWIW, I am on MediaWiki 1.35.5. Thanks!

Bawolff (talkcontribs)
Drewsaur (talkcontribs)

Yes I am quite aware of that flag, but not all of the permissions for each file are supposed to be the same, I could see from the new install. So that won't work...!

Bawolff (talkcontribs)

There is no one right answer for permissions and ownership of mediawiki files - it depends on how your system is setup.

but generally speaking, images subdirectory needs to be readable and writable by the webserver, LocalSettings.php should be readable by webserver but not other users (contains db pass) and should not be writable by webserver, everything else should be readable by webserver but not writable by webserver.

$wgCacheDirectoty, if set, must be readable and writable by webserver, generally it should be outside of web root. For best security ensure php is disabled in images directory.

Drewsaur (talkcontribs)

Understood. I am only referring to the permissions for the standard install directories and their subcontents, which are standard for a given release, such as docs, includes, languages, maintenance, resources, skins, vendor, etc. There are canonical permissions for those that are defined at install time. Other systems I have worked with have permissions-fixings scripts to fix things like this, and I am hoping something similar exists, or that there is at least a document from mediawiki that details the default install permissions for those directories and their contents. Thanks again!

Bawolff (talkcontribs)

If you are looking for a specific number, you probably want 644 on files 755 on directories. There is no mediawiki specific script

Drewsaur (talkcontribs)

Thank you - very helpful!

Reply to "After migrating a wiki to a new server, my subdirectory permissions are essentially all 777..."
79.178.153.224 (talkcontribs)

I have a MediaWiki 1.36.1 website with Skin:Timeless and about 2,000 webpages, most of them (about 51% at least) are about marketing.

The website is all core, no external extensions or skins are installed.

This is my robots.txt syntax pattern:

User-agent: *
Sitemap: https://example.com/sitemap/sitemap.xml
disallow: /index.php?
disallow: /index.php/*:
allow: /index.php/Category:
allow: /index.php/קטגוריה:

The website's performance is very good with Google Page Speed Insights grades of 100/100 (both in mobile and desktop).

But,

The website's SEO is bad with average position of 43.8.

The average position becomes worse every passing day.

The website has only articles and categories --- As far as I know, I have removed anything else from PHP and there are no links to machine pages anywhere.

What may cause bad SEO to that website?

79.178.153.224 (talkcontribs)

The website's SEO is bad with average position of 43.8.

In Google Search Console

Malyacko (talkcontribs)

If Google can tell you that the SEO is bad and some average position, I'd assume that Google can also tell you *why* it's on some average position and what you could do about it. It's unclear to me why you ask here in a MediaWiki support place.

79.178.153.224 (talkcontribs)

I believe that the bad SEO is a legacy from the days that machine pages were indeed linked from various places (such as the sidebar), before I've removed link to these machine pages from PHP.

But if so, what do I do now?

79.178.153.224 (talkcontribs)

A bit of help, someone?

Malyacko (talkcontribs)

A bit of way more patience, please?

79.178.153.224 (talkcontribs)

@Malyacko I don't think I was impatient, rather this thread might went too down under others.

Ciencia Al Poder (talkcontribs)

You're asking about SEO on a MediaWiki support desk.

You'll probably get some answers on a SEO forum (when actually sharing your website so others can take a look), where you can get tips from experienced users.

If you get tips about changes you should make in your MediaWiki installation to better meet your SEO strategy, feel free to post them here and someone can help.

Jonathan3 (talkcontribs)

It's probably more a reflection on your wiki rather than MediaWiki in general. I don't think there's any reason for a MediaWiki website (as a MediaWiki website) not to appear at the top of a search if the content is the best.

Reply to "Bad SEO"

some images missing, stored at another locations

2
Viktor the cleaner (talkcontribs)

Hello, I did a migration of our wiki to another server and a major upgrade from 1.27 (with BlueSpice plugin) to 1.37.1 (pure MediaWiki) and I'm facing several issues now. Some of the images are currently missing and not displayed on the pages. I have just noticed, that they are located in different folders so the links seem to be somehow broken. An example - a file is located here: /wiki/images/d/d3/vnc03.PNG but the links points to this location /wiki/images/9/92/Vnc03.PNG.

I've tried running rebuildImages.php but this had no effect.

Does someone have an idea how to fix this?

Thanks.

viktor@vm-niki:/var/www/html/wiki/maintenance$ php rebuildImages.php Processing image... 2022-05-13 13:14:50: 29.15% done on image; ETA 2022-05-13 13:14:50 [100/343] 1448.20/sec <0.00% updated> Finished image... 0 of 192 rows updated Processing oldimage... Finished oldimage... 0 of 48 rows updated

Product Version
MediaWiki 1.37.1
PHP 7.4.3 (apache2handler)
MySQL 8.0.28-0ubuntu0.20.04.3
ICU 66.1
Ciencia Al Poder (talkcontribs)

BlueSpice may have one extension that allows to have the initial character of the image name as lowercase, while on MediaWiki the first character of all page titles are uppercase.

Note how the image is called "vnc03.PNG" in the old location, but "Vnc03.PNG" on the new one.

You'll have to install the entire BlueSpice stack again, or find which extension was being used for this feature and install it.

Otherwise, you'll have to find the affected images and reimport them again with the importImages.php maintenance script. Those leftover initial-lowercase images may require some manual cleanup, though.

Reply to "some images missing, stored at another locations"
Jjarrells69 (talkcontribs)
Product Version
MediaWiki 1.35.6
PHP 8.0.18 (cgi-fcgi)
MariaDB 10.3.13-MariaDB
ICU 68.2

I run a mediawiki server behind a firewall and users have to access it through a NAT ip address. When trying to use the Visual Editor they are getting an error "Error contacting the Parsoid/RESTBase server: (curl error:7) Couldn't contact the server. I have to set the server in the local.php to the NAT address to get the mediawiki to work. I'm sure this is causing the error with Visual Editor. Has anyone else had this issue?

thank you

Reply to "Visual Editor error"
2600:1700:D590:A5E0:6133:2D33:5F40:84B4 (talkcontribs)

I had an offense 3 months ago. I have been banned. The time is over, and I am asking the ban to be lifted.

The agreement was 3monts banning and today is 3 months.


Please consider.


Herzakov

Bawolff (talkcontribs)

this is not the right place to make this request. You need to make this request at the wiki you were banned on. You should probably include your username.

Reply to "I am banned."
197.207.150.111 (talkcontribs)

How do I install the Sanitized CSS content model? --197.207.150.111 17:26, 14 May 2022 (UTC)

Bawolff (talkcontribs)
Reply to "Sanitized CSS"