{"id":141,"date":"2009-07-09T17:16:22","date_gmt":"2009-07-09T16:16:22","guid":{"rendered":"http:\/\/www.k-braungardt.de\/blogkb\/?p=141"},"modified":"2009-07-09T17:16:22","modified_gmt":"2009-07-09T16:16:22","slug":"upgrade-multiple-mediawikis-on-same-source-code","status":"publish","type":"post","link":"https:\/\/www.k-braungardt.de\/blogkb\/?p=141","title":{"rendered":"Upgrade multiple mediawikis on same source code"},"content":{"rendered":"<p>A bunch of wikis been set up following the recipe of <a href=\"http:\/\/www.steverumberg.com\/wiki\/index.php?title=WikiHelp_-_Method_Two\">Rumberg Method 2<\/a>. Then I had to upgrade from 1.6.XX to 1.15.0. This did not work out for me with the normal upgrade routine.<br \/>\nI figured out that i had to recreate symbolic links as well as a new LocalSettings.php.<\/p>\n<p>So i developed a shell script which led me through this until the point to where to run through Setup again.<br \/>\nI also set up a new source directory with Mediawiki 1.15.0.<\/p>\n<p><code>#!\/bin\/sh<br \/>\n# DBNAME, PATHTOWIKIDIRECTORY, NAMEOFDIRECTORYOFNEWSOURCE have to be your values<br \/>\n# in this case wiki directory is wiki<br \/>\n# in wiki directory there has to be a writeable directory called sich.<br \/>\ndb=DBNAME<br \/>\necho Tell me the directory name.<br \/>\nread verz<br \/>\npfad=PATHTOWIKIDIRECTORY<br \/>\nurw=NAMEOFDIRECTORYOFNEWSOURCE<br \/>\n#backuppath<br \/>\nneuerpfad=${pfad}wiki\/sich\/$verz<br \/>\nmkdir $neuerpfad<br \/>\n# copy images and config directory and LocalSettings.php to backup-path<br \/>\npfad1=${pfad}wiki\/$verz\/images\/<br \/>\npfad2=${pfad}wiki\/$verz\/config\/<br \/>\npfad3=${pfad}wiki\/$verz\/LocalSettings.php<br \/>\ncp -R $pfad1  $neuerpfad<br \/>\ncp -R $pfad2  $neuerpfad<br \/>\ncp -R $pfad3  $neuerpfad<br \/>\n#delete wikipath<br \/>\nrm -rf ${pfad}wiki\/$verz<br \/>\n#recreate wikipath<br \/>\nmkdir  ${pfad}wiki\/$verz<br \/>\n# copy images to wikipath<br \/>\ncp -R ${neuerpfad}\/images ${pfad}wiki\/$verz<br \/>\n# recreate config path<br \/>\nmkdir  ${pfad}wiki\/$verz\/config<br \/>\n# set up rights<br \/>\nchmod -R 755 ${pfad}wiki\/$verz\/<br \/>\nchmod -R 777 ${pfad}wiki\/$verz\/images<br \/>\nchmod -R 777 ${pfad}wiki\/$verz\/config<br \/>\n# create symbolic links. this follows rumberg method 2.<br \/>\ncd ${pfad}wiki\/$verz<br \/>\nln -s  ${pfad}wiki\/$urw\/* .<br \/>\nrm ${pfad}wiki\/$verz\/LocalSettings.php<br \/>\ncd ${pfad}wiki\/$verz\/config<br \/>\nln -s  ${pfad}wiki\/$urw\/config\/index.php .<br \/>\n# now going through setup. afterwards LocalSettings.php can be changed.<br \/>\necho Now go through Setup. Ready?  If yes type in y.<br \/>\nread antwort<br \/>\nif [ \"$antwort\" == \"y\" ]<br \/>\n then<br \/>\n# copy LocalSettings.php in main directory and set up rights.<br \/>\ncp ${pfad}wiki\/$verz\/config\/LocalSettings.php ${pfad}wiki\/$verz<br \/>\nrm ${pfad}wiki\/$verz\/config\/LocalSettings.php<br \/>\nchown -R rubcast:rubcast ${pfad}wiki\/$verz<br \/>\nchmod -R 755 ${pfad}wiki\/$verz\/config<br \/>\nfi<br \/>\necho Ready.<\/code><\/p>\n<p>This worked out for me fine. One problem was at the beginning that german &#8222;Umlaute&#8220; were not displayed correctly. I had to write into LocalSettings.php:<\/p>\n<p><code>$wgDBmysql5 = false;<br \/>\n$wgDBmysql4 = true;<\/code><\/p>\n","protected":false},"excerpt":{"rendered":"<p>A bunch of wikis been set up following the recipe of Rumberg Method 2. Then I had to upgrade from 1.6.XX to 1.15.0. This did&#8230;<\/p>\n<div class=\"more-link-wrapper\"><a class=\"more-link\" href=\"https:\/\/www.k-braungardt.de\/blogkb\/?p=141\">Weiterlesen<span class=\"screen-reader-text\">Upgrade multiple mediawikis on same source code<\/span><\/a><\/div>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[54],"tags":[79,80],"class_list":["post-141","post","type-post","status-publish","format-standard","hentry","category-technik","tag-mediawiki","tag-upgrade","entry"],"_links":{"self":[{"href":"https:\/\/www.k-braungardt.de\/blogkb\/index.php?rest_route=\/wp\/v2\/posts\/141","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.k-braungardt.de\/blogkb\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.k-braungardt.de\/blogkb\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.k-braungardt.de\/blogkb\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.k-braungardt.de\/blogkb\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=141"}],"version-history":[{"count":5,"href":"https:\/\/www.k-braungardt.de\/blogkb\/index.php?rest_route=\/wp\/v2\/posts\/141\/revisions"}],"predecessor-version":[{"id":153,"href":"https:\/\/www.k-braungardt.de\/blogkb\/index.php?rest_route=\/wp\/v2\/posts\/141\/revisions\/153"}],"wp:attachment":[{"href":"https:\/\/www.k-braungardt.de\/blogkb\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=141"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.k-braungardt.de\/blogkb\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=141"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.k-braungardt.de\/blogkb\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=141"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}