Last modified: 2012-08-04 20:48:57 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 12936 - Configuration directive ($wgDBmwschema) under the PostgreSQL backend is only used while installing
Configuration directive ($wgDBmwschema) under the PostgreSQL backend is only ...
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
Database (Other open bugs)
1.11.x
All Linux
: Normal minor (vote)
: ---
Assigned To: John Doe
:
Depends on:
Blocks: postgres
  Show dependency treegraph
 
Reported: 2008-02-06 10:09 UTC by John Doe
Modified: 2012-08-04 20:48 UTC (History)
2 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments
Fix for postgresql schema issue (277 bytes, patch)
2008-02-06 16:02 UTC, John Doe
Details

Description John Doe 2008-02-06 10:09:33 UTC
The configuration directive in LocalSettings.php that controls a wiki's database schema name ($wgDBmwschema) only appears to have relevance when creating Mediawiki's tables under PostgreSQL.  As far as I can tell, the database abstraction relies on the fact that it somehow overwrites search_path during schema initialization to subsequently find the tables instead of actually using the configuration variable. 

This makes two things very difficult under MediaWiki and PostgreSQL:

1) Renaming the wiki's schema.  Logic would dictate that you could simply change LocalSettings.php:$wgDBmwschema and then ALTER SCHEMA mediawiki RENAME TO mediawiki_meaningful_description;, but this does not work.

2) Running multiple wiki's on the same database in different schemas.  When you install the first one it works just fine.  When you install the second one, both the first and second wiki installations are in fact accessing the same schema.
Comment 1 John Doe 2008-02-06 16:02:32 UTC
Created attachment 4625 [details]
Fix for postgresql schema issue

Should fix the schema problem in mediawiki under postgres.
Comment 2 Greg Sabino Mullane 2008-02-10 17:07:03 UTC
Please see the changes in r25929 and see if that does what you need.
Comment 3 Sven Klemm 2008-03-03 21:31:25 UTC
To achieve 1) you only need to run maintenance/update.php afterwards which will adjust search_path of the database user according to LocalSettings.php or adjust search_path of the database user manually with ALTER USER $wgDBuser SET search_path = $wgDBmwschema, $wgDBts2schema;
Comment 4 Greg Sabino Mullane 2008-03-19 13:33:21 UTC
You'll need separate users to achieve number 2, but I just applied a patch from Sven in r32174 that should make #1 work reliably (thanks Sven!)


Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links