Leitfaden Update der Wiki-Software: Unterschied zwischen den Versionen

Peter (Diskussion | Beiträge)
KKeine Bearbeitungszusammenfassung
Peter (Diskussion | Beiträge)
 
(3 dazwischenliegende Versionen desselben Benutzers werden nicht angezeigt)
Zeile 237: Zeile 237:
   ALTER TABLE `test_sg2_trackbacks` CHANGE `tb_id` `tb_id` INT( 11 ) NOT NULL AUTO_INCREMENT;
   ALTER TABLE `test_sg2_trackbacks` CHANGE `tb_id` `tb_id` INT( 11 ) NOT NULL AUTO_INCREMENT;
   ALTER TABLE `test_sg2_user` CHANGE `user_id` `user_id` INT( 5 ) UNSIGNED NOT NULL AUTO_INCREMENT;
   ALTER TABLE `test_sg2_user` CHANGE `user_id` `user_id` INT( 5 ) UNSIGNED NOT NULL AUTO_INCREMENT;
  ALTER TABLE `test_sg2_logging` CHANGE `log_id` `log_id` INT( 10 ) UNSIGNED NOT NULL AUTO_INCREMENT;
==== ALTERNATIVE 1.3.3.X Aktualisieren der Test-Datenbank bei bestehendem Datenbank-Schema ====
Existiert bereits das Datenbank-Schema "test_sg2_*", kann mit folgendem Skript die Test-Datenbank aktualisiert und auf den aktuellen Stand der Produktivdatenbank gebracht werden:
  truncate table test_sg2_archive;
  truncate table test_sg2_categorylinks;
  truncate table test_sg2_externallinks;
  truncate table test_sg2_filearchive;
  truncate table test_sg2_hitcounter;
  truncate table test_sg2_image;
  truncate table test_sg2_imagelinks;
  truncate table test_sg2_interwiki;
  truncate table test_sg2_ipblocks;
  truncate table test_sg2_ipblocks_old;
  truncate table test_sg2_job;
  truncate table test_sg2_langlinks;
  truncate table test_sg2_logging;
  truncate table test_sg2_math;
  truncate table test_sg2_objectcache;
  truncate table test_sg2_oldimage;
  truncate table test_sg2_page;
  truncate table test_sg2_pagelinks;
  truncate table test_sg2_page_restrictions;
  truncate table test_sg2_querycache;
  truncate table test_sg2_querycachetwo;
  truncate table test_sg2_querycache_info;
  truncate table test_sg2_recentchanges;
  truncate table test_sg2_redirect;
  truncate table test_sg2_revision;
  truncate table test_sg2_searchindex;
  truncate table test_sg2_site_stats;
  truncate table test_sg2_templatelinks;
  truncate table test_sg2_text;
  truncate table test_sg2_trackbacks;
  truncate table test_sg2_transcache;
  truncate table test_sg2_user;
  truncate table test_sg2_user_groups;
  truncate table test_sg2_user_newtalk;
  truncate table test_sg2_validate;
  truncate table test_sg2_watchlist;
  insert into test_sg2_archive select * from sg2_archive;
  insert into test_sg2_categorylinks select * from sg2_categorylinks;
  insert into test_sg2_externallinks select * from sg2_externallinks;
  insert into test_sg2_filearchive select * from sg2_filearchive;
  insert into test_sg2_hitcounter select * from sg2_hitcounter;
  insert into test_sg2_image select * from sg2_image;
  insert into test_sg2_imagelinks select * from sg2_imagelinks;
  insert into test_sg2_interwiki select * from sg2_interwiki;
  insert into test_sg2_ipblocks select * from sg2_ipblocks;
  insert into test_sg2_ipblocks_old select * from sg2_ipblocks_old;
  insert into test_sg2_job select * from sg2_job;
  insert into test_sg2_langlinks select * from sg2_langlinks;
  insert into test_sg2_logging select * from sg2_logging;
  insert into test_sg2_math select * from sg2_math;
  insert into test_sg2_objectcache select * from sg2_objectcache;
  insert into test_sg2_oldimage select * from sg2_oldimage;
  insert into test_sg2_page select * from sg2_page;
  insert into test_sg2_pagelinks select * from sg2_pagelinks;
  insert into test_sg2_page_restrictions select * from sg2_page_restrictions;
  insert into test_sg2_querycache select * from sg2_querycache;
  insert into test_sg2_querycachetwo select * from sg2_querycachetwo;
  insert into test_sg2_querycache_info select * from sg2_querycache_info;
  insert into test_sg2_recentchanges select * from sg2_recentchanges;
  insert into test_sg2_redirect select * from sg2_redirect;
  insert into test_sg2_revision select * from sg2_revision;
  insert into test_sg2_searchindex select * from sg2_searchindex;
  insert into test_sg2_site_stats select * from sg2_site_stats;
  insert into test_sg2_templatelinks select * from sg2_templatelinks;
  insert into test_sg2_text select * from sg2_text;
  insert into test_sg2_trackbacks select * from sg2_trackbacks;
  insert into test_sg2_transcache select * from sg2_transcache;
  insert into test_sg2_user select * from sg2_user;
  insert into test_sg2_user_groups select * from sg2_user_groups;
  insert into test_sg2_user_newtalk select * from sg2_user_newtalk;
  insert into test_sg2_validate select * from sg2_validate;
  insert into test_sg2_watchlist select * from sg2_watchlist;


==== 1.3.3.4. Test der Testinstallation ====
==== 1.3.3.4. Test der Testinstallation ====
Zeile 308: Zeile 386:


Es gab in der Vergangenheit Probleme mit dem Seitentemplate, dem CSS und JavaScript, wo einige Erweitungen nicht standardkonform eingebaut werden konnten (Siehe auch EMails mit Erik, Stichwort "wikibits.js"
Es gab in der Vergangenheit Probleme mit dem Seitentemplate, dem CSS und JavaScript, wo einige Erweitungen nicht standardkonform eingebaut werden konnten (Siehe auch EMails mit Erik, Stichwort "wikibits.js"
==3.1. Anzeige Bearbeiter in Footer ==
Betroffene Dateien:
  includes/Article.php
  includes/Skin.php
Details siehe [[SkipperGuide:Interne_Dokumentation/Seitenfooter]]
==3.2. Stats==
Betroffene Dateien:
  index.php
Details siehe [[SkipperGuide:Interne_Dokumentation]]
==3.3. Externe Links in neuem Fenster==
Betroffene Dateien
  includes/Linker.php
Details siehe [[SkipperGuide:Interne_Dokumentation/Externe_Links_im_neuen_Fenster]]
=4. Übernahme aus dem Testsystem ins Produktivsystem=
Nach ausführlichen Tests muss die Installation auf dem Produktivsystem durchgeführt werden. Hierzu wird das tmp.tar ins Produktivverzeichnis übernommen, der normale Update-Vorgang gestartet und abschließend die Dateien aus dem Testsystem ins Produktivsystem kopiert
Vorbereitung: nochmal den Schritt [[#1.2. Sicherung des aktuellen Version als Referenz]] durchführen, um den aktuellsten Stand zu sichern! (z.B. wegen dem image-Verzeichnissen)
==4.1. Einspielen der aktualisierten Programmversion==
Übernehmen des tmp.tars ins Produktivsystem. Grund: die Update-Skripte für die Datenbank müssen auf dem Produktivsystem ausgeführt werden! Es kann nicht ausgeschlossen werden, dass die Update-Skripte auch Dateien verändern, so dass ein sauberer Pre-Update-Stand geschaffen werden muss.
  1. SSH> cd www_skipperguide_de/mediawiki
  2. SSH> cp ../../test_skipperguide_de/mediawiki/tmp.tar .
  3. SSH> tar xvf tmp.tar
==4.2. Update-Skripte==
Vorher: korrekte Config in '''AdminSettings.php''' prüfen (Datenbank-Präfix muss "sg2_" sein!
Weiteres Vorgehen: siehe [[#2.3. Updateskripte durchführen]]
==4.3. Update der Programmdateien ==
Kopieren des Dateisystems aus dem Testsystem ins Produktivverzeichnis:
  SSH> cp -R test_skipperguide_de/mediawiki/* www_skipperguide_de/mediawiki
Aktualisieren von
  AdminSettings.php
  LocalSettings.php
  LocalDBSettings.php
--> Datenbank-Präfix von "test_sg2_" nach "sg2_" ändern
==4.4. Kontrolle des Produktivsystems==
Ausführliche Kontrolle des Produktivsystems und aller Plugins!