Applicable to:
- Plesk for Linux
Symptoms
-
All websites show the error:
PLESK_INFO: 421 Misdirected Request
-
The following error message is logged in domain's log (Plesk > Domains > example.com > Logs):
CONFIG_TEXT: AH02032: Hostname default-203_0_113_2 (default host as no SNI was provided) and hostname www.example.com provided via HTTP have no compatible SSL setup
Cause
In recent Apache version, Apache team has released fixes for CVEs that affected Apache + nginx functionality: new changes do not allow Apache process requests from nginx without the server name (by default, nginx does not pass the server name through SNI when establishing a connection with a proxied HTTPS server).
This issue has been addresses in Plesk Obsidian 18.0.70 and later releases.
Resolution
Update Plesk Obsidian to the latest build.
Note: The hotfixes are compatible with the manual workaround. So, even for servers where manual solution is already applied, no extra steps are required after installing Plesk update.
Manual workaround for previous Plesk versions:
Add proxy_ssl_server_name, proxy_ssl_name and proxy_ssl_session_reuse directives in nginx configuration to make nginx pass the server name to Apache through TLS Server Name Indication (SNI) extension:
- Connect to the Plesk server via SSH.
-
Run the script (without any modifications):
# echo -e "proxy_ssl_server_name on;\nproxy_ssl_name \$host;\nproxy_ssl_session_reuse off;" > /etc/nginx/conf.d/fixssl.conf && systemctl restart nginx
Comments
The update last night 18.0.71 broke ours
Support said, the issue happened due to Apache package update from OS repository, it has nothing to do with Plesk version.
The below workaround worked.
You took all Plesk hosted websites down, worldwide. Good job.
You guys seriously need a better way to alert users to critical failures like this inside the plesk control panel!!! Otherwise I spend previous minutes googling and freaking out!
Thank you for the quick fix. Adding the nginx directives and restarting the service resolved the 421 Misdirected Request error.
Best regards
Kev
For goodness sake. If you update the fix for an ongoing issue, add some notes to explain it! It looks like the 3rd parameter change added (but not highlighted) has fixed the issue with this only working for the first site visited, which many people have reported. This needs to be made clear for those still with an issue.
And add a important note about people posting “me too”. Anyone trying to follow updates on this is getting flooded with pointless replies saying it works for them, or others who clearly have a different issue.
Confirmation: Solution for “421 Misdirected Request” after Apache update
I can confirm that the workaround described in this article immediately resolved the “421 Misdirected Request” error on all of my domains after the recent Apache update.
All websites are accessible again via HTTPS and HTTP/2 without any issues.
Thank you for providing an effective and straightforward solution!
Plesk Obsidian 18.0.71
Ubuntu 22.04.5 LTS
Fix worked for me.
echo -e "proxy_ssl_server_name on;\nproxy_ssl_name \$host;" > /etc/nginx/conf.d/fixssl.conf && service nginx restart
However, do we now need to leave the new fixssl.conf in place indefinately or will Ubuntu/Plesk push an update to fix what Ubuntu broke?
For those not operating the command line, you may use these - non global - settings in Plesk panel.
Additional nginx directives:
proxy_ssl_server_name on;
proxy_ssl_name $host;
I tested the 18.0.71.1 update on my Ubuntu 22.04 server AFTER having applied the manual patch yesterday. Everything still works, but it would be great to know if any steps need to be taken for those who had applied the manual patch before the update was published.
Its also on Ubuntu 24.04.2 LTS.
If the patch was done before “Plesk Obsidian 18.0.71 Update 1”, should we remove the patch after the update?
If so, perhaps you could update this article.
I updated Plesk to version 18.0.71, which is supposed to include the official fix for the
"421 Misdirected Request"issue caused by the recent Apache update.After the upgrade, I tried to remove the temporary workaround (the one adding
proxy_ssl_server_name on, etc. in/etc/nginx/conf.d/fixssl.conf) and restarted NGINX — but unfortunately, the 421 error came back right away.So for now, I've restored the patch, and everything is working fine again.
Even after updating to 18.0.71, the issue still seems to persist in some environments. I recommend keeping the patch in place for now until a more complete fix or further guidance is provided by Plesk.
This kb has become very noisy. if you have problems do not comment here, but go to the plesk forum. it is very disurbing that on one hand we have to follow the issue for updates and on the other hand reading all day long issues from users which do not solve the problem. so please go to the forum and seek for help there. thanks
When the fix released? I didn't run update the apache but why my server got this error in sudden in this morning (Hong Kong time).
I get a permission error running that script
My automatic updates have been disabled and this error happend as well. Is plesk doing some package updates even if auto updates are disabled? The fix above worked for me.
Same issue and fixed with the above script.
worked like a charm and saved my day with over 100+ website.
confirmed working on Ubuntu 22.04.5 LTS Plesk Obsidian 18.0.65 Update #2 Web Host Edition
Great to see there's swift support here. Fix applied as mentioned under sudo -s and got all sites working again
Thank you! The fix worked. Appreciate it!
I removed the nginx from plesk and that has solved the issue for me
For me the command below worked .. but if I restart server, same problem and have do redo command
How to solve that?
Command used:
Hey George Kwan
Most likely you have automatic system updates setting checked in your Plesk at Tools & Settings > Update Settings.
This setting triggers system update every night.
Yes, I just noticed this option is enabled.
Andrew Petty I guess you have to log in to your server as a root user or a user which has administrative rights.
Try running
sudo suin your SSH console to switch to root or use SSH Terminal extension in Plesk.I applied the script above as root but that just gave a 403 permission page on the website. So I reverted out those lines and back to Misdirected issue.
Kuzma Ivanov
I also had this issue which is fixed by the resolution provided, However this has impacted our system for:
1. The request that was on Apache previously is now coming as Nginx (as checked in server logs)
2. I've running project of PHP where I fetch data of multipart/form-data using $_REQUEST but now due to this it's always set to blank.
Could you please let me know how can I resolve both of the points?
Thank you so much! Saved my day!
This solution works perfectly fine.
Strange, because this problem affect to my Ubuntu 24.04.2 LTS, but NOT to other server with Ubuntu 24.04.1 LTS
Of course, the solution provided works perfectly! Thank you.
I also got a 403 Error and all websites did not work anymore after applying the fix and restarting the service. Any idea? Missing default domain for exampe?
How is it possible to publish an update, that disables plesk hosted websites over night? that is really bad and makes me think to ditch plesk completely.
Please sign in to leave a comment.