Title here
Summary here
One should be careful renaming a wiki (database/domain) as it involves many steps and basically anything going wrong can make it impossible for users to login across the entire farm, or worse. Please pay attention to what the scripts output when doing a rename to make sure everything is working properly.
mwscript extensions/MirahezeMagic/renameDatabase.php loginwiki --old=<old_wiki_db> --new=<new_wiki_db>
mwscript extensions/CreateWiki/renameWiki.php loginwiki --no-log --rename <old_wiki_db> <new_wiki_db> <user_running_script>
sudo -i mysql -e "DROP DATABASE nameofwikidb;"
Double check Swift:
. /etc/swift-env.sh
swift list --prefix miraheze-<old_wiki_db>
If anything shows in the above, for each of them:diff --color <(swift list miraheze-<new_wiki_db>-<zone>) <(swift list miraheze-<old_wiki_db>-<zone>)
local-public
If only empty directories or everything looks fine there (files returned by that are now only present on old container, not on the new wiki container), you can remove the old containers with:swift delete miraheze-<old_wiki_db>-<zone>
sudo -u www-data rm -rf /tmp/miraheze-<old_wiki_db>-<zone>
Finally, run:
mwscript extensions/CreateWiki/setContainersAccess.php <new_wiki_db>