As I installed nginx 1.6.x from Debian dotdeb repository, the daemon nginx started automatically using the user ‘www-data‘. As I wanted to change this user in the configuration file /etc/nginx/nginx.conf from:
user www-data;
TO
user appuser;
NGinX didn’t want to start any more and found the following line in the error logs:
[emerg]: getgrnam(“appuser”) failed in /etc/nginx/nginx.conf:1
I verified that the user existed in the system
id appuser
Result:
uid=2001(appuser) gid=3000(apps) groups=3000(apps)
Thanks to this site I got what went wrong.
http://nu2ruby.wordpress.com/2010/04/13/nginx-getgrnam-presmini-failed/

The problem was that nginx needs also the group. So I completed the line as follows and it worked.
user appuser apps;