Open main menu

MediaWiki β

Project:Support desk

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".

Is there any way to block or selectively kill geo info from pictures I uploaded?

3
Summary last edited by RedKnight7 00:40, 21 November 2017 1 day ago

If it helps any other newbie. After experimentation I found Bawolff's reply to more precisely mean:

SELECT img_name from image where img_metadata like '%GPSL%';

Where "image" should be the name of your mediawiki dataset. For me, it was named mw_image

Using the SiteGround SQL tools I have, my particular MediaWiki files were located in a \MediaWiki directory off my public site root directory. They had a somewhat arbitrary name assigned when first made (like [domain_name]_mw[number]\mw_image

Hope this helps.

Thanks again, Bawolff! Now I see other pictures with geocoords.

If anyone can ever make a utility to block geocoords? That sure is a lot simpler than never messing up, or having to delete the entire page and start over, if you do.

RedKnight7 (talkcontribs)

Hi everyone,

I uploaded a bunch of pictures to my personal mediawiki site, then realized I forgot to wipe geocoords from them (which can be clearly seen on their metadata pages). I'm just an amateur site builder, but this presents multiple problems:

1) Even if I edit the image and upload a new version with geo info wiped, doesn't the old version remain, with its geo info?

2) How can I be sure I haven't goofed and left a geocoord across the many pictures I've uploaded? Maybe dozens or hundreds; not sure how many were screen captures, and how many from my phone.

In short, I think I am looking for a tool that will wipe and/or block any and all geocoords on any of my pictures, passively and forever more.

Does anyone know of such a thing? Thanks so much if you can help!

P.S. I am using 1.27.1 of MediaWiki, from Sept. 2016 or so.

Bawolff (talkcontribs)

You need to upload a new version, and delete the old version (If you have revision deletion, you can just set the old version of the image content to be deleted and keep the rest of the history).

You can try to get a list of such photos by doing a query on the database like SELECT img_name from image where img_metadata like '%GPSL%';

p.s. Edit - As RedKnight7 noted above, if you're using $wgDBPrefix, then you need to add that to the image name.

Ciencia Al Poder (talkcontribs)

For blocking uploads that contain geocoords you can implement a UploadVerifyFile hook to check metadata of the file and reject it (apparently it should be accessible from UploadBase::getImageInfo()).

Reply to "Is there any way to block or selectively kill geo info from pictures I uploaded?"
Kayzingzingy (talkcontribs)

I'm writing a script that calls the api about 3 times with different requests.

I wrote it a few weeks ago and had no issues. I ran it probably about a dozen times.

Today I tried to run it and I always get a DDoS protection response. What can I do to prove I'm not trying to do a DDoS attack?

Malyacko (talkcontribs)

Have you contacted the admin of that website which hosts that wiki?

Kayzingzingy (talkcontribs)

No, I wasn't sure if it is a mediaWiki thing or an individual wiki. I will try to contact them.

Kayzingzingy (talkcontribs)

I actually tried it again today and am no longer getting that response. I wonder if it only does that check when there is heavy load or something.

Incorrect weblinks - Rhylanor Subsector maps

2
Zoltan-Zandar (talkcontribs)

The two right-hand weblinks on the Rhylanor Subsector maps lead to the Star Lane Subsector page instead of Sabine's.

Also, the right-hand link on the top map in labelled 'Star Lane' instead of Sabine.

http://wiki.travellerrpg.com/Rhylanor_Subsector

AhmadF.Cheema (talkcontribs)

This website is unrelated to the Traveller Wiki, refer to that Wiki's support forum, Forum:Index.

Reply to "Incorrect weblinks - Rhylanor Subsector maps"

Arabic text when editing with Visual Editing

3
91.123.76.192 (talkcontribs)

When I try to edit my first page of my new Wikia, I do not see my previous edits for this page. Instead, I see this Arabic text:

بسم الله الرحمن الرحيم ((وَقُلِ اعْمَلُوا فَسَيَرَى اللَّهُ عَمَلَكُمْ وَرَسُولُهُ وَالْمُؤْمِنُونَ وَسَتُرَدُّونَ إِلَى عَالِمِ الْغَيْبِ وَالشَّهَادَةِ فَيُنَبِّئُكُمْ بِمَا كُنْتُمْ تَعْمَلُونَ)).

قال النبي محمد عليه الصلاة والسلام: ( إِذَا مَاتَ ابْنُ آدَمَ انْقَطَعَ عَمَلُهُ إِلا مِنْ ثَلاثٍ صَدَقَةٍ جَارِيَةٍ أَوْ عِلْمٍ يُنْتَفَعُ بِهِ ، أَوْ وَلَدٍ صَالِحٍ يَدْعُو لَهُ ).

الحمد لله وكفى والصلاة والسلام على النبي محمد المصطفى أما بعد:

فمن الأقوال التي أجدها صحيحة قول بديع الزمان سعيد النورسي: (ان الدين هو ضياء القلوب أما العلوم الحديثة فهي نور العقول)، ولهذا كلما حاولت أن تكتب شيئا أو تضيف معلومة في علوم الدين أو علوم الدنيا فقد ساهمت في إثراء المعرفة الإنسانية. لقد كان الكثير من علماء العرب والعجم مؤمنين بوجود الله الخالق معترفين بجهلهم وعجزهم عن إدراكه وتصوره، فالعالم إسحق نيوتن كان مؤمنًا بوجود الله، وقال العلامة الفيزيائي ألبرت أينشتاين : (لا أستطيع أن أتصوَّر عالِمًا حقيقيًا دون إيمان عميق، ويمكن التعبير عن هذا الوضع من خلال الصورة الآتية: العلم بلا دين علم أعرج)، ولقد قال العالم الفيزيائي الألماني ماكس بلانك أحد مؤسسي الفيزياء الحديثة: ( أنه ينبغي على كل من يدرس العلم بجدية أن يقرأ العبارة الآتية المكتوبة على باب معبد العلم: تَحَلَّ بالإيمان في الله، فالإيمان من الصفات الأساسية المميزة للعالِم)، ولا أتصور عالما بلا إعتراف بعظمة الله وقدرته فبدونها يكون فاقدا لجمال عظمة الخالق. وتذكر أخي إن كل شيء ستكتبه ستحاسب عليه يوم الحساب، وكما قال الشاعر:

وما من كاتب إلا سيفـنـى ويبقي الدهر ما كتبت يداه

فلا تكتب بخطك غير شيء يسرك في القيامة أن تراه

91.123.76.192 (talkcontribs)

Please, help me remove this problem.

AhmadF.Cheema (talkcontribs)

This support forum is unrelated to Wikia. For queries related to Wikia, ask at Wikia's support forum, Community Central.

Reply to "Arabic text when editing with Visual Editing"

Creatign an account without email authentication

2
Kairo5590 (talkcontribs)

Hello,

I want to create an account without confirming the email by using @domain as address.

I'm using MW 1.26.

Thank you.

MacFan4000 (talkcontribs)

MediaWiki 1.26 is unsupported. We reccomend upgrading.

Reply to "Creatign an account without email authentication"

What approach to use for Active Directory login?

8
PSIDWiki (talkcontribs)

I have been going around in circles with trying to get this to work. I had installed 1.29.1 then I read that active directory works better with 1.26.3. Extension:LDAP Authentication

So I removed 1.29.1 and downloaded and setup 1.26.3. So I go to setup the ldap options and I see that I have to use AuthPlugin so I go to this site AuthPlugin where it says it is deprecated and for backwards compatibility up to version 1.27 and to use Manual:SessionManager and AuthManager.

What is the recommended approach to use where I can have users login with their active directory credentials and I can add them to a group to just be able to edit?

Thank you

MarkAHershberger (talkcontribs)

You're right that the situation is confusing right now.

The version for 1.29.x may work depending on your needs or not. Try it and then ask for help here if you run into problems.

If it fails and you need this immediately, go with 1.26.x and Extension:LDAP Authentication since that will most likely work.

Finally, we are working on a replacement for the LDAP authentication. You can follow our progress: LDAP hub.

PSIDWiki (talkcontribs)

Hi Mark,

Thank you for the reply. I'm trying to use 1.26.x since I have to have it completed by today.

I'm running this on

MediaWiki 1.26.3

IIS 8.5

php 7.0 (I think this needs to change since I'm using 1.26.3)

mySQL 5.5.57

Windows Server 2012 R2

Here is what I have in LocalSettings.php for connecting to Active Directory:

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

$wgAuth = new LdapAuthenticationPlugin();

$wgLDAPDomainNames = array( "TMP" );

$wgLDAPServerNames = array( "TMP" => "tmp01.ab.cde.fghi.edu" );

$wgLDAPSearchStrings = array( "TMP" => "TMP\\USER-NAME" );

$wgLDAPEncryptionType = array( "TMP" => "tls" );

$wgLDAPUseLocal = false;

$wgMinimalPasswordLength = 1;

$wgLDAPBaseDNs = array( "TMP" => "dc=tmp01,dc=ab,dc=cde,dc=fghi,dc=edu" );

$wgLDAPSearchAttributes = array( "TMP" => "sAMAccountName" );

$wgLDAPRetrievePrefs = array( "TMP" => "true" );

$wgLDAPPreferences = array('TMP' => array( 'email' => 'mail','realname' => 'displayname'));

$wgLDAPDebug = 3; //for debugging LDAP

$wgShowExceptionDetails = true; //for debugging MediaWiki

$wgDebugLogFile = "C:\inetpub\wwwroot\NewWiki\w\debug.log" ;

$wgDebugLogGroups["ldap"] = "C:\inetpub\wwwroot\NewWiki\w\debugldap.log" ;

$wgLDAPProxyAgent = array(

'TMP' => 'cn=TMP\userLDAP,dc=tmp01,dc=ab,dc=cde,dc=fghi,dc=edu',

);

$wgLDAPProxyAgentPassword = array(

'TMP' => 'tmpLDAPpassword',

);

I know that the ldap server has a certificate and it is not self signed but from a third party. Do I still need to use openssl and create a cert file? If so where do I put this file in a windows server 2012 computer? Should I use SSL?

All I want to do is have my users use their current login information to log into my MediaWiki setup and just allow them to edit. I need to give myself and another user top level control. Anyone else who uses the site will just be a user and just viewing the wiki.

Thank you again for your help. I look forward to hearing from you.l

MarkAHershberger (talkcontribs)

I've used SSL without a client certificate. Unless you are told you need one, you shouldn't have to create one. Yes, you should use SSL.

This comment was hidden by Jörgi123 (history)
207.242.44.6 (talkcontribs)

Curious where you got the 1.26.3 version. I too have a need today to incorporate AD auth for our MediaWiki to allow users to view and edit on the platform. I am running MediaWiki 1.29.1 and tried with LdapAuthentication release 1.29 and 1.30. Lowest version I could find on the site was 1.27. You also mentioned AuthManager, is that needed too?

If you could, let me know what all extensions you are using to get the AD stuff to work. It would be greatly appreciated.

MarkAHershberger (talkcontribs)

Here you go.

207.242.44.6 (talkcontribs)

Ok, I thought you were using the 1.26 plugin version for the LdapAuthentication. In order to get that to work you need to downgrade the version of MediaWiki. Got it and thank you!!

Reply to "What approach to use for Active Directory login?"
Waanders (talkcontribs)

One of our templates seems corrupted. We can't edit the page, even not show (yes, it exists) and so on. All this results in a time-out. Now we try to import a back-up version but also Special:Import gives a time-out.

How do I fix this?

Malyacko (talkcontribs)

If your webserver software (not MediaWiki) shows a timeout, please check the logs of your webserver software for more information about the reasons. Also see How to debug.

Waanders (talkcontribs)

I think it's a MediaWiki problem.

I'v added this to LocalSettings.php:

error_reporting( -1 );

ini_set( 'display_errors', 1 );

$wgShowExceptionDetails = true;

$wgShowSQLErrors = true;

$wgShowDBErrorBacktrace = true;

$wgDebugComments = true;

$wgLogQueries = true;

$wgDebugDumpSql = true;

$wgDevelopmentWarnings  = true;

$wgDebugProfiling = true;

$wgDebugTimestamps = true;

$wgResourceLoaderDebug  = true;

Now MW gives this error: "Fatal error: Maximum execution time of 30 seconds exceeded in /home/hz01/mediawiki/core/includes/debug/MWDebug.php on line 369".

Reply to "How to fix a corrupted page?"

How can i import Wiki dump (*.xml) and related images and templates into my local Wiki

2
Kuninminh (talkcontribs)

I am building an local Wiki for automation test, and i have imported an dump file (*.xml) from dumps.wikimedia.org:

php importDumpphp < dumpfile.xml

php rebuildall.php

After that i can see many pages imported, but the related images and templates don't display as normal online Wiki page.

Anyone please help to overcome this stuck???

Many thanks!

Ciencia Al Poder (talkcontribs)

Dumps don't contain images. You'll need to download them manually. The easiest solution would be to enable InstantCommons, so your wiki fetches images automatically from WikiMedia Commons as they're needed.

About templates, they are included in dumps (unless you have imported a dump that doesn't contain them).

Maybe what you need is to rebuild those pages using refreshLinks.php. This often happens when the page is imported before the template, as they appear in the XML dump. Manually editing and saving those templates/mages may fix that, but refreshLinks.php will take care of that automatically.

Reply to "How can i import Wiki dump (*.xml) and related images and templates into my local Wiki"
Fazzeh (talkcontribs)

Hi everyone,

I recently took over hosting and administrating a rather large mediawiki (1.27) installation and it's set up on new hardware and a freshly installed CentOS 7.3.11.

We are running an nginx / php-fpm setup with a MariaDB-Galera database (3 node multi-master-cluster).

Everything works as intended, but our users are complaining about getting logged out every now and then. I can't seem to conclude on how often it happens, but according to some users it happens multiple times during a 30minute timeframe.

Our nginx / php installation is:

nginx-mod-http-geoip-1.10.2-1.el7.x86_64

nginx-all-modules-1.10.2-1.el7.noarch

nginx-mod-stream-1.10.2-1.el7.x86_64

nginx-mod-mail-1.10.2-1.el7.x86_64

nginx-1.10.2-1.el7.x86_64

nginx-mod-http-perl-1.10.2-1.el7.x86_64

nginx-mod-http-xslt-filter-1.10.2-1.el7.x86_64

nginx-mod-http-image-filter-1.10.2-1.el7.x86_64

nginx-filesystem-1.10.2-1.el7.noarch

php70w-fpm-7.0.23-2.w7.x86_64

php70w-7.0.23-2.w7.x86_64

php70w-common-7.0.23-2.w7.x86_64

php70w-mysql-7.0.23-2.w7.x86_64

php70w-intl-7.0.23-2.w7.x86_64

php70w-pdo-7.0.23-2.w7.x86_64

php70w-mbstring-7.0.23-2.w7.x86_64

php70w-xml-7.0.23-2.w7.x86_64

php70w-cli-7.0.23-2.w7.x86_64

php70w-gd-7.0.23-2.w7.x86_64

I have set session.gc_maxlifetime = 28800 (8 hrs) but that doesn't seem to affect anything.

Our sessions dir is /var/lib/php/session, but MW doesn't create any session files in that folder.

I have run a mockup session creater to see if sessions are working, and they are, but MW doesn't use that folder for some reason.

I've been scratching my head about this and I can't figure out how MW handles sessions and why users keep getting logged out.

The MW installation itself is an rsync-copy of a previous installation that didn't have this issue so I'm guessing it's due to our configuration, but I can't figure out where we've done anything wrong.

Any help would be greatly appreciated!

MarkAHershberger (talkcontribs)

Make sure that MW is set up to store sessions on the local disk. Also see $wgMainCacheType where it says:

Note: Since MediaWiki 1.27, PHP sessions are stored in a cache, depending on the variable of this setting, unless overridden by $wgSessionCacheType. This may cause problems when CACHE_ACCEL is used. (task T147161)
Reply to "Session timeout?"

Where do I change the time a user can be inactive before having to login again?

2
Summary by MarkAHershberger
Tohbbe (talkcontribs)

Where do I change the time a user can be inactive before having to login again?

TheDJ (talkcontribs)

Please see Manual:$wgExtendedLoginCookieExpiration and Manual:$wgCookieExpiration