#2583 MediaWiki: locking fails when uploading a file


I installed MediaWiki in my project's web space as per the hosted-apps migration guide. I am able to view and edit wiki pages. However, file uploads fail with the following message:

Could not acquire lock for "mwstore://local-backend/local-public/5/56".
Could not acquire lock for "mwstore://local-backend/local-public/5/56/Setup_sve_project_new_project.gif".

Any suggestions on how to resolve this? Thus far, Google hasn't been very helpful...

Thanks and Regards,


Site Support: #2758
Site Support: #2816


  • Anonymous - 2013-01-31
    • status: unread --> pending
    • assigned_to: Chris Tsai
  • Matthew Ballance

    Thanks for the suggestion. I did try the updated permissions (755 => 777), but still receive the 'Could not acquire lock' message.

    I did note that the post above describes a 'Could not open lock' message, while I am receiving a 'Could not acquire lock' message. Is there anything unique about how the SF filesystem implements file locking?

  • Håkon Skjelten

    Håkon Skjelten - 2013-02-11

    I got exactly the same problem, but did not find this ticket before after I filed a new ticket. Look at #2758 for some more info.

  • Anonymous - 2013-02-12

    Yeah, I'm escalating this ticket to our operations team to investigate this issue further.

    As Håkon Skjelten mentions, [#2758] has further detail that may be useful.

    Chris Tsai, SourceForge.net Support



    Site Support: #2758

  • Anonymous - 2013-02-12
    • labels: --> siteops, p3
    • status: pending --> assigned
    • assigned_to: Chris Tsai --> Wayne Davison
  • Håkon Skjelten

    Håkon Skjelten - 2013-03-19

    This is getting ridiculous. Mediawiki on sourceforge is absolutely useless (both speed wise and with the file locking issue) and this support request is taking forever. How long does it normally take from a task is assigned to someone until we get some feedback on progress?

    I would be happy to invest some time on this issue if there where some feedback to work on.

  • Doriano Cometto

    Doriano Cometto - 2013-03-27

    I'm experiencing exactly the same problem with a new installation of mediawiki-1.20.3
    This issue is much better exposed in [#2758].


    I found a crude solution here

    The trick has been finding a way to force a nullLockManager, and my uploads on SF using mediawiki work now.

    In the mediawiki source code I changed line 97 in

                         'lockManager'    => 'fsLockManager',


                         'lockManager'    => 'nullLockManager',


    Site Support: #2758

    Last edit: Doriano Cometto 2013-03-28
  • Kissaki

    Kissaki - 2014-03-22

    Same issue here after upgrading to mediawiki 1.19.
    The FileBackendGroup.php nullLockManager hack from Doriano works.
    It should be possible to set this in the LocalSettings rather than hacking it that way.
    See https://www.mediawiki.org/wiki/Manual:$wgFileBackends

    // $wgFileBackends[]['lockManager'] = 'nullLockManager';

    Although I am not sure what the first level index has to be (0?).

    Last edit: Kissaki 2014-03-22
  • Kai Sterker

    Kai Sterker - 2014-05-03

    Same issue here. Also no idea how to configure the lockmanager in LocalSettings, but exchanging it in the code directly appears to work well enough.


Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.

No, thanks