• 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

Forwarded to devs CGroups dont start a session scope on create (Filemanager error)

B4c4rd1

Regular Pleskian
TITLE:
CGroups dont start a session scope on create (Filemanager error)
PRODUCT, VERSION, OPERATING SYSTEM, ARCHITECTURE:
Plesk Onyx, Version 17.0.17 Update #20, Ubuntu 16.04.2 LTS‬, 64 Bit VM
PROBLEM DESCRIPTION:
Various errors in filemanager related to CGroups.

Error messsages:
Code:
Error: Unable to find the file /var/www/vhosts/WEB/ at the specified location

or

Warning: Symlinks out of webspace are prohibited /: Access to realpath denied: /var/www/vhosts/WEB/ to /var/www/vhosts/WEB.

Once a new web is created, there are permission problems and the path to the web can not be found etc.

Syslog:
Code:
Apr  4 00:26:26 srv-01 systemd[1]: user-10017.slice: Start request repeated too quickly.
Apr  4 00:26:26 srv-01 systemd[1]: Failed to start user-10017.slice.
Apr  4 00:26:26 srv-01 systemd[1]: Dependency failed for User Manager for UID 10017.
Apr  4 00:26:26 srv-01 systemd[1]: [email protected]: Job [email protected]/start failed with result 'dependency'.

Systemctl --failed:
Code:
● session-c73869.scope    loaded failed failed Session c73869 of user XXXXX

Systemctl status session-c73869.scope:
Code:
● session-c73869.scope - Session c73869 of user XXXX
   Loaded: loaded
Transient: yes
  Drop-In: /run/systemd/system/session-c73869.scope.d
           └─50-After-systemd-logind\x2eservice.conf, 50-After-systemd-user-sessions\x2eservice.conf, 50-Description.conf,
   Active: failed (Result: resources)

Apr 04 00:21:47 srv-01 systemd[1]: session-c73869.scope: Failed to add PIDs to scope's control group: No such process
Apr 04 00:21:47 srv-01 systemd[1]: Failed to start Session c73869 of user XXXX.
Apr 04 00:21:47 srv-01 systemd[1]: session-c73869.scope: Unit entered failed state.
STEPS TO REPRODUCE:
Create a customer, create a web and activate CGRoups. Then go to the filemanager....​
ACTUAL RESULT:
Filemanager not working!​
EXPECTED RESULT:
With deactivated cgroups, filemanager now work...​
ANY ADDITIONAL INFORMATION:
To solve the problem, a PHP file must be called once under the web. Then the session is properly registered and everything works.

After open PHP File:
Code:
Apr  4 00:27:03 srv-01 systemd[1]: Created slice user-10017.slice.
Apr  4 00:27:03 srv-01 systemd[1]: Starting User Manager for UID 10017...
Apr  4 00:27:03 srv-01 systemd[1]: Started Session c73971 of user XXXX.
YOUR EXPECTATIONS FROM PLESK SERVICE TEAM:
Confirm bug
 
Last edited:
04.04.2017
I have more information. The file manager on the phone works correctly. This also opens only one session correctly:
Code:
Apr  4 12:16:16 srv-01 systemd[1]: Started Session c79687 of user XXXX.

The onyx web-filemanager creates a separate session for each file or folder (One load!):
Code:
Apr  4 12:20:14 srv-01 systemd[1]: Started Session c79747 of user XXXX.
Apr  4 12:20:14 srv-01 systemd[1]: Started Session c79748 of user XXXX.
Apr  4 12:20:14 srv-01 systemd[1]: Started Session c79749 of user XXXX.
Apr  4 12:20:14 srv-01 systemd[1]: Started Session c79750 of user XXXX.
Apr  4 12:20:14 srv-01 systemd[1]: Started Session c79751 of user XXXX.
Apr  4 12:20:14 srv-01 systemd[1]: Started Session c79752 of user XXXX.
Apr  4 12:20:14 srv-01 systemd[1]: Started Session c79753 of user XXXX.
Apr  4 12:20:14 srv-01 systemd[1]: Started Session c79754 of user XXXX.
Apr  4 12:20:14 srv-01 systemd[1]: Started Session c79755 of user XXXX.
Apr  4 12:20:14 srv-01 systemd[1]: Started Session c79756 of user XXXX.
Apr  4 12:20:14 srv-01 systemd[1]: Started Session c79757 of user XXXX.
Apr  4 12:20:14 srv-01 systemd[1]: Started Session c79758 of user XXXX.
Apr  4 12:20:14 srv-01 systemd[1]: Started Session c79759 of user XXXX.
Apr  4 12:20:14 srv-01 systemd[1]: Started Session c79760 of user XXXX.
Apr  4 12:20:14 srv-01 systemd[1]: Started Session c79761 of user XXXX.
 
Developers tried to reproduce the issue on the test environment. Same OS, same Plesk - everything is working fine.
Seems like there are additional steps to reproduce this issue.
Could you please provide more steps to reproduce this issue? Or maybe login credentials of your server for our developers? You can send it to me in PM.
 
I have more information:

- graceful restart is activatet
- reboot the VM, if not reproduce
- Go back and forth quickly in the etc and httpdocs folders or other folders
- Look at the log file at tail -f / var/log/syslog

Message:
Code:
Unable to open the directory: Symlinks out of webspace are prohibited /httpdocs: Access to realpath denied: /var/www/vhosts/XXXX/httpdocs to move_to_cgroup(): pam_open_session() failed 6: Permission denied,move process 13719 to cgroup for user XXXX failed,/var/www/vhosts/XXXX/httpdocs.

Log:
Code:
Apr  6 14:16:23 srv-02 systemd[13731]: Reached target Timers.
Apr  6 14:16:23 srv-02 systemd[13731]: Reached target Sockets.
Apr  6 14:16:23 srv-02 systemd[13731]: Reached target Paths.
Apr  6 14:16:23 srv-02 systemd[13731]: Reached target Basic System.
Apr  6 14:16:23 srv-02 systemd[13731]: Reached target Default.
Apr  6 14:16:23 srv-02 systemd[13731]: Startup finished in 6ms.
Apr  6 14:16:23 srv-02 systemd[1]: Started User Manager for UID 10003.
Apr  6 14:16:23 srv-02 systemd[1]: Stopping User Manager for UID 10003...
Apr  6 14:16:23 srv-02 systemd[13731]: Reached target Shutdown.
Apr  6 14:16:23 srv-02 systemd[13731]: Stopped target Default.
Apr  6 14:16:23 srv-02 systemd[13731]: Stopped target Basic System.
Apr  6 14:16:23 srv-02 systemd[13731]: Stopped target Timers.
Apr  6 14:16:23 srv-02 systemd[13731]: Stopped target Sockets.
Apr  6 14:16:23 srv-02 systemd[13731]: Stopped target Paths.
Apr  6 14:16:23 srv-02 systemd[13731]: Starting Exit the Session...
Apr  6 14:16:23 srv-02 systemd[13731]: Received SIGRTMIN+24 from PID 13739 (kill).
 
Last edited:
From developers:

Looks like user slice is started too quickly and start limit burst takes an effect.
Unfortunately we cannot reproduce this problem on local test server so we'll take one more day for investigation.

P.S. as temporary workaround you may set StartLimitBurst=999 (or another big number) for user slices.
 
Bug has been confirmed and submitted as PPP-28915

Workaround 1

For each affected user create file "/etc/systemd/system/user-$userid.slice.d/51-StartLimit.conf" which contains:

[Unit]
StartLimitBurst=999

Workaround 2
Override DefaultStartLimitBurst for all systemd units:
set DefaultStartLimitBurst=999 in "/etc/systemd/system.conf".
This will affect not only slices but other services as well.

Do not forget to systemctl daemon-reload after making changes.
 
Hi @IgorG

This is really a very good news!

I think I found the next bug. I wondered yesterday that my limits were no longer active. Restarting CGroups has not changed anything. I had to stop the service completely and start again.

If I have more information, I make a new thread on it.

Do you still need the VM?
 
Back
Top