開始的時候,使用本機wyc用戶名及group名staff,發現session寫到了/var/tmp/下面,wyc帳戶沒有權限寫,切換到root帳戶,
php
切換到root帳戶,及wheel組
nginx
php-fpm啓動項裏有-c能夠容許用root啓動
-R, --allow-to-run-as-root
Allow pool to run as root (disabled by default)session
2.切換Nginx的帳戶,默認nobody,切換成root帳戶,user root 會報錯
➜ conf sudo /usr/local/openresty/nginx/sbin/nginx -s reload
nginx: [emerg] getgrnam("root") failed in /usr/local/openresty/nginx/conf/nginx.conf:3php-fpm
必須加上wheel組名就行了rest