Project:Support desk

Jump to: navigation, search

About this board

vde   Welcome to MediaWiki.org's Support desk, where you can ask MediaWiki questions!

There are also other places where to askCommunication: IRCCommunication#Chat, mailing listsMailing lists, Q&A etc.

Before you post

Post a new question

  1. To help us answer your questions, please always indicate which versions you are using (reported by your wiki's Special:Version page):
    • MediaWiki
    • PHP
    • Database
  2. Please include the URL of your wiki unless you absolutely can't. It's often a lot easier for us to identify the source of the problem if we can look for ourselves.
  3. To start a new thread, click "Start a new topic".
Language: English  español
By clicking "Add topic", you agree to our Terms of Use and agree to irrevocably release your text under the CC BY-SA 3.0 License and GFDL
73.4.80.180 (talkcontribs)

Hello all. Just upgraded via dnf (Fedora 24) from mediawiki 1.26.4-1 to 1.27.1-1. I ran the db upgrade script with no problem. When I try to access the wiki now, I get this error:

Fatal error: Class 'Wikimedia\PhpSessionSerializer' not found in /usr/share/mediawiki/includes/session/PHPSessionHandler.php on line 161

I made no changes other than the install and upgrade script.

A search for php session serializer returned this:

/usr/share/mediawiki/vendor/wikimedia/php-session-serializer

/usr/share/mediawiki/vendor/wikimedia/php-session-serializer/formats.md

/usr/share/mediawiki/vendor/wikimedia/php-session-serializer/README.md

/usr/share/mediawiki/vendor/wikimedia/php-session-serializer/src

/usr/share/mediawiki/vendor/wikimedia/php-session-serializer/src/Wikimedia

/usr/share/mediawiki/vendor/wikimedia/php-session-serializer/src/Wikimedia/PhpSessionSerializer.php

/usr/share/mediawiki/vendor/wikimedia/php-session-serializer/COPYING

I am not an expert in mediawiki by any means, any help would be appreciated.

mediawiki 1.27.1-1

php 5.6.28-1

database mariadb (mysql) 10.1.19

AhmadF.Cheema (talkcontribs)

Maybe composer needs to be updated?

73.4.80.180 (talkcontribs)

I installed mediawiki via dnf (rpm package) all dependencies should already be met, is that correct?

Reply to "Error after upgrade"

bxr.wiki wikitext and VisualEditor broken?

1
Elvonudinium (talkcontribs)

Please take a look at Buryat Wikipedia engine. I suspect there is something wrong with the interface. 1. The editing interface does not load. Wikitext editing works only partially, and VisualEditor does not work at all. 2. For not-logged in users the main page displays a page from several days ago. I spotted both problems from several computers and browsers.

Reply to "bxr.wiki wikitext and VisualEditor broken?"

Updated to 1.28 today and i cannot get the SyntaxHighlight_GeSHi working

9
Summary by AhmadF.Cheema

Issue resolved by using external pygmentize binary.

50.106.19.97 (talkcontribs)

I used the 1.28.0 downloadable tar.gz file from the official download page.

I am running on FreeBSD 9.1-RELEASE-p3

The wiki is working normally after upgrade in that it shows all my pages, files, etc. However, all my highlights in bash, perl, python, etc. are showing up like <pre> sections instead of with colors like they normally did before the upgrade. Here is the output of my Version page:

Product Version
MediaWiki 1.28.0
PHP 5.6.27 (apache2handler)
MariaDB 10.0.27-MariaDB
ICU 58.1

Entry point URLs

Entry point URL
Article path /wiki/$1
Script path /w
index.php /w/index.php
api.php /w/api.php
load.php /w/load.php

Installed skins

Skin Version License Description Authors
MonoBook GPL-2.0+ The classic MediaWiki skin since 2004, named after the black-and-white photo of a book in the page background Gabriel Wicke and others

Installed extensions

Parser hooks
Extension Version License Description Authors
SyntaxHighlight 2.0 (65073ad)17:03, 24 October 2016 GPL-2.0+ Provides syntax highlighting <syntaxhighlight> using Pygments - Python syntax highlighter Brion Vibber, Tim Starling, Rob Church, Niklas Laxström, Ori Livneh and Ed Sanders

I have made sure the pygmentize binary is executable and i've run it myself with -V and got version 1.21 which is in the 1.28.0 mediawiki tar.gz.

Does anyone have any idea of anything I might have missed?

<syntaxhighlight lang="bash">

#!/usr/local/bin/bash

echo -ne "ada0 : " && smartctl -a /dev/ada0 | grep Temp | awk '{ print $10 }'

echo -ne "ada1 : " && smartctl -a /dev/ada1 | grep Temp | awk '{ print $10 }'

echo -ne "ada2 : " && smartctl -a /dev/ada2 | grep Temp | awk '{ print $10 }'

echo -ne "ada3 : " && smartctl -a /dev/ada3 | grep Temp | awk '{ print $10 }'

echo -ne "ada4 : " && smartctl -a /dev/ada4 | grep Temp | awk '{ print $10 }'

echo -ne "ada5 : " && smartctl -a /dev/ada5 | grep Temp | awk '{ print $10 }'

</syntaxhighlight>

RESULT:

#!/usr/local/bin/bash
echo -ne "ada0 : " && smartctl -a /dev/ada0 | grep Temp | awk '{ print $10 }'
echo -ne "ada1 : " && smartctl -a /dev/ada1 | grep Temp | awk '{ print $10 }'
echo -ne "ada2 : " && smartctl -a /dev/ada2 | grep Temp | awk '{ print $10 }'
echo -ne "ada3 : " && smartctl -a /dev/ada3 | grep Temp | awk '{ print $10 }'
echo -ne "ada4 : " && smartctl -a /dev/ada4 | grep Temp | awk '{ print $10 }'
echo -ne "ada5 : " && smartctl -a /dev/ada5 | grep Temp | awk '{ print $10 }'
58.164.108.250 (talkcontribs)

Check for any errors in the browser console, perhaps an error is preventing the styling from loading.

AhmadF.Cheema (talkcontribs)

You have made the pygmentize binary executable by "User" or "World"?

50.106.19.97 (talkcontribs)

It's world executable

AhmadF.Cheema (talkcontribs)

Try setting the rights to allow "User" to be able to execute too and then try again.

Octavianh (talkcontribs)

Here is the output of the permissions on the binary:

drwxr-xr-x  2 www  www       7 Nov 28 11:21 .

drwxr-xr-x  7 www  www      19 Nov 28 11:21 ..

-rw-r--r--  1 www  www    7326 Nov 28 11:21 AUTHORS

-rw-r--r--  1 www  www    1330 Nov 28 11:21 PYGMENTS_LICENSE

-rw-r--r--  1 www  www       4 Nov 28 11:21 VERSION

-rwxr-xr-x  1 www  www    1852 Nov 28 11:21 create_pygmentize_bundle

-rwxr-xr-x  1 www  www  754672 Nov 28 11:21 pygmentize

AhmadF.Cheema (talkcontribs)

These permissions should've worked, so the issue is probably somewhere else.

See this phabricator task opened for this bug, maybe you will find something here which helps.

Octavianh (talkcontribs)

i'm getting this error in debug:

[Preprocessor] Cached preprocessor output (key: wiki:preprocess-xml:6a88b2bdb1bee6bbf0a2a002f1d79c5d:0)

[error] [694ffd93e3aebc31d7e87cf8] /wiki/FreeBSD_arc_summary.pl   ErrorException from line 311 of /data/www/www/mediawiki/includes/debug/MWDebug.php: PHP Notice: Failed to invoke Pygments: env: python: No such file or directory

[Called from SyntaxHighlight_GeSHi::highlight in /data/www/www/mediawiki/extensions/SyntaxHighlight_GeSHi/SyntaxHighlight_GeSHi.class.php at line 296]

i verified and i have the following package installed:

py27-pygments-2.1.3

path:

-rwxr-xr-x  1 root  wheel  399 Nov 30 12:24 /usr/local/bin/pygmentize

what is the option to point to an external pygmentize binary in LocalSettings?

Octavianh (talkcontribs)

fixed, i used this:

$wgPygmentizePath = "/usr/local/bin/pygmentize";

This was quite the nightmare but it's working now.

thanks Ahmad.

How do I reuse MediaWiki templates between wikis?

2
195.234.74.168 (talkcontribs)

Hello.

While editiing my wikis a lot I noticed that I would like to create a sort of a library out of the templates that are used on all of those wikis (especially the ones that put metadata onto pages in Semantic MediaWiki). This question may be too broad, but what are the best practices of sharing MediaWiki markup between wikis? Would it be possible to make it in "library fashion" somehow so I could put the templates in a certain repository? Another point of such an approach, I think, might be just sharing the templates world-wide, let's say, on GitHub/BitBucket/etc.

Any advices and answers are greatly appreciated! Thank you in advance!

Cavila (talkcontribs)

Of course, templates can be complex, site-specific creatures with dependencies on many other templates, extensions, semantic data, etc., which then also need to be transcluded or enabled on your wiki - simply borrowing a template would not always work out of the box. I think you would need to come up with your own way of managing the templates that you need for your wikis. If you are using SMW, you could use that to store data about their usage and create some sort of a library.

See also: Manual:$wgEnableScaryTranscluding (but the above comment also applies here).

Reply to "How do I reuse MediaWiki templates between wikis?"
Cavila (talkcontribs)

Is it possible to partially suppress search box autocompletion for anonymous 'users' (visitors who have not logged on to the site)? I'm primarily thinking of the following scenarios:

# select pages (e.g. using a magic word)

# pages whose namespaces have ben made inaccessible through Extension:Lockdown

Reply to "Question about search autocompletion"
Aarango1 (talkcontribs)

Hi,

====

Hi,

I am trying to install in another server mediawiki with auth LDAP on main server. (iredMail really + LDAP)

I have LDAP installed and working on main server and mediawiki running too in another server. Now I want to install plugin LDAP on mediawiki, but I can't do it because I receive some fails.

Info

LocalSettings.php

require_once( "extensions/LdapAuthentication/LdapAuthentication.php" );

$wgAuth = new LdapAuthenticationPlugin();

$wgLDAPDomainNames = array("iRedMail");

$wgLDAPServerNames = array("iRedMail" => "192.168.XX.XX");

$wgLDAPPort = array("iRedMail" => 389);

$wgLDAPEncryptionType = array( "iRedMail" => "clear");

$wgLDAPBaseDNs = array( "iRedMail"=>"o=domains,dc=example,dc=com");

$wgLDAPProxyAgent = array("iRedMail"=>"cn=vmail,dc=example,dc=com");

$wgLDAPProxyAgentPassword = array( "iRedMail"=>"PasswordBindPW");

$wgLDAPUserBaseDNs = array( "iRedMail"=>"o=domains,dc=example,dc=com");

$wgLDAPSearchAttributes = array( "iRedMail" => "mail");

$wgLDAPLowerCaseUsername = array( "iRedMail"=>true);

$wgLDAPUseLocal = true;

$wgLDAPDebug = 3;

$wgDebugLogGroups['ldap'] = '/tmp/debug.log';

If I try to connect I receive this on debug.log

2016-12-02 09:19:38 mikro wikidb: 2.1.0 basedn is o=domains,dc=example,dc=com

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Using base: o=domains,dc=example,dc=com

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Setting the LDAPUsername based on fetched wgLDAPSearchAttributes: pepe@mx.example.com

2016-12-02 09:19:38 mikro wikidb: 2.1.0 userdn is: mail=pepe@mx.example.com,ou=Users,domainName=mx.example.com,o=domains,dc=example,dc=com

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering getDomain

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Pulling domain from session.

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Binding as the user

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Bound successfully

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering getDomain

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Pulling domain from session.

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering getDomain

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Pulling domain from session.

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering getGroups

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering getDomain

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Pulling domain from session.

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering getDomain

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Pulling domain from session.

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering checkGroups

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering getDomain

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Pulling domain from session.

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering getDomain

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Pulling domain from session.

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering getPreferences

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering getDomain

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Pulling domain from session.

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Authentication passed

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering getCanonicalName

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Username is: Pepe@mx.example.com

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering getDomain

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Pulling domain from session.

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Munged username: Pepe@mx.example.com

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Allowing the local domain, adding it to the list.

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering allowPasswordChange

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering getDomain

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Pulling domain from session.

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering getDomain

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Pulling domain from session.

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering getDomain

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Pulling domain from session.

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering modifyUITemplate

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering getDomain

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Pulling domain from session.

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering getDomain

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Pulling domain from session.

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering getDomain

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Pulling domain from session.

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Allowing the local domain, adding it to the list.

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering getCanonicalName

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Username is: Admin

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Entering getDomain

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Pulling domain from session.

2016-12-02 09:19:38 mikro wikidb: 2.1.0 Munged username: Admin

I see "Succesfully" on connect to LDAP server but Mediawiki can't login with this error:

Automatic creation of a local account failed: A valid username was not specified.

Why? How could I fix it?

Maybe Should I edit some config on Mediawiki to disable automatic creation account?

Maybe Am I using bad values on String?

Thanks

Greetings.

Reply to "LDAP + Mediawiki"

[RESOLVED] invoke infobox error in mediawiki (template copied from Wikipedia)

13
180.149.49.231 (talkcontribs)

I have installed the latest mediawiki and i am having trouble installing infobox in my mediawiki. After a lot of searching in web i found this tutorial http://trog.qgl.org/20110815/setting-up-infobox-templates-in-mediawiki. I have done all things as described in the tutorial , downloaded the template:infobox xml then imported in my wiki made proper changes in my common.css ,localsetting.php. But when i put the example code given in the tutorial in my wiki its giving this error.

{{#invoke:Infobox|infobox}} http://i44.tinypic.com/157m0bd.png

Creating a infobox in mediawiki is making me mad,any help will be appreciated

Advance thanks for input

77.250.212.237 (talkcontribs)

Exactly the same problem over here. Any help would be nice.

Thanks in advance.

Ciencia Al Poder (talkcontribs)

Wikipedia is now using Extension:Scribunto for heavy templates like this.

You need to install that extension or select an old version of the template, prior of the switch to Scribunto / Lua .

173.57.184.105 (talkcontribs)

I've installed the Scibunto extension and I'm still getting this error. I *did* have to comment out the sort function in LuaCommon.php to get the extension to run. I did an export/import to copy the templates into my wiki.

I presume the problem is that I'm using MW 1.19 and WP is on the latest version. Upgrading is too much of a hassle. Guess I'm stuck with stripping out templates...

116.202.96.220 (talkcontribs)

I am getting errors as bellow after setting up Extension:Scribunto

Script error: No such module "Infobox".
Script error: No such module "citation/CS1".
Template:Cite news
116.202.96.220 (talkcontribs)

My error URL

wikicinema.org/index.php?title=Mammootty
Ciencia Al Poder (talkcontribs)

The errors are self-explanatory:

There's no Module:Infobox nor Module:citation/CS1 on your wiki. Try creating/importing them?

66.3.7.50 (talkcontribs)

And so would anyone care to explain how to actually do the task of "Try creating/importing them?" so that someone can actually follow a list of instructions to do this task?

JamesPoulson (talkcontribs)

As 66.3.7.50 says it is not clear how modules should be imported.

Lua has been installed.

However, attempting to add a source to a module page gives a "Fatal exception of type MWException".

I will dig into this by displaying debug and have been searching for a solution for around a week.

I'm a developer so it's not the technical manipulations that are a problem and it's just unfamiliarity with how mediawiki functions.

This comment was hidden by 66.3.7.50 (history)
116.202.96.220 (talkcontribs)
This comment was hidden by 66.3.7.50 (history)
Ciencia Al Poder (talkcontribs)

Manual:Importing Wikipedia infoboxes tutorial

Reply to "[RESOLVED] invoke infobox error in mediawiki (template copied from Wikipedia)"

Retrieving lost data after MW Zip closed

5
108.30.56.174 (talkcontribs)

Hello, I'm part of a group that had a wiki hosted by MW Zip, which closed down unexpectedly a few weeks ago. We don't have a backup of our data, and haven't been able to contact anyone from MW Zip for help. Anyone have suggestions for how we might be able to access our data, or contact whoever was running MW Zip? Any help appreciated, thanks!

Wargo (talkcontribs)

Maybe archived in Web Archive?

108.30.56.174 (talkcontribs)

Thanks for the suggestion Wargo, but that doesn't seem to be working, I think because it wasn't a publicly accessible wiki.

Any other ideas?? Does anyone have any info on who was running MW Zip or how we might contact them? Or has anyone had similar experiences losing and retrieving wiki data in the past?

AhmadF.Cheema (talkcontribs)

Maybe try sending a message to their twitter account.

108.30.56.174 (talkcontribs)

Thanks Ahmad for the suggestion. We've been trying that for the past couple of weeks, without luck so far.

Reply to "Retrieving lost data after MW Zip closed"
Bwfreas (talkcontribs)

#$wgSecureLogin = true;

$wgServer = "//10.10.10.1";

When I enable the wgSecureLogin i cant access the site at all (http or https). I have a second instance of mediawiki on a different server that is working via https but i am not sure why i cannot get this instance to work?

Reply to "https for mediawiki not working"
Resplendent (talkcontribs)

When upgrading from MW 1.24 to 1.26.2, I'm running into this error:

MediaWiki 1.26 internal error

Installing some external dependencies (e.g. via composer) is required.

External dependencies

MediaWiki now also has some external dependencies that need to be installed via composer or from a separate git repo. Please see mediawiki.org for help on installing the required components.

I've installed Composer and run the installation and upgrade commands, but nothing seems to fix this. How do I install these external dependencies? The documentation on this is difficult to understand.

URL: http://rose.irowiki.org/wiki/Special:Version

87.123.13.117 (talkcontribs)

How are you installing MediaWiki?

The recommended way is to download the tarball and to extract it to a new folder. Then move your installation specific files in there and run update.php. These steps do not need composer to be run.

87.123.13.117 (talkcontribs)

When I visit your wiki, I see that you have this problem:

Manual:Load.php#Styles not displaying

Ciencia Al Poder (talkcontribs)

Looks like $wgScriptPath is not set correctly

Tjyderrien (talkcontribs)

Good evening. It seems I have also this problem.

When updating from MediaWiki 1.19 to 1.28, I well extracted new files in another folder, but I get the same problem. You can check here: http://www.quantumlap.eu/wikiflaps1.28/

All the best,

Thibault

Reply to "Upgrading Error"