Website hosted in Plesk displayed incorrectly or shows 503 Internal Server Error or showing the PHP warning: Failed to read session data: files

Follow

Comments

8 comments

  • Avatar
    Soni Vimal

    I am suffering from the same issue and I use CentOs system. I cross check session.save_path through phpinfo(); it shows /var/lib/php/session.

    I rest the permissions for it but still the issue is active. please help me to resolve it. 

     

    0
    Comment actions Permalink
  • Avatar
    Bulat Tsydenov

    @Soni, check the permissions and ownership of the folder:

    # ls -ld /var/lib/php/session
    drwx-wx-wt 2 root root 4096 Nov 6 00:32 /var/lib/php/session

    Permission should be 1733

    0
    Comment actions Permalink
  • Avatar
    Justin Lnch

    Should it be session or sessions? In centos it is session. Above you have sessions?

     

    0
    Comment actions Permalink
  • Avatar
    Lev Iurev

    Hi @Justin Lnch,

    Ubuntu, Debian - /var/lib/php/sessions/

    CentOS - /var/lib/php/session/

    0
    Comment actions Permalink
  • Avatar
    MySiteMalixi

    Your answers here helps me, but i have added the directory given inside SFTP root not on the FTP and it resolved my issues. Thanks so much guys, i hope this input also helps others

    0
    Comment actions Permalink
  • Avatar
    Rizwan

    Hi,

    I am using Suse 12, And there is /var/lib/php7 folder but no session folder is there so should i create a new session directory and set permission to 1733.

    Please help me.

    0
    Comment actions Permalink
  • Avatar
    James Sweiderk

    I have encountered this issue, and the permissions and ownership appear as above for the PHP session directory, and I've confirmed the directory is named as such in the PHP configuration. The resolution of setenforce 0 works, but is apparently needs to be set frequently because the permissions issue reappears. Is there a permanent solution?

    0
    Comment actions Permalink
  • Avatar
    Ekaterina Babenko

    Hello James,

    If the disabling SELinux resolves the issue, there is possibility that the context on the /var/lib/php/session is insufficient. As far as I understood permission/ownership on directory is also got reset. The both issue require deep investigating. Please, submit request to support for further investigating. On how to do so check the article: https://support.plesk.com/hc/en-us/articles/213608509-How-to-submit-a-request-to-Plesk-support-

    0
    Comment actions Permalink

Please sign in to leave a comment.

Have more questions? Submit a request