I have tried to upgrade my MediaWiki 1.37.2 to 1.38.1:
- Copied the images folder in the new version
- Added my extra extensions in the extensions folder of the new version
- Copied de LocalSettings.php (but commented-out all extensions)
Running 'php maintenance/update.php' gives the error
"Fatal error: Uncaught FatalError: $wgBaseDirectory must not be modified in settings files! Use the MW_INSTALL_PATH environment variable to override the installation root directory. in /var/www/html/includes/Setup.php:237
Stack trace:
#0 /var/www/html/maintenance/doMaintenance.php(96): require_once()
#1 /var/www/html/maintenance/update.php(264): require_once('/var/www/html/m...')
#2 {main}
thrown in /var/www/html/includes/Setup.php on line 237"
Also, going to the site , gives the error:
"Fatal error: Uncaught FatalError: $wgBaseDirectory must not be modified in settings files! Use the MW_INSTALL_PATH environment variable to override the installation root directory. in /var/www/html/includes/Setup.php:237 Stack trace: #0 /var/www/html/includes/WebStart.php(93): require_once() #1 /var/www/html/index.php(44): require('/var/www/html/i...') #2 {main} thrown in /var/www/html/includes/Setup.php on line 237"
How can I solve this error?