From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1NKQVJ-0001x2-7o for garchives@archives.gentoo.org; Tue, 15 Dec 2009 06:03:29 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 2C9F2E0A00 for ; Tue, 15 Dec 2009 06:03:20 +0000 (UTC) Received: from ey-out-1920.google.com (ey-out-1920.google.com [74.125.78.145]) by pigeon.gentoo.org (Postfix) with ESMTP id 3CE67E0953 for ; Tue, 15 Dec 2009 04:55:15 +0000 (UTC) Received: by ey-out-1920.google.com with SMTP id 3so887780eyh.40 for ; Mon, 14 Dec 2009 20:55:14 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:subject:date :user-agent:cc:references:in-reply-to:mime-version:content-type :content-transfer-encoding:message-id; bh=dpVnyH2+VeckHYkwPS5Pi4c+A6Uf55d9ukUUD1MfPMU=; b=rwtTng6N8svtnAyv2y4AxSpfOu4oj5/ZUP6YCbPeBY9d7gd+sJDnE5Vtcoc0yKqA7V fulK/PSVAvj2ghR/nyBjW1baFZ47uORz+Ns1nnvlIFK3hCTnjwbjSC5EMlL/3of6f02V RHUduRKGaQIeVmkxX7KxMnVLCk3pts6PBbMfI= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:subject:date:user-agent:cc:references:in-reply-to :mime-version:content-type:content-transfer-encoding:message-id; b=FBu8Oe0eXfT2OEhbqNNbIO0vF1SFWpH0F9wd+pHv5jsi60atZMIGeRGLrGrazakCs6 FZTJFCcI8BouS2eTvCkin1RnqJaQclYO45dMlE4Q/3DGaB0NDJywBC3Atd50L913/lkS 10tJPGoGSqhZbaeCHokszt8kkFwWNDXsi4X5k= Received: by 10.213.100.156 with SMTP id y28mr552079ebn.68.1260852914671; Mon, 14 Dec 2009 20:55:14 -0800 (PST) Received: from nazgul.localnet ([196.210.202.184]) by mx.google.com with ESMTPS id 13sm3484115ewy.1.2009.12.14.20.55.13 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 14 Dec 2009 20:55:13 -0800 (PST) From: Alan McKinnon To: gentoo-user@lists.gentoo.org Subject: Re: [gentoo-user] Emerge with --root option : users not created Date: Mon, 14 Dec 2009 22:41:22 +0200 User-Agent: KMail/1.12.4 (Linux/2.6.31-zen9; KDE/4.3.4; x86_64; ; ) Cc: Shinkan References: <166af1cf0912140502o35adb412i9b5517723448dfb8@mail.gmail.com> In-Reply-To: <166af1cf0912140502o35adb412i9b5517723448dfb8@mail.gmail.com> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-user@lists.gentoo.org Reply-to: gentoo-user@lists.gentoo.org MIME-Version: 1.0 Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <200912142241.22116.alan.mckinnon@gmail.com> X-Archives-Salt: 0212067c-8d16-4310-b0a8-29ede7107710 X-Archives-Hash: 0a4be41cf5321f904fbb173f7dfbe3fe On Monday 14 December 2009 15:02:22 Shinkan wrote: > Hi everyone, > > I wanted to submit this as a bug on bugzilla, but I must be sure there is > nothing that I miss. > > Let's say I have a /target dir. > If I do 'emerge --root=/target ' (cross-emerge), and that > is supposed to create users (like vixie-cron, clamav or many > others), users are not created on /target. I can verify that by chrooting > on /target and making something that requires this user (such as launching > clamd for clamav), or simply by looking at /target/etc/passwd to see that > there's no expected users. > > Am I missing somethings or is this really a bug ? What you are trying to do makes no sense. You are either cross-compiling for chroot-type purposes or cross-compiling for a different machine and arch. If it's the former, you do not need or want an /etc/passwd in the chroot - you start such things with the EUID of the intended user from the starts. If it's for another machine, what good will a passwd file be? What are you going to do with it? You certainly can't copy it to the target intact, you can't cat and append it to the passwd file on the target host, in fact you cannot make any assumptions about the target at all, not even that a passwd file is present there. The only thing you can do in that case is write an installer script that takes you tar.bz2, unpacks it on the target and then checks the status there and runs useradd as necessary depending on what it finds. -- alan dot mckinnon at gmail dot com