From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17579 invoked by alias); 7 Dec 2017 15:03:50 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 17568 invoked by uid 89); 7 Dec 2017 15:03:50 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-100.3 required=5.0 tests=AWL,BAYES_00,GOOD_FROM_CORINNA_CYGWIN,KAM_LAZY_DOMAIN_SECURITY,RCVD_IN_BRBL_LASTEXT,RCVD_IN_DNSWL_LOW,SPF_HELO_PASS autolearn=ham version=3.3.2 spammy= X-HELO: drew.franken.de Received: from mail-n.franken.de (HELO drew.franken.de) (193.175.24.27) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 07 Dec 2017 15:03:38 +0000 Received: from aqua.hirmke.de (aquarius.franken.de [193.175.24.89]) (Authenticated sender: aquarius) by mail-n.franken.de (Postfix) with ESMTPSA id 956CB721E281E for ; Thu, 7 Dec 2017 16:03:35 +0100 (CET) Received: from calimero.vinschen.de (calimero.vinschen.de [192.168.129.6]) by aqua.hirmke.de (Postfix) with ESMTP id 567545E03A0 for ; Thu, 7 Dec 2017 16:03:35 +0100 (CET) Received: by calimero.vinschen.de (Postfix, from userid 500) id 754A6A806C6; Thu, 7 Dec 2017 16:03:35 +0100 (CET) Date: Thu, 07 Dec 2017 16:43:00 -0000 From: Corinna Vinschen To: cygwin@cygwin.com Subject: Re: How to handle changed user ID Message-ID: <20171207150335.GB10123@calimero.vinschen.de> Reply-To: cygwin@cygwin.com Mail-Followup-To: cygwin@cygwin.com References: <03c139ef-2ef9-e4bb-e8d8-11e8a1e00e9c@towo.net> <7b97953c-8df0-6a7b-6740-6bbed1fd744c@gmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="E39vaYmALEf/7YXx" Content-Disposition: inline In-Reply-To: <7b97953c-8df0-6a7b-6740-6bbed1fd744c@gmail.com> User-Agent: Mutt/1.9.1 (2017-09-22) X-SW-Source: 2017-12/txt/msg00055.txt.bz2 --E39vaYmALEf/7YXx Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-length: 1272 On Dec 7 09:12, cyg Simple wrote: > On 12/7/2017 2:50 AM, Thomas Wolff wrote: > > I had to delete a corrupted Windows account and recreate it. > > For cygwin, the new account, although with the same name, has a > > different user id. > > Of course, this creates access problems for existing files (even if they > > appear to have the same user in ls -l, because the *old user* is still > > listed in /etc/passwd). > > Is there a canonical solution to this problem, other than running chown > > -R $USER ~ ? > > Can the new user be forced to use the previous user ID? >=20 > What happens if you simply remove /etc/passwd and /etc/group files? A > change long ago caused these files to not be needed. >=20 > You may need to take ownership of the directories and their files at the > Windows system level. Definitely, and this is independent of Cygwin. The files have been created with the Windows SID of the old user and thus the ownership is still set to the old user. Either taking ownership in Windows, or starting a shell as admin and using chown -R (or more intelligent variations using find) should do it. Corinna --=20 Corinna Vinschen Please, send mails regarding Cygwin to Cygwin Maintainer cygwin AT cygwin DOT com Red Hat --E39vaYmALEf/7YXx Content-Type: application/pgp-signature; name="signature.asc" Content-length: 819 -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBCAAGBQJaKVhHAAoJEPU2Bp2uRE+gfz8P/i2ZWr9Br8ImRnli9emfW9sP 8uVF+beCPVRrTLKuvvfMtzSJ53BfnwNufzcgr4BnHK2t8cJZQns2kKzizZ/OfGND sBrDI2BTkMnsNuKqpCJhFQAGePnpNf32kWLhLFERgE7ms/AZndR7CLnlXYbPbwum YXv+CDve0yIBsxajzMzCfC5Urb1674yNOIuhdbFNf3zLu47D0uDfj0nnZUpnrUO4 pLUV+8eAZiDLId6VOnXcovroEeeEyM253y4n8o81pmUJFCey1drAZn24Hr0ZUkad mNl2r8c/AHd3SsF5JEG71yvDDiba0algtC1vkbOwYsgwSVy1iPjrGtVHHwJZMliV gYcqK/dvXj5Srl70FOcujfhHph0dqoKzsv2lpNLBaexbhKOj4gL7SdJYuqey54SH aPwnEJBPU2+NUzh/eVMro5kyd+cnjIMAubja5fdSFT7RxvGzLb7XgxIm3EE07wWO tMamgbo07RlMuYP9gNbN3p5EobhzYAfe2Dic9nJAhif1NK5uMuWkkc/T90mh6ZbW u2I4nbGcRxj88DMhLBb+8HFFp84n1HpbwHYO5bzsvEq0K4KQsocR4N7PMhNBh93E Xhs6uzuGQwTF/YBA006Cd8HIcXsHSHRzRJBq5CtKsjgn695q+q4iG0FUOjttCTRs eV8Ppe0oBWBhuMw+pz6j =W8GH -----END PGP SIGNATURE----- --E39vaYmALEf/7YXx--