From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mr4.vodafonemail.de (mr4.vodafonemail.de [145.253.228.164]) by sourceware.org (Postfix) with ESMTPS id 518203858281 for ; Thu, 23 Nov 2023 18:40:52 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 518203858281 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=nexgo.de Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=nexgo.de ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 518203858281 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=145.253.228.164 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1700764854; cv=none; b=D0AKJSM3nYDJTiY6i+0MjHQJr6V51gy0w3EyoPJObaCO1ioz5xSCVi7v8fbbQTOk9GRldVasQlT4Va2x4FJ1mRr+mAoHkQBb2UKEEIdQ4ED9gjPyhNNf8QaEQxLb0eclmnPSJ6I37KoUO1c2X+8E6qBCoksqW6Npczhj1/lRwN0= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1700764854; c=relaxed/simple; bh=G7YV7GQcwKqpk2EcyeNLpaRsyePjKgt9dS0LwomCkyk=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=LrtVluhzWrED1P1VVTVzjd39UCDxZYVX6z8b0kg3wjzv04RUwMCskJTOjDqn7TeDXBuoWscRPLEdztkZ2BatHD9t2LCE5OFwTUymjZxyN7tX+WscRKxqocNcvXoDVawAZyps5T36ZFIcmnPoP7daY4XkSYE5wasyFYEWmxhTlXQ= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nexgo.de; s=vfde-mb-mr2-23sep; t=1700764850; bh=kuPHMv1ERAzBpVFDPyChk8q1E9F4kQM1eYctupgqt3Y=; h=From:To:Subject:In-Reply-To:References:Date:Message-ID:User-Agent: Content-Type:From; b=gMgbSS4+fyuYekkMEoZi5WEv0wESsuNXRjlU+EmS2yyC14M5jBY9O71W7Ke7woRxW vXXFwDrqhsbh4PhegtxoduUTxTOjzAD97HuBLp1rtJxju8/6D0b+TpIOcsbRN6N2AA uXLtoixNKBV6GHye8yfuXoBMpaIwartcge3Ii1u0= Received: from smtp.vodafone.de (unknown [10.0.0.2]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by mr4.vodafonemail.de (Postfix) with ESMTPS id 4Sbn4L0RwNz1xyK for ; Thu, 23 Nov 2023 18:40:50 +0000 (UTC) Received: from Gerda (p5b2f3d59.dip0.t-ipconnect.de [91.47.61.89]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (prime256v1) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp.vodafone.de (Postfix) with ESMTPSA id 4Sbn4F5z7GzHnfp for ; Thu, 23 Nov 2023 18:40:42 +0000 (UTC) From: ASSI To: cygwin@cygwin.com Subject: Re: Capturing a Cygwin instance from another PC In-Reply-To: (Jose Isaias Cabrera via Cygwin's message of "Wed, 22 Nov 2023 14:53:11 +0000") References: Date: Thu, 23 Nov 2023 19:40:38 +0100 Message-ID: <87o7fkmhy1.fsf@Gerda.invalid> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-purgate-type: clean X-purgate: clean X-purgate-size: 2295 X-purgate-ID: 155817::1700764845-DFFFA94E-2732FAA3/0/0 X-Spam-Status: No, score=-3030.6 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS,TXREP,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: Jose Isaias Cabrera via Cygwin writes: > I have a new Win11 PC, and I wanted to capture the same Cygwin setup > that I have in another Win10 PC. I copied the C:\cygwin64 folder from > the Win10 pc to the Win11 pc, This doesn't really work unless both machines are domain joined and all SID for the installation are identical on both machines plus you'd need to ensure that symlinks and stuff make it to the new machine unharmed. It's actually easier to re-install from scratch and don't worry about all those things. > then I downloaded a fresh > setup-x86_64.exe from cygwin.com to the win11 PC. I ran it and chose > "Install from Local Directory" and only one shortcut for "Cygwin64 > Terminal" was created on the desktop. No Cygwin nor Cygwin-X folders > were created on the Start menu. The original cygwin from the Win10 PC > had X installed also. > > Any idea how to get this done automatically? I know I can go and > create folders manually, etc., but it kind of a pain. Any help would > be greatly appreciated. Thanks. Do a base install on the new machine, then copy over the /etc/setup/installed.db from the old machine. Then reset all the version/release numbers in that file to zero: sed -re 's/^(.+) (\1)-[0-9].+(\.bz2)/\1 \1-0-0\3/' -i.bak /etc/setup/installed.db Close the Cygwin shell and run setup again and it will re-install everything you've had installed on your old machine, thus ensuring that all postinstall scripts will execute in the correct order. If you've changed any system-wide configuration files like /etc/nsswitch.conf or /etc/fstab, compare those to the new files just installed and decide which version to keep. Take note if you've used the "desc" schema for user mapping and re-apply those to the SAM for local accounts. If you've had an SSH server running on the old machine you will of course need to create new host keys and install the services, again that's easier to do from scratch IMHO. Once the system is set up to your satisfaction, copy any home directories you want to keep on the new machine. Regards, Achim. -- +<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+ SD adaptation for Waldorf rackAttack V1.04R1: http://Synth.Stromeko.net/Downloads.html#WaldorfSDada