Need advice for home directory of system user

Normally, I create system user without home directory and login shell as following

Code:
#pw useradd phpwww -g phpwww -d /nonexistent -s /usr/sbin/nologin -c "php user for www use"

I am considering to assign a home directory to the above system user, since it is not a general user, any suggestion from a system admin view?

PS. it's another story why I want to assign a home directory to the PHP user. Because I am experiencing "connection-timeout" while connecting Paypal production server occasionally. I am trying to fix it, and thinking maybe the PHP system user lacks a home directory to store the SSL certificate which causes slow connection.
 
You can both change the user settings and assign a home directory like any other normal user (/usr/home) or can keep the home directory somewhere else (/var?) to emphasize this is not a regular user. I tend to prefer the latter, even if this means my servers have double home-places.
 
And, to throw a third option into the mix, you might consider creating /usr/home/sysacct and keeping that (and future system accounts) as children, a la /usr/home/sysacct/foo, /usr/home/sysacct/bar...
 
As can be seen from the replies so far, it doesn't matter that much. Just make sure that the filesystem is mounted (usually at boot time, through /etc/fstab), that there's enough space and that the file permissions are properly set.

Fonz
 
Back
Top