Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Message-ID: <17B78BDF120BD411B70100500422FC6309E4EC@IIS000> From: Bernard Dautrevaux To: "'Bleyer, Michael'" , "'cygwin AT cygwin DOT com'" Subject: RE: login account is "Administrator" not "username" Date: Mon, 18 Mar 2002 19:29:56 +0100 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2653.19) Content-Type: text/plain; charset="iso-8859-1" > -----Original Message----- > From: Bleyer, Michael [mailto:MBleyer AT DEFiNiENS DOT com] > Sent: Monday, March 18, 2002 7:13 PM > To: 'cygwin AT cygwin DOT com' > Subject: login account is "Administrator" not "username" > > > > I am logged in as user "jdoe" and have administrator rights > on a WinNT box. > I installed the most recent stable cygwin on this box (logged > in as user > "jdoe"), usable for "all". > > However, the cygwin shell tells me: > ~ $ whoami > Administrator > > and gives me the following environment variable settings: > USER=Administrator > USERNAME=jdoe If you are on NT and logged in as Domain user (not a local user) this may be related to the /etc/passwd setting. As already discussed on this list you get strange results when logged in as a Domain user if you keep th enormal /etc/passwd and /etc/group files as created initially by Cygwin. You *must* in this case be sure you have an entry for your user/group in the proper files. For that there is two solutions: 1) You have a relatively small NT Domain (less than a thousand user perhaps) and you can simply do: $ mkpasswd -d -l > /etc/passwd $ mkgroup -d -l > /etc/group This will last for a minute or so (for about 100 entries it takes less than 10 seconds) and you should be up and running. 2) You have a *huge* NT Domain; then just create the entries needed in /etc/passwd (/etc/group should be sufficiently small to be created normally): $ mkgroup -d -l > /etc/group $ mkpasswd -l > /etc/passwd $ mkpasswd -u jdoe -d >> /etc/passwd > > and consequently: > ~ $ pwd > /home/Administrator > Here you should then get your normal NT home (%HOMEDRIVE%%HOMEPATH%) > > Obviously cygwin logs me in as "Administrator" instead of "jdoe", even > though I logged in as user jdoe under WinNT > (USERNAME=jdoe in a DOS box). > Is there a way to change/avoid this? I tried installing > cygwin as "usable > only for me" but it's just the same. > I've tried the registry, FAQ and mailing list archives to no avail. > > A problem arises when I use cvs for example, as it gets my > username from the > env variable USER and all my files get checked in from user > "Administrator" > as opposed to "jdoe". I could of course hack around this, but > maybe there is > a simpler solution? > > Thanks for any help, You're welcome Bernard -------------------------------------------- Bernard Dautrevaux Microprocess Ingenierie 97 bis, rue de Colombes 92400 COURBEVOIE FRANCE Tel: +33 (0) 1 47 68 80 80 Fax: +33 (0) 1 47 88 97 85 e-mail: dautrevaux AT microprocess DOT com b DOT dautrevaux AT usa DOT net -------------------------------------------- -- 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/