ISPConfig and phpMyAdmin user and session

Discussion in 'Installation/Configuration' started by ayublin, Mar 10, 2014.

  1. ayublin

    ayublin New Member

    Hi Everyone,

    Here is the server info:
    Centos 6 64bit
    Nginx Web Server
    ISPConfig 3

    I followed the instruction here:
    To setup then server and phpmyadmin.

    I created a site via ISPConfig for example, and under php-fpm.d conf files I can see it's assigned with user `web1`, and it's showing the `web1` user also with `top` command upon accessing the site.

    Then I tried accessing phpmyadmin via this site like this:

    I can access the login page, but after entering the credentials, nothing happens. It seems that there is an issue of non writable session path which is:
    `/var/www/`. I can see via `top` command that the phpmyadmin is run under `nginx` user, as `/var/www/` is owned by `web1` I suspect the `nginx` user can't write to it and causing the problem.

    Any work around to fix this? Thanks a bunch in advance!
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    phpmyadmin is run under the apps vhost and the nginx user and not the website So does does not use the /var/www/ directory for temporary files.

    Take a look at the nginx error log (the global one, not the one of the website as the website is not related to the running phpmyadmin) and the php-fpm error log.
  3. ayublin

    ayublin New Member

    Thanks for the reply Till,

    Ah I see, I checked the global error logs and found no errors, but after examined the global conf file of php-fpm at `/etc/php-fpm.d/www.conf` I can see that the `session.save_path` is pointed to `/var/lib/php/session` and it is owned by `root` with 770 permission. After changing it to 777, the phpmyadmin worked! Do you think this is the right thing to do?
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    Yes, thats the right solution. The path /var/lib/php/session is a Centos system directory, that it is owned by root does not make any sense as php (except of shell scripts that dont use sessions at all) is never run as root. I will have to add a note to the centos guides to check and adjust the permissions of that directory.
  5. ayublin

    ayublin New Member

    Cool! also just tried using 775 instead of 777, and it worked as well :) Thanks again Till!

Share This Page