
I've been working on updating Drupal from 10.4.2 to 11.1.0, as recommended. We were all told this process should be a walk in the park—spoiler alert: it isn’t.
Drupal was once a great platform, but lately, it seems plagued by option paralysis and growing complexity. After my third attempt at updating, I’m still running into random, frustrating issues. Judging by the complaints on Drupal.org, I’m clearly not the only one pulling my hair out.
Honestly, after this experience, I doubt I’ll use Drupal again. Laravel, here I come.
If you’re also struggling with the upgrade, here’s what it really takes to get from Drupal 10.4.2 to 11.1.0 successfully.
What I’ve Done So Far
- Updated all modules.
- Removed anything not supported by Upgrade Status.
- Upgrade Status reports I’m 100% ready.
Nope!
`composer update "drupal/core:11.1.0" --dry-run` to get another view on the problem.
[townscanada@rockstar www]$ composer update "drupal/core:11.1.0" --dry-run
Loading composer repositories with package information
Updating dependencies
Your requirements could not be resolved to an installable set of packages.
Problem 1
- drupal/composer_deploy is locked to version 1.10.0 and an update of this package was not requested.
- drupal/composer_deploy 1.10.0 requires drupal/core ^9 || ^10 || ^11 -> satisfiable by drupal/core[11.1.0].
- drupal/core 11.1.0 requires symfony/console ^7.2 -> found symfony/console[v7.2.0-BETA1, ..., 7.3.x-dev] but it conflicts with your root composer.json require (^6.4).
Use the option --with-all-dependencies (-W) to allow upgrades, downgrades and removals for packages currently locked to specific versions.
[townscanada@rockstar www]$ composer update "drupal/core:11.1.0" -W --dry-run
Loading composer repositories with package information
Updating dependencies
Your requirements could not be resolved to an installable set of packages.
Yep, errors... SURPRISE!! So, what are the offending packages?
composer prohibits drupal/core 11.1.0
drupal/core 11.1.0 requires symfony/console (^7.2)
drupal/legacy-project - requires symfony/console (^6.4)
drupal/core 11.1.0 requires symfony/dependency-injection (^7.2)
drupal/legacy-project - does not require symfony/dependency-injection (but v6.4.16 is installed)
drupal/core 11.1.0 requires symfony/event-dispatcher (^7.2)
drupal/legacy-project - does not require symfony/event-dispatcher (but v6.4.13 is installed)
drupal/core 11.1.0 requires symfony/filesystem (^7.2)
drupal/legacy-project - does not require symfony/filesystem (but v6.4.13 is installed)
drupal/core 11.1.0 requires symfony/finder (^7.2)
drupal/legacy-project - does not require symfony/finder (but v6.4.17 is installed)
drupal/core 11.1.0 requires symfony/http-foundation (^7.2)
drupal/legacy-project - does not require symfony/http-foundation (but v6.4.18 is installed)
drupal/core 11.1.0 requires symfony/http-kernel (^7.2)
drupal/legacy-project - does not require symfony/http-kernel (but v6.4.18 is installed)
drupal/core 11.1.0 requires symfony/mailer (^7.2)
drupal/legacy-project - does not require symfony/mailer (but v6.4.18 is installed)
drupal/core 11.1.0 requires symfony/mime (^7.2)
drupal/legacy-project - does not require symfony/mime (but v6.4.18 is installed)
drupal/core 11.1.0 requires symfony/routing (^7.2)
drupal/legacy-project - does not require symfony/routing (but v6.4.18 is installed)
drupal/core 11.1.0 requires symfony/serializer (^7.2)
drupal/legacy-project - does not require symfony/serializer (but v6.4.18 is installed)
drupal/core 11.1.0 requires symfony/validator (^7.2)
drupal/legacy-project - does not require symfony/validator (but v6.4.18 is installed)
drupal/core 11.1.0 requires symfony/process (^7.2)
drupal/legacy-project - does not require symfony/process (but v6.4.15 is installed)
drupal/core 11.1.0 requires symfony/yaml (^7.2)
drupal/legacy-project - does not require symfony/yaml (but v6.4.18 is installed)
drupal/core 11.1.0 requires doctrine/annotations (^2.0)
drupal/legacy-project - does not require doctrine/annotations (but 1.14.4 is installed)
drupal/core 11.1.0 requires symfony/psr-http-message-bridge (^7.2)
drupal/legacy-project - does not require symfony/psr-http-message-bridge (but v6.4.13 is installed)
Not finding what you were looking for? Try calling `composer update "drupal/core:11.1.0" --dry-run` to get another view on the problem.
[site@rockstar www]$ composer update "drupal/core:11.1.0" --dry-run
Loading composer repositories with package information
Updating dependencies
Your requirements could not be resolved to an installable set of packages.
As a side note. This is the third time attempting an update. About 5 hours of Googling, a chat with AI (which was completely useless, AI honestly sucks at anything to do with coding.), and every time the errors are different.
So now I am editing the composer.json file to work correctly. If you are going to use this remember to edit it for your needs. Add or remove items that you are using.
{
"name": "drupal/legacy-project",
"description": "Project template for Drupal 8 projects with composer following drupal/drupal layout",
"type": "project",
"license": "GPL-2.0-or-later",
"homepage": "https://www.drupal.org/project/drupal",
"support": {
"docs": "https://www.drupal.org/docs/user_guide/en/index.html",
"chat": "https://www.drupal.org/node/314178"
},
"repositories": [
{
"type": "composer",
"url": "https://packages.drupal.org/8"
},
{
"type": "package",
"package": {
"name": "desandro/masonry",
"version": "3.3.1",
"type": "drupal-library",
"dist": {
"url": "https://github.com/desandro/masonry/archive/v3.3.1.zip",
"type": "zip"
}
}
},
{
"type": "package",
"package": {
"name": "desandro/imagesloaded",
"version": "3.1.8",
"type": "drupal-library",
"dist": {
"url": "https://github.com/desandro/imagesloaded/archive/v3.1.8.zip",
"type": "zip"
}
}
},
{
"type": "package",
"package": {
"name": "enyo/dropzone",
"version": "4.2.0",
"type": "drupal-library",
"source": {
"url": "https://github.com/enyo/dropzone",
"type": "git",
"reference": "origin/master"
}
}
}
],
"require": {
"commerceguys/addressing": "^2",
"composer/installers": "^1.2",
"defuse/php-encryption": "^2.4",
"desandro/imagesloaded": "^3.1",
"desandro/masonry": "^3.3",
"drupal/address_map_link": "^2.0@alpha",
"drupal/admin_toolbar": "^3.3",
"drupal/advancedqueue": "^1.0",
"drupal/advban": "^1.6",
"drupal/autoban": "^1.10",
"drupal/backup_migrate": "^5.0",
"drupal/better_exposed_filters": "^7.0",
"drupal/block_visibility_groups": "^2.0",
"drupal/bootstrap_sass": "^5.0",
"drupal/chosen": "^4.0",
"drupal/commerce": "^3.0",
"drupal/commerce_license": "^3.0",
"drupal/commerce_paypal": "^1.8",
"drupal/core-composer-scaffold": "10.3.10",
"drupal/core-project-message": "10.3.10",
"drupal/ctools": "^4.0",
"drupal/default_content": "^2.0@alpha",
"drupal/devel": "^5.3",
"drupal/dropzonejs": "^2.11",
"drupal/ds": "^3.28",
"drupal/entity": "^1.5",
"drupal/entity_browser": "^2.11",
"drupal/entity_embed": "^1.6",
"drupal/entity_reference_revisions": "^1.10",
"drupal/entity_usage": "^2.0@beta",
"drupal/eu_cookie_compliance": "^1.24",
"drupal/facets": "^2.0",
"drupal/field_formatter": "^3.0",
"drupal/field_group": "^3.4",
"drupal/flag": "^4.0@beta",
"drupal/flag_rating": "^2.0@dev",
"drupal/fullcalendar_library": "^3.0",
"drupal/geocoder": "^4.25",
"drupal/geofield": "^1.55",
"drupal/geolocation": "^3.12",
"drupal/token": "^1.13",
"drupal/upgrade_status": "^4.3",
"drupal/views_bulk_operations": "^4.2",
"drupal/views_infinite_scroll": "^2.0",
"drupal/webform": "^6.3@beta",
"drupal/xmlsitemap": "^2.0@beta",
"drush/drush": "^13.3",
"enyo/dropzone": "^4.2",
"geocoder-php/google-maps-provider": "^4.7",
"geocoder-php/mapbox-provider": "^1.4",
"geocoder-php/nominatim-provider": "^5.7",
"longwave/laminas-diactoros": "^2.14",
"symfony/console": "^7.2",
"symfony/dependency-injection": "^7.2",
"symfony/event-dispatcher": "^7.2",
"symfony/filesystem": "^7.2",
"symfony/finder": "^7.2",
"symfony/http-foundation": "^7.2",
"symfony/http-kernel": "^7.2",
"symfony/mailer": "^7.2",
"symfony/mime": "^7.2",
"symfony/process": "^7.2",
"symfony/routing": "^7.2",
"symfony/serializer": "^7.2",
"symfony/validator": "^7.2",
"symfony/yaml": "^7.2",
"doctrine/annotations": "^2.0",
"symfony/psr-http-message-bridge": "^7.2",
"wikimedia/composer-merge-plugin": "^2.0"
},
"conflict": {
"drupal/drupal": "*"
},
"minimum-stability": "dev",
"prefer-stable": true,
"config": {
"sort-packages": true,
"allow-plugins": {
"composer/installers": true,
"drupal/core-composer-scaffold": true,
"drupal/core-project-message": true,
"drupal/core-vendor-hardening": true,
"wikimedia/composer-merge-plugin": true,
"php-http/discovery": true,
"phpstan/extension-installer": true
}
},
"extra": {
"drupal-scaffold": {
"locations": {
"web-root": "./"
}
},
"installer-paths": {
"core": [
"type:drupal-core"
],
"libraries/{$name}": [
"type:drupal-library"
],
"modules/contrib/{$name}": [
"type:drupal-module"
],
"profiles/contrib/{$name}": [
"type:drupal-profile"
],
"themes/contrib/{$name}": [
"type:drupal-theme"
],
"drush/Commands/contrib/{$name}": [
"type:drupal-drush"
],
"modules/custom/{$name}": [
"type:drupal-custom-module"
],
"themes/custom/{$name}": [
"type:drupal-custom-theme"
]
},
"drupal-core-project-message": {
"include-keys": [
"homepage",
"support"
],
"post-create-project-cmd-message": [
"<bg=blue;fg=white> </>",
"<bg=blue;fg=white> Congratulations, you’ve installed the Drupal codebase </>",
"<bg=blue;fg=white> from the drupal/legacy-project template! </>",
"<bg=blue;fg=white> </>",
"",
"<bg=yellow;fg=black>Next steps</>:",
" * Install the site: https://www.drupal.org/docs/8/install",
" * Read the user guide: https://www.drupal.org/docs/user_guide/en/index.html",
" * Get support: https://www.drupal.org/support",
" * Get involved with the Drupal community:",
" https://www.drupal.org/getting-involved",
" * Remove the plugin that prints this message:",
" composer remove drupal/core-project-message"
]
}
},
"merge-plugin": {
"include": [
"modules/contrib/webform/composer.libraries.json"
]
},
"require-dev": {
"drupal/composer_deploy": "^1.6",
"mglaman/phpstan-drupal": "^1.2",
"palantirnet/drupal-rector": "^0.12.4",
"phpstan/extension-installer": "^1.3",
"phpstan/phpstan": "^1.10",
"phpstan/phpstan-deprecation-rules": "^1.1"
}
}
Now you can run.
composer update
You must run updates to the database
drush updb
Then clear the cache.
drush cr
This should have an updated Drupal installation with all the modules that work under Drupal 11.1.2.
Steps to Automation
1. Create the Script File:
Open your favourite editor copy the code below, edit to your preference, and save the script to a file named drupal_updater
(without an extension) in your ~/bin
directory.
#!/bin/bash
# Change to the directory where your Drupal installation is located
cd /path/to/your/drupal/installation
# Function to send email notification
send_email() {
local subject=$1
local body=$2
ADMIN_EMAILS=$(drush sql-query "SELECT GROUP_CONCAT(mail SEPARATOR ',') FROM users_field_data ufd INNER JOIN user__roles ur ON ufd.uid = ur.entity_id WHERE ur.roles_target_id = 'administrator';")
echo "$body" | mail -s "$subject" $ADMIN_EMAILS
}
# Update Composer dependencies
composer update --prefer-dist --no-progress --no-suggest --no-interaction
if [ $? -ne 0 ]; then
send_email "Composer update failed" "Composer update failed. Please check the logs for details."
exit 1
fi
# Run Drupal database updates
drush updb -y
if [ $? -ne 0 ]; then
send_email "Drupal updb failed" "Drupal updb failed. Please check the logs for details."
exit 1
fi
# Clear Drupal cache
drush cr
if [ $? -ne 0 ]; then
send_email "Drush cache clear failed" "Drush cache clear failed. Please check the logs for details."
exit 1
fi
# If all steps are successful, send a success email
send_email "Drupal Maintenance Successful" "All maintenance tasks completed successfully."
Tell us how you managed to update your Drupal installation, or share your frustrations in the comments!
2. Make the Script Executable:
Open your terminal and run the following command to make the script executable:
chmod +x ~/bin/drupal_updater
Add drupal_updater to Your $PATH
If ~/bin
is not in your PATH, you can add it by editing your shell configuration file (e.g., ~/.bashrc, ~/.profile
).
Add the following line to the file:
export PATH="$HOME/bin:$PATH"
After adding the ~/bin directory, refresh the shell to apply the changes:
source ~/.bashrc # or source ~/.zshrc or source ~/.profile depending on your shell
4. Set Up the Cron Job:
Edit your cron table by running crontab -e
.
Add the following line to schedule the script to run daily at 2 AM UTC you can adjust this to your preference:
0 2 * * * ~/bin/drupal_updater