• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Issue 502 Bad Gateway - after applying updates

CChris

New Pleskian
Server operating system version
Ubuntu 22.04
Plesk version and microupdate number
18.0.53
Hi there,
today I wanted to change the imap server package from Courier to Dovecot.
After selecting Dovecot in the Plesk Package Installer - the installation / migration script looked good... I did not notice any error during the installation
But my Plesk Server was then throwing an "Server Error 502 Bad Gateway"

... Since I could not start the Repair Kit (I don't really know why) - I started to roll back from a Backup created yesterday afternoon...

Later, I wanted to apply some updates, that were shown in the Plesk Package Center... and again, after applying the backups, I just got the 502 "bad gateway"...
Unfortunately, the support from my hoster wasn't very helfpul and they only told me, that I need to restore the backup (again) ...

Based on their information, I should not apply all listed updates at once, but should apply them one after another ... to see, where / when the server is running into this issue

But before I got the 502 error, I the Plesk Website did show another error this time:

Syntax Error
JSON.parse: unexpected character at line 1 column 1 of the JSON data

So I expect an invalid configuration SOMEWHERE... but it is unclear to me, where I should look at.
The Plesk package center (Port 8447) is still available when the server is in the error state...

Installed packages in case it helps:
- Plesk
- BIND DNS Server
- Fail2Ban
- All language localization for Plesk
- Git
- Plesk Migrator
- MySQL Server
- Webmail
---- Horde
- Mail Hosting
---- SpamAssassin
---- SMTP Servers
-------- Postfix
---- IMAP / POP3 Servers
-------- Courier
- Web Hosting
---- ProFTPD
---- Webalizer
---- AWStats
---- ModSecurity
---- Apache
------ mod_fcgid
------ Apache
---- PHP interpreter
------ 8.2
------ 8.1
------ 8.0
------ 7.4
------ PHP from OS vendor
- Plesk extensions
---- Plesk Firewall
---- WP Toolkit
---- SSLit!
---- Let's Encrypt
---- RepairKit
---- PHP Composer
---- Monitoring
---- Site Import

Any suggestions on how to solve the issues, figure out what's going wrong rather than restore the whole server backups every time?
Thanks!
 
- Please check /var/log/plesk/install/autoinstaller3.log for what has happened during the updates. Where there really no warnings?
- Why can you not start Plesk Repair? What happens when you try to? Does this only affect the graphical user interface or can you also not run commands like "plesk repair db -y"?
 
Hi, unfortunately, I don't have any information from the time the issue happened anymore.
And unfortunately, I am not yet very well with using the cli (especially before running into this issue)...

Anyway - after restoring the backups (again) - I did some further analysis and was able to run the repair tools inside the plesk webinterface...

What I found so far (maybe, that helps)
--> Plesk showed updates for nearly all installed components (applying these, caused the second 502 error)'
After running the repair tool for some of the options were errors were detected - these updates were gone.

--> some time later, plesk update did show the same updates again...
I decided to try the option "Repair" on Plesk directly.
After checking for updates again, no available updates were shown...

Therefore, I've decided to give it a try again - and installed Dovecote (install) + uninstall Courier...
This time, it seems that everything was running smooth and without any failures.

So sorry - I know I can't provide much input atm... but I'm glad that now everything seems to work as expected :)
 
Back
Top