permission issues with ISPConfig3, nginx and cakephp

Discussion in 'Installation/Configuration' started by ItsDom, Dec 21, 2012.

  1. ItsDom

    ItsDom New Member


    I've installed ISPConfig3 according to the perfect server suse 12.2 nginx (with php-fpm), dovecot, ispconfig3 setup but I'm having some issues. I'm sure they're probably not real problems, just me not quite understanding things:

    1) I created a site, and extracted the cakephp files to the web folder for that site. Unless I chown root:root with the cakephp folder, I just get 404's when I try load any of the pages. Yet when it root is the owner, even with 777 permissions, the pages load but report that the tmp directory (cakephp's temp directory, /app/tmp) can't be written to.

    This confuses me as according to the site setup in ISPConfig, the user is web2 and group is client0.

    2) Also, when I update the nginx directive field in the options through ISPconfig, it wont make any changes until I restart nginx - is this normal behaviour? Is there a shortcut or way to do it through ISPConfig without having to go through the terminal? It seems to undermine the point of ISPConfig allowing a semi-automated multi-user hosting environment if when the user wants to change their settings they have to restart nginx (because if they can restart nginx, they can disrupt other users hosting, so they would have to ask me to do it instead)

    3) So I can only get cakephp pages to even be visible (e.g. not 404) if I chown root:root. Yet I'm regularly restarting nginx to apply changes to the directives (once all is up and running, I obviously wont have to do this much) but when I restart nginx, it chowns all the files in /web/ back to web2:client0, breaking the little bit of success I have with cake. Is this meant to happen? I'm guessing solving problem 1) would probably solve this problem also.

    I feel I've not quite got something setup right, but I'm not sure what. Any input would be greatly appreciated.

    Thanks in advanced,

  2. falko

    falko Super Moderator ISPConfig Developer

    The PHP process is running as web2:client0, so the files/directories must be owned by that user/group.

    No, this is not normal. Something seems to be wrong with your setup.

    nginx isn't changing any permissions.

    Which distribution do you use, and which tutorial (URL) did you use to set up the system? Are there any errors in your logs?
  3. ItsDom

    ItsDom New Member

    Hi, thanks for the response. Sorry for the delay (festive season etc - hope you had a nice one)

    The tutorial I was using was this one:

    I'm using a 32bit build of suse 12.2 build on suse studio from JeOS with all the packages added through suse studio. It's a 32 bit build as it's running in ESXi guest on an old Dell PE1850 (doesn't have VT-x so can only do 32 bit guests)

    ISPConfig interface works fine.

    I think the relevent log in the error file is:

    WARNING: [pool www] child 2267 said into stderr: "ERROR: Unable to open primary script: /usr//html/index.php (No such file or directory)"
    However, I can't at all figure out how it's coming up with the path /usr//html/ - in which config file is this defined?

    Thanks again for the help.


    EDIT: another strange quirk. If I visit http://sausage.server/ I get 404. Yet if I go to http://sausage.server/login.php (I copied the files from the ISPC remote access examples) the file loads (says logged in etc)

    However, if i go to http://sausage.server/index.html I get a 404, despite the default index.html file being in the same directory as the login.php which appears to work fine.

    (sausage.server is an internal domain)
    Last edited: Dec 30, 2012

Share This Page