Project

General

Profile

Support #11741

Updated by Marc Egger 7 months ago

Steps to upgrade Typo3 to 9.5.22 with QFQ and UZH CD taken for Forkred Project. 

 h2. Upgrade Typo3 v8 (to most recent version) 

 * Backup LocalConfiguration.php! 
 * download 8.7.32 
 <pre> 
 wget --content-disposition https://get.typo3.org/8.7.32 
 tar -xzf typo3_src-8.7.32.tar.gz 
 rm typo3_src-8.7.32.tar.gz 
 </pre> 

 * replace symlink typo3_src 
 <pre> 
 rm typo3_src 
 ln -s "/var/www/typo3_src-8.7.32/":/var/www/typo3_src-8.7.32/ typo3_src 
 </pre> 

 * open T3 backend > install > upgraade wizard 

 h2. Upgrade Typo3 v9 

 * Backup LocalConfiguration.php! 
 * update reference index: 
 ** “System” > “DB check” module and use the “Check and update global reference index” function. 
 *** https://docs.typo3.org/m/typo3/guide-installation/master/en-us/Upgrade/UpdateReferenceIndex/Index.html 
 * download 9.5.22 
 <pre> 
 wget --content-disposition https://get.typo3.org/9.5.22 
 tar -xzf typo3_src-9.5.22.tar.gz 
 rm typo3_src-9.5.22.tar.gz 
 </pre> 

 * replace symlink 
 <pre> 
 rm typo3_src 
 ln -s "/var/www/typo3_src-9.5.22":/var/www/typo3_src-9.5.22 typo3_src 
 </pre> 

 * upgrade wizzard 
 ** go install tool: install.php 
 ** upgrade > run upgrade wizard 
 ** execute all except the ones that install extensions 
 *** side note: executed but not sure if good: Merge be_groups access rights from pages_language_overlay to pages 
 *** side note: interesting: Introduce URL parts ("slugs") to all existing pages 
 **** TYPO3 includes native URL handling. Every page record has its own speaking URL path called "slug" which can be edited in TYPO3 Backend. However, it is necessary that all pages have a URL pre-filled. This is done by evaluating the page title / navigation title and all of its rootline. 
 * Database analyze tool 
 ** go to install tool: install.php 
 ** Analyze Database Structure > apply all changes 
 *** removed tables renamed to: zzz_tableName 
 *** removed fields renamed to: zzz_fieldName 
 *** completely dropped one field: DROP INDEX `sys_log_uid` ON `sys_history` (Not done on forkred-simon !) 
 * Optional (not done): Clear User Settings 
 ** https://docs.typo3.org/m/typo3/guide-installation/master/en-us/Upgrade/ClearCachesAndUserSettings/Index.html 
 * clear caches 
 ** Maintanance > Flush Cache 
 * look at change log (just for info) 
 ** Upgrade > View Upgrade Documentation 
 * delete the other temporary files, which TYPO3 saves in typo3temp/ by doing: 
 ** Install tool > Maintanance > Remove Temporary Assets 
 * upgrade ldap manually (current version breaks Typo3>Extension) 
 ** extract newest version of ig_ldap_sso_aut to ext 
 <pre> 
 wget --content-disposition https://extensions.typo3.org/extension/download/ig_ldap_sso_auth/3.6.0/zip/ 
 unzip ig_ldap_sso_auth_3.6.0.zip -d ig_ldap_sso_auth 
 rm ig_ldap_sso_auth_3.6.0.zip 
 chown -R www-data ig_ldap_sso_auth 
 </pre> 

 * upgrad extensions in typo3>Extensions: 
 ** qfq (FAF) 
 ** uzh cd 
 ** static_info_tables: kollektion von tabellen mit sprache und country data 
 ** rdct: deprecated url routing with hash index.php?RDCT=$hash 
 * make sure that the upgraded extensions are activated 
 * restore LDAP settings (check exactly these boxes): 
 ** Throw exception if configured incorrectly 
 ** Backend LDAP authentication 
 ** Backend user must exist 
 ** Enable local Backend users 
 ** Disable Backend group synchronization 
 ** Keep Backend groups 
 ** Frontend LDAP authentication 
 ** Disable Frontend group synchronization 
 ** Keep Frontend groups 
 * check if qfq settings are still there 
 ** if not: use var_export(unserialize('<qfq settings string>')) on the old qfq settings and replace the ones in LocalConfiguration.php 
 ** chown www-data LocalConfiguration.php 
 * Choose backend layout in Home>Edit>Appearance>Backend Layout > UZH CD - 4 column 
 * search and replace title object removal by doing: 
 ** (Explenation: the line "cd.content.title >" causes exception!) 
 ** Typo3 > DB check: search for: "cd.content.title >" 
 ** replace all occurrences in templates with: 
 <pre> 
 # Hide the content title 
 cd.content.title > 
 cd.content.title = TEXT 
 cd.content.title.value = 
 </pre> 

 * Typo3 routing 
 ** enable apache modules 
 *** Liste der modules: https://docs.typo3.org/m/typo3/guide-installation/master/en-us/In-depth/SystemRequirements/Index.html#apache 
 <pre> 
 a2enmod alias 
 a2enmod authz_core 
 a2enmod autoindex 
 a2enmod deflate 
 a2enmod expires 
 a2enmod filter 
 a2enmod headers 
 a2enmod rewrite 
 a2enmod setenvif 
 </pre> 

 ** edit apache config 
 <pre> 
 vi "/etc/apache2/apache2.conf":/etc/apache2/apache2.conf 
 </pre> 

 *** in apache config add directory and AllowOverride rule (adjust for your setup) 
 <pre> 
 <Directory "/var/www/html/forkred-simon/>":/var/www/html/forkred-simon/> 
   Options Indexes FollowSymLinks 
   AllowOverride Indexes FileInfo AuthConfig Options=MultiViews,Indexes 
   Require all granted 
 </Directory> 
 </pre> 

 ** .htaccess 
 *** copy from here to page root: https://github.com/TYPO3/TYPO3.CMS/blob/master/typo3/sysext/install/Resources/Private/FolderStructureTemplateFiles/root-htaccess 
 *** Add redirect for Extensions for english language before line "# Stop rewrite processing, [...]" 
 <pre> 
 # Marc: remove 'en' directory from url if path leads to extension directory and requested file does not exist, 
 # e.g.: en/typo3conf/ext/qfq/example.jpg ---> typo3conf/ext/qfq/example.jpg 
 # Explenation of used flags for RewritteRule: 
 # QSA: Appends any query string from the original request URL to any query string created in the rewrite target 
 # L: Stop the rewriting process immediately and don't apply any more rules. 
 # NC: Makes the pattern comparison case-insensitive. 
 # NE: Prevent mod_rewrite from applying hexcode escaping of special characters in the result of the rewrite. 
 # R=307: Forces an external redirect, with the specified HTTP status code: 307 (temporary redirect, keep http request method e.g. POST stays POST) 
 RewriteCond %{REQUEST_FILENAME} !-f 
 RewriteCond %{REQUEST_FILENAME} !-d 
 RewriteCond %{REQUEST_FILENAME} !-l 
 RewriteRule ^en/typo3conf/ext/(.*)$ %{ENV:CWD}typo3conf/ext/$1 [QSA,L,NC,NE,R=307] 
 </pre> 

 ** restart apache 
 *** service apache2 reload 
 *** service apache2 restart 
 * add site configuration: 
 ** Typo3 > Sites (left) > Add new site configuration for this site 
 *** entry point: " https://webwork16.math.uzh.ch/forkred-simon/" (adjust for your setup) 
 *** site identifier: forkred (adjust for your setup) 
 *** Languages 
 **** Deutsch 
 ***** Entry Point: '/' 
 ***** Language key: English 
 ***** Locale: de_DE 
 ***** Two leter ... : German 
 ***** Navigation Title: Deutsch 
 **** English 
 ***** Entry Point: '/en/' 
 ***** Language key: English 
 ***** Locale: en_US.UTF-8 
 ***** Two leter ... : English 
 ***** Navigation Title: English 
 ***** Fallback Type: Fallback ... 
 ***** Fallback to language: Default Language 
 *** Error Page for 403 forbidden (shown when login expired): 
 **** Error Handling > Create New 
 ***** HTTP Error status code: 403 
 ***** How to handle Errors: Show Content from Page 
 ***** Show Content from Page: t3://page?uid=1 
 ****** this is the home page with the login form 
 * Edit root page > fill in "/" as URL Segment 
 * remove typo3conf/ENABLE_INSTALL_TOOL 
 * flush all cashes 
 * Test if all is well 
 ** excel export testen 
 ** pdf generation testen 
 ** email testen 
 ** login english und deutsch 
 * delete backup files *<--- forkred/preview*

Back