upgrade_v10.md 5.4 KB

Upgrade docker

php composer.phar update ./vendor/bin/typo3 referenceindex:update

errors

rm public/typo3conf/ext/ot_admin rm public/typo3conf/ext/ot_connect rm public/typo3conf/ext/ot_core rm public/typo3conf/ext/ot_stats rm public/typo3conf/ext/ot_templating rm public/typo3conf/ext/ot_optimizer ./vendor/bin/typo3 upgrade:run

error: ot_templating not loaded

ln -s /var/opentalent/git/ot_typo3/ot_core public/typo3conf/ext/ ln -s /var/opentalent/git/ot_typo3/ot_connect public/typo3conf/ext/ ln -s /var/opentalent/git/ot_typo3/ot_admin public/typo3conf/ext/ ln -s /var/opentalent/git/ot_typo3/ot_stats public/typo3conf/ext/ ln -s /var/opentalent/git/ot_typo3/ot_templating public/typo3conf/ext/ ln -s /var/opentalent/git/ot_typo3/ot_optimizer public/typo3conf/ext/ php composer.phar dumpautoload ./vendor/bin/typo3 upgrade:run

Uncaught TYPO3 Exception Cannot autowire service "Opentalent\OtAdmin\Controller\ScanController": argument "$otWebsiteRepository" of method "Opentalent\OtCore\Controller\ActionController::injectOtWebsiteRepository()" references class "Opentalent\OtCore\Website\OtWebsiteRepository" but no such service exists. thrown in file /var/www/typo3/vendor/symfony/dependency-injection/Compiler/DefinitionErrorExceptionPass.php in line 54

rm public/typo3conf/ext/ot_admin rm public/typo3conf/ext/ot_connect rm public/typo3conf/ext/ot_core rm public/typo3conf/ext/ot_stats rm public/typo3conf/ext/ot_templating rm public/typo3conf/ext/ot_optimizer php composer.phar dumpautoload ./vendor/bin/typo3 upgrade:run

An exception occurred while executing 'SELECT content FROM cache_hash WHERE (identifier = ?) AND (expires >= ?)' with params ["cb5eaa637b", 1633424030]: Table 'typo3.cache_hash' doesn't exist

disable all caches by adding these lines to AdditionalConfiguration.php:

foreach ($GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations'] as $cacheName => $cacheConfiguration) {
$GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations'][$cacheName]['backend'] = \TYPO3\CMS\Core\Cache\Backend\NullBackend::class;
}

./vendor/bin/typo3 upgrade:run

[ERROR] Error running Database Up-to-Date. Please ensure this prerequisite manually and try again.

./vendor/bin/typo3 upgrade:run extensionManagerTables ./vendor/bin/typo3 upgrade:run separateSysHistoryFromLog ./vendor/bin/typo3 upgrade:run rsaauthExtension >> no when asked ./vendor/bin/typo3 upgrade:run feeditExtension >> no when asked ./vendor/bin/typo3 upgrade:run taskcenterExtension >> no when asked ./vendor/bin/typo3 upgrade:run sysActionExtension >> no when asked ./vendor/bin/typo3 upgrade:run svgFilesSanitization >> no when asked ./vendor/bin/typo3 upgrade:run databaseRowsUpdateWizard

access to the BE

run remaining upgrade wizard (felogin) flush cache analyse db apply changes to fields languages: update all reset BE users preferences clear persistent tables: all >> useless, I guess...

./vendor/bin/typo3 referenceindex:update

long, prévoir 1h+ / voir à lui passer un param quiet ou silent

ln -s /var/opentalent/git/ot_typo3/ot_core public/typo3conf/ext/ ln -s /var/opentalent/git/ot_typo3/ot_connect public/typo3conf/ext/ ln -s /var/opentalent/git/ot_typo3/ot_admin public/typo3conf/ext/ ln -s /var/opentalent/git/ot_typo3/ot_stats public/typo3conf/ext/ ln -s /var/opentalent/git/ot_typo3/ot_templating public/typo3conf/ext/ ln -s /var/opentalent/git/ot_typo3/ot_optimizer public/typo3conf/ext/ php composer.phar dumpautoload

http://local.sub.opentalent.fr/typo3/install.php

I fix every deprecated call in my extensions BE is loading, ok

analyse db structure >> nothing new Environment Status > ok Directory Status >> permission denied, I let it asit is for the moment (docker...)

I re-enable the cache by deleting these lines in AdditionalConfiguration.php:

foreach ($GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations'] as $cacheName => $cacheConfiguration) {
$GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations'][$cacheName]['backend'] = \TYPO3\CMS\Core\Cache\Backend\NullBackend::class;
}

Backend is not working anymore, I access to the typo3 install page, and run a db analysis I create the new tables

BE is back to life Everything seems to be fine, except for the perfs. Make it work, then make it fast...

Upgrade sur preprod

cd /var/opentalent/git/ot_typo3 git pull git checkout typo10_migration cd /var/www/typo3 rm composer.json nano composer.json >> I copy paste the content of docker/typo3/composer.json php7.4 composer.phar self-update --2 php7.4 composer.phar update

(en root) chown exploitation:www-data public/typo3conf/AdditionalConfiguration.php

I add these lines to AdditionalConfiguration.php

foreach ($GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations'] as $cacheName => $cacheConfiguration) {
    $GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations'][$cacheName]['backend'] = \TYPO3\CMS\Core\Cache\Backend\NullBackend::class;
}

./vendor/bin/typo3 upgrade:run databaseRowsUpdateWizard touch public/typo3conf/ENABLE_INSTALL_TOOL

I access to https://preprod.opentalent.fr/typo3/install.php

db analysis -> alter fields

I remove the lines added to AdditionalConfiguration

db analysis -> add tables languages -> update all reset be users prefs

./vendor/bin/typo3 referenceindex:update

plan for 20min