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

Re: Avoid collisions between parallel [...], take 2

On Thu, Oct 29, 2009 at 04:17:29PM +0100, Corinna Vinschen wrote:
>On Oct 22 13:55, Corinna Vinschen wrote:
>> Ok, so, after all the discussions, this is the patch which comes
>> out of it.  [...]
>I just created the matching documentation, see below.  I hope that's
>Is there anything else which holds up the inclusion of this patch?

I haven't had time to look at the patch itself but don't let that hold up
the checkin.  I assume other people have checked it for any gotchas.

I have some wording changes below, however.


>Index: doc/new-features.sgml
>RCS file: /cvs/src/src/winsup/doc/new-features.sgml,v
>retrieving revision 1.21
>diff -u -p -r1.21 new-features.sgml
>--- doc/new-features.sgml	28 Oct 2009 10:09:54 -0000	1.21
>+++ doc/new-features.sgml	29 Oct 2009 15:15:25 -0000
>@@ -325,6 +325,14 @@
>   delete, to support the toolchain in implementing full C++ standards
>   conformance when working with shared libraries.
>+- Different Cygwin installations in different paths can be run in parallel
>+  without knowing of each other.  The path of the Cygwin DLL used in a
>+  process is a key used when creating IPC objects.  So different Cygwin
>+  DLLs are running in different namespaces.
>+- Each Cygwin DLL stores its path and installation key in the registry.
>+  This allows to troubleshoot problems which could be a result of having
    This allows troubleshooting of problems...
>+  multiple concurrent Cygwin installations.
> </screen>
> </sect2>
>Index: utils/utils.sgml
>RCS file: /cvs/src/src/winsup/utils/utils.sgml,v
>retrieving revision 1.79
>diff -u -p -r1.79 utils.sgml
>--- utils/utils.sgml	22 Jul 2009 10:20:26 -0000	1.79
>+++ utils/utils.sgml	29 Oct 2009 15:15:25 -0000
>@@ -13,13 +13,18 @@ command-line utilities support the <lite
> <sect2 id="cygcheck"><title>cygcheck</title>
> <screen>
>-Usage: cygcheck PROGRAM [ -v ] [ -h ]
>-       cygcheck -c [ PACKAGE ... ] [ -d ]
>-       cygcheck -s [ -r ] [ -v ] [ -h ]
>+Usage: cygcheck [-v] [-h] PROGRAM
>+       cygcheck -c [-d] [PACKAGE]
>+       cygcheck -s [-r] [-v] [-h]
>        cygcheck -k
>-       cygcheck -f FILE [ FILE ... ]
>-       cygcheck -l [ PACKAGE ... ]
>+       cygcheck -f FILE [FILE]...
>+       cygcheck -l [PACKAGE]...
>        cygcheck -p REGEXP
>+       cygcheck --delete-orphaned-installation-keys
>+       cygcheck --enable-unique-object-names Cygwin-DLL
>+       cygcheck --disable-unique-object-names Cygwin-DLL
>+       cygcheck --show-unique-object-names Cygwin-DLL
>+       cygcheck -h
> List system information, check installed packages, or query package database.
> At least one command option or a PROGRAM is required, as shown above.
>@@ -36,6 +41,19 @@ At least one command option or a PROGRAM
>   -l, --list-package   list contents of PACKAGE (or all packages if none given)
>   -p, --package-query  search for REGEXP in the entire package
>                        repository (requires internet connectivity)
>+  --delete-orphaned-installation-keys
>+                       Delete installation keys of old, now unused
>+                       installations from the registry.  Requires the right
>+                       to change the registry.
>+  --enable-unique-object-names Cygwin-DLL
>+  --disable-unique-object-names Cygwin-DLL
>+  --show-unique-object-names Cygwin-DLL
>+                       Enable, disable, or show the setting of the
>+                       \"unique object names\" setting in the Cygwin DLL
>+                       given as argument to this option.  The DLL path must
>+                       be given as valid Windows(!) path.
>+                       See the users guide for more information.
>+                       If you don't know what this means, don't change it.
>   -v, --verbose        produce more verbose output
>   -h, --help           annotate output with explanatory comments when given
>                        with another command, otherwise print this help
>@@ -184,6 +202,65 @@ for example:</para>
> <prompt>$</prompt> <userinput>cygcheck -s -v -r -h &gt; cygcheck_output.txt</userinput>
> </screen>
>+Each Cygwin DLL stores its path and installation key in the registry.
>+This allows to troubleshoot problems which could be a result of having
              troubleshooting of problems...
>+multiple concurrent Cygwin installations.  However, if you're experimenting
>+a lot with different Cygwin installation paths, your registry could 
>+accumulate a lot of old Cygwin installation entries for which the
>+installation doesn't exist anymore.  To get rid of these orphaned registry
>+entries, use the <command>cygcheck --delete-orphaned-installation-keys</command>
>+Each Cygwin DLL generates a key value from its installation path.  This
>+value is not only stored in the registry, it's also used to generate
>+global object names used for interprocess communication.   This allows
>+to keep different Cygwin installations separate.  Processes running
 This keeps different Cygwin installations separate.
>+under a Cygwin DLL installed in C:\cygwin don't see processes running
>+under a Cygwin DLL installed in C:\Program Files\cygwin.  This allows
>+to run multiple versions of Cygwin DLLs without these versions to
>+interfere with each other, or to run small third-party installations
>+for a specific purpose independently from a Cygwin net distribution.
>+For debugging purposes it could be desired that the various Cygwin DLLs
>+use the same key, independently from their installation paths.  If the
>+DLLs have different versions, trying to run processes under these DLLs
>+concurrently will result in error messages like this one:</para>
>+*** shared version mismatch detected - 0x8A88009C/0x75BE0074.
>+This problem is probably due to using incompatible versions of the cygwin DLL.
>+Search for cygwin1.dll using the Windows Start->Find/Search facility
>+and delete all but the most recent version.  The most recent version *should*
>+reside in x:\\cygwin\\bin, where 'x' is the drive on which you have
>+installed the cygwin distribution.  Rebooting is also suggested if you
>+are unable to find another cygwin DLL.
>+To disable the usage of a unique key value of a certain Cygwin DLL, use
>+the <command>cygcheck --disable-unique-object-names Cygwin-DLL</command>
>+command.  <literal>Cygwin-DLL</literal> is the Windows path (*not* a 
>+Cygwin POSIX path) to the DLL for which you want to disable this feature.
>+Note that you have to stop all Cygwin processes running under this DLL,
>+before you're allowed to change this setting.  For instance, run
>+<command>cygcheck</command> from a DOS command line for this purpose.</para>
>+<para>To re-enable the usage of a unique key, use the
>+<command>cygcheck --enable-unique-object-names Cygwin-DLL</command> command.
>+This option has the same characteristics as the
>+<literal>--disable-unique-object-names</literal> option</para>
>+<para>Last but not least, you can use
>+<command>cygcheck --show-unique-object-names Cygwin-DLL</command> to find out
>+if the given Cygwin DLL use unique object names or not.  In contrast to the
>+<literal>--disable-...</literal> and <literal>--enable-...</literal> options,
>+the <literal>--show-unique-object-names</literal> option also works for
>+Cygwin DLLs which are currently in use.</para>
> </sect2>
> <sect2 id="cygpath"><title>cygpath</title>

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