Nginx + apache + ssl = 421 misdirected request

@servtelecom
As described above, to also fix phpmyadmin & webmail:
echo -e "proxy_ssl_server_name on;\nproxy_ssl_name \$host;" > /etc/nginx/conf.d/fixssl.conf && service nginx restart

2 Likes

I checked it myself - I can’t confirm. The script works correctly. Webmail opens without problems.

1 Like

exactly, just like @jekasumy stated, webmail works too. Roundcube is mine.
Are you running the command as root/admin? try rebooting once.

The script must be run under root. Everything works. I don’t see a problem at the moment.

1 Like

Yes. Hence I asked the question. I ran it as root only. Worked fine, but as @servtelecom says, it does not seem to be working for mail.

1 Like

Try running - v-rebuild-mail-domains yourusername

This should solve the problem.

I think you are confused. It runs fine for me, and I was suggesting and asking the user above. Everything works perfectly fine for me.
But @servtelecom (Alex), try what @jekasumy (Yevhen) states. It should help solve your issue. :slight_smile:

1 Like

I don’t have any problems either.

1 Like

Hi,
I’m having the same problem, I only get the sucess page of the server, not the website
could you help me, pleae?
thanks
bes

@mavbcn follow this. Run as root.

2 Likes

Hi,
Only to use the script? or I have to do some other changes?
thanks for your help

1 Like

the laravel site works fine, but I have a site in cloudflare with full strict, and I have a Invalid SSL certificate Error code 526
thanks for your help

Just want to thank @maurice and @sahsanu for your wonderful help.
:heart:

8 Likes

A huge shout out to @maurice and @sahsanu. I did the updates and was scratching my head there for a while.

6 Likes

Thanks for the solution, I thought I had unintentionally broken something… (I’m no linux expert, and I’m always testing, changing things…).

Now I see it’s a general problem. I’ve already fixed it thanks to the help you offer here (thank you very much).

Would it be possible to implement this automatic repair in HestiaCP? I have more VPS with hestiacp and I’m worried about them updating and breaking… I don’t know if it’s better to update them and break them myself, and then repair them, or wait for Hestia to implement this solution automatically.

Thanks

1 Like

Well, @sahsanu and another guy I saw earlier on another topic about same issue, already sent a request on github in order to fix the issue… By myself, what I can tell to anyone interested, is that I have made a fresh Debian 12 install on a VM and have installed HestiaCP 1.9.3 on it and issue is presented since this installation, fixed again with @sahsanu scripts provided earlier here…

Now, if you are not sure about update or not other VPS my suggestion will be to first download a backup copy of all users of the Server and if you have Snapshots available on the VPS you could take 1 before update and if after update, fix scripts and server reboot (or just restart Apache and Nginx services, something I did) is not working certainly you can revert changes with snapshot, in the worst scenario, you will have backups, so server reinstall and restore still possible… (U will need to run fix anyway hehe).

I just tried it and it worked for me! Thank you so much! Excellent work!

2 Likes

Thank you! That solved the problem!

2 Likes

It worked very well
thanks so much for your help!

1 Like

@maurice & @sahsanu you saved my life. My clients were ready to eat me alive! :stuck_out_tongue:

3 Likes