Slow startup time on AD joined PCs

Brian Inglis Brian.Inglis@Shaw.ca
Mon Jun 26 14:12:21 GMT 2023


On 2023-06-26 00:15, Cristi Anichitei via Cygwin wrote:
> This has been initially reported as a Git for Windows issue:
> https://github.com/git-for-windows/git/issues/4459
> 
> But it has been tracked down to originate in the Cygwin project (see
> https://github.com/git-for-windows/git/issues/4459#issuecomment-1580526636
> and maybe
> https://github.com/git-for-windows/git/issues/4459#issuecomment-1602566700).
> 
> Using 3.4.6.1 (from
> http://mirrors.kernel.org/sourceware/cygwin/x86_64/release/cygwin/cygwin-3.4.6-1-src.tar.xz),
> running any program from /usr/bin takes at least 20 seconds, for example
> 
> $ .\ldd.exe --version
> ldd (cygwin) 3.4.6
> Print shared library dependencies
> Copyright (C) 2009 - 2023 Chris Faylor
> This is free software; see the source for copying conditions.  There is NO
> warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
> $ Measure-Command { .\ldd.exe --help }
> Days              : 0
> Hours             : 0
> Minutes           : 0
> Seconds           : 22
> Milliseconds      : 552
> Ticks             : 225529747
> TotalDays         : 0.000261029799768519
> TotalHours        : 0.00626471519444444
> TotalMinutes      : 0.375882911666667
> TotalSeconds      : 22.5529747
> TotalMilliseconds : 22552.9747
> 
> I have also tried this with 3.4.7 - same issue.
> 
> Using 3.1.7 there is no slow down. I haven't tried any versions between
> 3.1.7 and 3.4.7 yet, but I can do that.
> 
> I'm running Windows 10 21H2 (19044.3086).

https://cygwin.com/faq.html#faq.using.startup-slow

Probably slow AD server or network connection, or long group membership lists, 
that can be ameliorated by running cygserver service at system startup, so only 
the first Cygwin process takes SAM/AD access hits, which are cached thereafter, 
and shared with all Cygwin processes on the system.
Otherwise the first Cygwin process in each Cygwin process tree takes the hits, 
so if you are not running under Cygwin mintty terminal and/or Cygwin shell, 
every Cygwin process run from a Windows shell has to load all the SAM/AD info 
required to run the Cygwin process.

-- 
Take care. Thanks, Brian Inglis              Calgary, Alberta, Canada

La perfection est atteinte                   Perfection is achieved
non pas lorsqu'il n'y a plus rien à ajouter  not when there is no more to add
mais lorsqu'il n'y a plus rien à retirer     but when there is no more to cut
                                 -- Antoine de Saint-Exupéry


More information about the Cygwin mailing list