• Please be aware: Kaspersky Anti-Virus has been deprecated
    With the upgrade to Plesk Obsidian 18.0.64, "Kaspersky Anti-Virus for Servers" will be automatically removed from the servers it is installed on. We recommend that you migrate to Sophos Anti-Virus for Servers.
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Resolved sw-engine.service gets killed after 1-2 minutes

sternwanderer

New Pleskian
Hello Plesk community

I am running Plesk Onyx 17.8.11 Update #91 , last updated at Nov 6, 2020 01:20 AM on ‪Ubuntu 18.04.5 LTS‬

Recently I started having the following error when accessing the plesk control panel:

Server Error
502
Bad Gateway

When opening the Repair Kit I see that the sw-engine.service is stopped.
So I click restart processes and after that the access to the control panel works again for a minute or 2.

Then the same problem happens again.

When I do service sw-engine status I get the following output:

● sw-engine.service - Startup script for Panel sw-engine
Loaded: loaded (/lib/systemd/system/sw-engine.service; enabled; vendor preset: enabled)
Active: failed (Result: signal) since Fri 2020-11-06 12:35:43 CET; 1min 55s ago
Process: 6968 ExecStopPost=/usr/bin/find /run/lock/lmlib/ -mindepth 1 -delete (code=exited, status=0/SUCCESS)
Process: 6729 ExecStart=/usr/sbin/sw-engine-fpm --fpm-config /etc/sw-engine/sw-engine-fpm.conf -c /usr/local/psa/admin/conf/php.ini --nodaemonize --pid /r
Main PID: 6729 (code=killed, signal=SEGV)
Status: "Processes active: 0, idle: 5, Requests: 7, slow: 0, Traffic: 0req/sec"

When I do less /var/log/sw-cp-server/sw-engine.log I get the following output:

[06-Nov-2020 12:26:27] NOTICE: fpm is running, pid 452
[06-Nov-2020 12:26:27] NOTICE: ready to handle connections
[06-Nov-2020 12:26:27] NOTICE: systemd monitor interval set to 10000ms
[06-Nov-2020 12:34:55] NOTICE: fpm is running, pid 6729
[06-Nov-2020 12:34:55] NOTICE: ready to handle connections
[06-Nov-2020 12:34:55] NOTICE: systemd monitor interval set to 10000ms

When I do less /var/log/sw-cp-server/error_log I get the following output

2020/11/06 12:33:58 [error] 574#0: *43 connect() to unix:/var/run/sw-engine.sock failed (111: Connection refused) while connecting to upstream, client: xxx.xxx.xxx.xxx, server: , request: "GET /admin/ip-address/refresh HTTP/1.1", upstream: "fastcgi://unix:/var/run/sw-engine.sock:", host: "www.mydomain.com:8443", referrer: "https://www.mydomain.com:8443/admin/ip-address/list/"

How can I see what caused sw-engine.service to stop?
Any ideas?

Thank you in advance :)
 
Hello,
your post is realy pleasure to me. Looks like this problem is not our fault. There must be a bug concerning last update we received.
Please read my thread. Maybe we get much faster help. We are two people with the same problem....


Last Advice from Moderator Igor i did not aply cause i'm not that nerd. I wont kill my server. I dont know if igors advice could help. I'm not that specialist.

Greetings / Andreas
 
@jumpstart:
# plesk installer --select-release-current --reinstall-patch --upgrade-installed-components
which IgorG provided fixes all issues with Plesk files and tries to install or replace faulty files that do not match their standard installation with their latest correct files. It is a "magic" line that can fix a lot of basic issues with a Plesk installation. If this kills your server, you had severe issues with your operating system before that fix was run.

@sternwanderer:
/var/log/sw-cp-server/error_log and /var/log/sw-cp-server/sw-engine.log are the two places to look at. You already did. Are your sure that your local IP is not being blocked by your local firewall like iptables, firewalld or whatever you might have? For example by Fail2Ban because the local IPs were not whitelisted?
 
Hello together,
just applyed magic line above. It endet up with success. Server still working. But I'm sorry. It's not the solution. The problem ist still alive.
Further Help welcome.
 
You'll need Plesk support. I think it's an issue with the operating system configuration or your system's resources, but this needs to be dealt with on the machine. Now way to figure this out by forum posts.
 
Since this morning I have exactly the same described problem on 2 V-servers (Contabo).
Ubuntu 18.04.5 LTS and Plesk Onyx Version 17.8.11 Update #91

Server Error
502
Bad Gateway

When freeing up disc Space and restart sw.engine the problem repeats after a few minutes.
See attached png.
Any help would be very welcome!
 

Attachments

  • 502.png
    502.png
    159.1 KB · Views: 9
I contactet Contabo/Plesk support and here ist the answer:

This is a bug that will be fixed with the next Plesk release. In the meantime, Plesk support has implemented a workaround by modifying /etc/sw-engine/pool.d/plesk.conf as follows

pm = dynamic
pm.start_servers = 2
pm.min_spare_servers = 2
pm.max_spare_servers = 8

For me it works...
 
I contactet Contabo/Plesk support and here ist the answer:

This is a bug that will be fixed with the next Plesk release. In the meantime, Plesk support has implemented a workaround by modifying /etc/sw-engine/pool.d/plesk.conf as follows

pm = dynamic
pm.start_servers = 2
pm.min_spare_servers = 2
pm.max_spare_servers = 8

For me it works...
Thank you very much!

This workaround worked for me too :)
 
Back
Top