delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2006/08/30/13:03:25

X-Spam-Check-By: sourceware.org
Date: Wed, 30 Aug 2006 13:03:12 -0400 (EDT)
From: Igor Peshansky <pechtcha AT cs DOT nyu DOT edu>
Reply-To: cygwin AT cygwin DOT com
To: ukr DOT name DOT lists AT gmail DOT com
cc: cygwin AT cygwin DOT com
Subject: Re: Apache 1.3.33 on W2003 problems only on system boot
In-Reply-To: <147239341.20060830182731@gmail.com>
Message-ID: <Pine.GSO.4.63.0608301257430.20474@access1.cims.nyu.edu>
References: <78145923 DOT 20060830151248 AT ukr DOT name> <Pine DOT GSO DOT 4 DOT 63 DOT 0608301024070 DOT 20474 AT access1 DOT cims DOT nyu DOT edu> <147239341 DOT 20060830182731 AT gmail DOT com>
MIME-Version: 1.0
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

On Wed, 30 Aug 2006, ukr.name.lists wrote:

> Hello, Igor.
>
> OK, Here's long story. I'm trying to replay what I did to set
> up Apache before.
>
> Did $cygrunsrv.exe -I httpd -d "CYGWIN httpd" -p /usr/sbin/httpd -a -F
> Started service. Doesn't work. Lines in error_log:
>
> [Wed Aug 30 17:52:30 2006] [notice] Apache/1.3.33 (Cygwin) configured -- resuming normal operations
> [Wed Aug 30 17:52:30 2006] [notice] Accept mutex: pthread (Default: pthread)
> [Wed Aug 30 17:52:30 2006] [alert] (3)No such process: setuid: unable to change to uid: 1003
> [Wed Aug 30 17:52:31 2006] [alert] Child 2920 returned a Fatal error... \nApache is exiting!
>
> uid 1003 exists and my current uid. After some digging found out that
> there's some special user needed instead of SYSTEM to run such services in 2003.
>
> Decided to setup OpenSSH and use it's sshd_server user to run Apache.
>
> Executed ssh-host-config, did $cygrunsrv -S sshd, checked if sshd
> running and accepts connection - yes. Rebooted. Checked if sshd running.
> Kinda. It's still in list of running services but doesn't accept any
> connections. Messages from /var/log/sshd.log:
>       5 [main] ? (3788) E:\Cygwin\usr\sbin\sshd.exe: *** fatal error - E:\Cygwin\usr\sbin\sshd.exe: *** couldn't allocate heap, Win32 error 0, base 0x6A0000, top 0x6B0000, reserve_size 61440, allocsize 65536, page_const 4096
>       9 [main] sshd 1952 fork: child -1 - died waiting for longjmp before initialization, retry 0, exit code 0x100, errno 11
>       4 [main] ? (3960) E:\Cygwin\usr\sbin\sshd.exe: *** fatal error - E:\Cygwin\usr\sbin\sshd.exe: *** couldn't allocate heap, Win32 error 0, base 0x6A0000, top 0x6B0000, reserve_size 61440, allocsize 65536, page_const 4096
> 2754387 [main] sshd 1952 fork: child -1 - died waiting for longjmp before initialization, retry 0, exit code 0x100, errno 11
>       4 [main] ? (1684) E:\Cygwin\usr\sbin\sshd.exe: *** fatal error - E:\Cygwin\usr\sbin\sshd.exe: *** couldn't allocate heap, Win32 error 0, base 0x6A0000, top 0x6B0000, reserve_size 61440, allocsize 65536, page_const 4096
> 38433345 [main] sshd 1952 fork: child -1 - died waiting for longjmp before initialization, retry 0, exit code 0x100, errno 11
>
> Last error repeated on each connect attempt.
>
> Then did:
> $ cygrunsrv -E sshd
> $ telnet localhost 22
> Trying 127.0.0.1...
> telnet: Unable to connect to remote host: Connection refused
> $ cygrunsrv -S sshd
> $ telnet localhost 22
> Trying 127.0.0.1...
> Connected to nowhere-vi3mfi2.
> Escape character is '^]'.
> Connection closed by foreign host.
>
> Now it works. Nothing in log.
>
> I'll stop here before proceeding to Apache because it behave exactly
> the same - "couldn't allocate heap after boot", normal operation after
> restarting service.
>
> Thank you in advance !

Sergei,

The fact that the service doesn't work after system boot and then works
fine after a restart seems to suggest that it's started too early (before
some other service).  You need to discover what that service is (could be
the firewall service, or Tcp/ip, or something else) and add a dependency
to it by using the -y cygrunsrv option.  Your cygcheck output confirms
that your apache service has no dependencies.
HTH,
	Igor
-- 
				http://cs.nyu.edu/~pechtcha/
      |\      _,,,---,,_	    pechtcha AT cs DOT nyu DOT edu | igor AT watson DOT ibm DOT com
ZZZzz /,`.-'`'    -.  ;-;;,_		Igor Peshansky, Ph.D. (name changed!)
     |,4-  ) )-,_. ,\ (  `'-'		old name: Igor Pechtchanski
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

"Las! je suis sot... -Mais non, tu ne l'es pas, puisque tu t'en rends compte."
"But no -- you are no fool; you call yourself a fool, there's proof enough in
that!" -- Rostand, "Cyrano de Bergerac"

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019