This is the mail archive of the cygwin@cygwin.com 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]

Re: How to debug inetd/sshd services?


Did you try sshd -d -d -d? Or is it -v -v -v?
These multiple debug/verbosity flags give it further
levels of output.

Search the mail archives for posts about the SYSTEM account,
especially from Corinna Vinschen. She details the specific
limitations of the SYSTEM account running a service like sshd
or inetd. Where it works from the command line, but not as a
service, it sounds like the SYSTEM account could be involved in
your problem.

HTH,
Peter

Lassi A. Tuura wrote:

> This is to follow up on my problem where I have cygdrive prefix
> set to `/', both system and user setting, but $PATH and other
> env vars are initialised to /cygdrive/x.  This happens only when
> the process (inetd or sshd) is started as a service under the
> system account.  Under the same remote session mount reports
> the expected values (`/').  The extra /cygdrive prefixes causes
> problems with the $PATH: cygwin thinks those /cygdrive/<x>/...
> directories don't exist (which is consistent with mount output).
> 
> After some further testing:
>   - sshd -d didn't seem to print any useful information
>   - sshd started from cygwin/bash command line on my own
>     account does not have this problem
>   - I managed to get the sshd-as-service to run under strace;
>     beginning of the output is attached below.
> 
>>From the strace output, cygwin seems to happily use the /cygdrive
> prefix instead of `/'.  I am not sure how I can debug this further
> -- experts, please help.  I am happy to debug this under gdb if
> some kind soul can explain to me how do I do that in the service
> conditions...
> 
> Is there a way to get more output from strace?  Any other debugging
> ideas?  I can provide the strace outputs both with and without
> /cygdrive prefix set if someone thinks that will be useful.
> 
> Registry data:
> $ regtool -v list '\machine\SOFTWARE\Cygnus Solutions\Cygwin\mounts v2'
> /\ (Cygwin)
> /usr/bin\ (Cygwin)
> /usr/lib\ (Cygwin)
> cygdrive prefix = "/"
> cygdrive flags = 0x00000028 (40)
> $ regtool -v list '\user\SOFTWARE\Cygnus Solutions\Cygwin\mounts v2'
> cygdrive prefix = "/"
> cygdrive flags = 0x00000020 (32)
> 
> //lat
> 


-- 
-- 
Your mouse has moved.
Windows NT must be restarted for the change to take effect.
Reboot now?  [OK]

--


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


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