This is the mail archive of the cygwin mailing list for the Cygwin project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Cygrunsrv crashes when setting STDERR to /dev/null

Hi group,

I have Apache running via cygrunsrv on a WinXP system. It works fine. Apache can
even do a setuid on startup, so a 'ps -ef' looks like this:

     UID     PID    PPID  TTY        STIME COMMAND
   httpd    1604    1308 ?        14:26:47 /usr/local/apache/bin/httpd
  SYSTEM    1308    1400 ?        14:26:47 /usr/local/apache/bin/httpd
   httpd     896    1308 ?        14:26:47 /usr/local/apache/bin/httpd
   httpd     536    1308 ?        14:26:47 /usr/local/apache/bin/httpd
   httpd     612    1308 ?        14:26:47 /usr/local/apache/bin/httpd
   httpd     560    1308 ?        14:26:47 /usr/local/apache/bin/httpd

As you can see, I have it running as 'httpd', an unprivileged user, which I created
without password and removed from the 'Users' group, so it cannot login.

Unfortunately, this doesn't work on a Win7 system. If I try the same configuration
in a Win7 system, the following message is logged in logs/error_log and the Service
won't start:

[alert] (1)Operation not permitted: setuid: unable to change to uid: 1006

So, I set a password for the 'httpd' user and configured the Service to log on as
that user. This works, but now I cannot use cygrunsrv's -1 or -2 switches for
redirecting STDOUT and STDERR anymore.

cygrunsrv crashes if I set either one of them to /dev/null. If I unset them, it

Can anybody help?


Problem reports:
Unsubscribe info:

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]