delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2019/05/08/09:50:12

X-Recipient: archive-cygwin AT delorie DOT com
DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:from:subject:to:message-id:date:mime-version
:content-type:content-transfer-encoding; q=dns; s=default; b=uQg
gtwbhBNZmHrxz+lIkBXS2bbeIVoxeEoEqXV8vHPG4DkODfEctzPo4Sn7BtwQ5g9I
we21iyhZsxF8rVMqh0BoAUuGSuwfF357dA5Y857Hn/u50Jc32e30KBkncijQMnoE
jqitP0pCxVE4QJYQD8RIzlexGqoXit6jJ2CfQgUE=
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:from:subject:to:message-id:date:mime-version
:content-type:content-transfer-encoding; s=default; bh=OnV+IEiWt
Yk1aem+u6xIWOarNQY=; b=gZr7KVkzL0JgPPeP1mMO1ecwSLYdn0+tF6kg7FEmZ
gp/GNOdK0mnZmx0g7zPoUSlF3G/YUUa9YMSaHRW+1G60J4mCyLOzm5v11QnTloA2
H32KaJW8ZICK0HWj3IOBmDpo4KNeRmqqQuoip8tKGuqmxDoFU+oAKFMDJqyGsjuQ
P0=
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Authentication-Results: sourceware.org; auth=none
X-Spam-SWARE-Status: No, score=-2.0 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,RCVD_IN_JMF_BL autolearn=no version=3.3.1 spammy=2003, H*MI:online, absolutely, switched
X-HELO: mailout09.t-online.de
From: Henning <xaoxx AT t-online DOT de>
Subject: How to become root/root (0/0)
To: cygwin AT cygwin DOT com
Message-ID: <17b2ff99-3c08-e1c6-2006-40b6465d94f9@t-online.de>
Date: Wed, 8 May 2019 15:50:59 +0200
User-Agent: Mozilla/5.0 (Windows NT 6.3; rv:56.0) Gecko/20100101 Thunderbird/56.0
MIME-Version: 1.0
X-IsSubscribed: yes

In order to not be misunderstood: the question is not about executing
a single command as a priviledged user.

Instead, I'm asking how to get rid the annoying Unknown+User and
Unknown+Group  with six digits IDs permanently.

What I've tried so far:

1. put USER=root and HOME=/root
    This gave me only /root as $HOME.

2. put the USER=root and UID=0 on the starting cmdline like so
    U:\bin\mintty.exe -d -T tty1 -i /Cygwin-Terminal.ico /bin/env TTY=1 
USER=root UID=0 /bin/bash -il
    which gave me $UID=0 but not $USER=root

3. additionally set USER=root in ~/.profile
    this finally yielded $USER=root

_but_ to no avail. because echo foo > bar and then ls -{l,n} showed
that absolutely nothing had changed: USER=Unknown+User (-1) etc.
And, what's worse, an attempt to chmod user perms of ./bar was not
possible.

4. following an old thread (Nov 2003) in the cygwin-apps mailing list
    I created /etc/passwd with the line
          root::0:0:me:/root:/bin/bash
    with and without the asterisk for the empty password
    and also /etc/group with the lines
          root:S-1-5-32-544:0:
          Administrators:S-1-5-32-544:544:

    and I edited /etc/nsswitch.conf to contain
          passwd:   files	# db
          group:    files	# db
          db_enum:
          db_home:
          db_shell:
          db_gecos:

but again, to no avail. I simply can't get rid of the Unknowen+User
stuff. (And I am unable to change the user bits of permissions.)

I forgot to mention that my Windows user name is root, and I am the
only user, that is, administrator, group administrators. And I have
switched off UAC (registry) in order to avoid constant annoyances
regarding permissions.

What do I have to do, to get root (user and group).

... slightly desparate.

Henning

N.B. My cygwin installation is up to date. Windows 8.1
I have been using Linux for nearly 25 years (since kernel 1.2/3) and
cygwin since 2002. So this is not my first cygwin experience, but my
worst up to now.

Henning





--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019