[Slackbuilds-users] nginx permissions?
Miguel De Anda
miguel at thedeanda.com
Mon Jul 13 03:22:22 UTC 2015
basically it was to undo what the slackbuild did:
# Make the temp path.
mkdir -p $PKG/var/lib/$PRGNAM
chmod 0700 $PKG/var/lib/$PRGNAM
i'm not sure of the details of nginx creating the folders but i think
its trying to create the folders as the user nginx runs as but since
it can't access the /var/lib/nginx folder then that process fails. its
hard to identify the problem b/c the fastcgi stuff worked until the
payload was too big and it had to use the file buffers. took me awhile
to figure it a long time again and i had to figure it out again last
week when i setup a _new_ machine.
On Sun, Jul 12, 2015 at 5:13 PM, Thomas Morper <thomas at beingboiled.info> wrote:
> On Sun, 12 Jul 2015, Larry Hajali wrote:
>
>> What does setting the permissions of /var/lib/nginx to 755 accomplish?
>
> It will allow the worker processes to actually have access to the working
> directories :-)
>
> The SlackBuild sets /var/lib/nginx to 0700. On startup the master process
> will create the various sub directories with the right ownership and
> permissions, but it won't change ownership or permissions of any existing
> directory including /var/lib/nginx itself, thus the worker processes can't
> access the working directories. Drop the "chmod 700 ..." from the build
> and everything should be fine.
>
> Once up and running it should look like this:
>
> root at ks3357608:~# ll /var/lib/nginx/
> total 28
> drwxr-xr-x 7 root root 4096 Apr 21 17:30 ./
> drwxr-xr-x 38 root root 4096 Jul 12 23:59 ../
> drwx------ 2 nginx root 4096 Jun 21 21:42 client-body/
> drwx------ 2 nginx root 4096 Aug 31 2014 fastcgi/
> drwx------ 2 nginx root 4096 Aug 31 2014 proxy/
> drwx------ 2 nginx root 4096 Aug 31 2014 scgi/
> drwx------ 2 nginx root 4096 Aug 31 2014 uwsgi/
>
>> I could look at having a nginx user rather than it being optional.
>
> I'm in favour of that.
>
> --
> _______________________________________________
> SlackBuilds-users mailing list
> SlackBuilds-users at slackbuilds.org
> http://lists.slackbuilds.org/mailman/listinfo/slackbuilds-users
> Archives - http://lists.slackbuilds.org/pipermail/slackbuilds-users/
> FAQ - http://slackbuilds.org/faq/
>
More information about the SlackBuilds-users
mailing list