From owner-freebsd-current@FreeBSD.ORG Sun Mar 9 23:43:02 2014 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id EB3A4D79 for ; Sun, 9 Mar 2014 23:43:02 +0000 (UTC) Received: from mail-la0-x22c.google.com (mail-la0-x22c.google.com [IPv6:2a00:1450:4010:c03::22c]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 7473D3A7 for ; Sun, 9 Mar 2014 23:43:02 +0000 (UTC) Received: by mail-la0-f44.google.com with SMTP id hr13so4251574lab.3 for ; Sun, 09 Mar 2014 16:43:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; bh=a+dmcarbLl7+Ls0SpGAzUe1/v4XK7SBffGJUyKiBoNE=; b=FpNflUFONI7zc5SMVYCCDjPEGy/WM7zJmVA4FzKsuMAX08u6lEbHRRUyPLHtKvn5Ti 5efS4ltL0N9ajfi7yW7CSZAkC5IulEVjohdSO2mYug0+5hWXZl5VNQkP/x9RpsdQeaou P8ayciuPid8J5eIpZssv+/fuW/hNP5sM4kL/Bt5j+GzlaUSGgVOGxus8BTKJOq2GvjBj idYN4bpQ2FEWHO1GbL54LXgDjHBJ1yKzcNeQNuGsiQaE/kNeWmB17RvsTDQJx35MhgSP OFOqNzCT6Fd4mVdzs1jtvCaXfHVDwe8DI6bpqzh9v37rJEILazShjrwCXeAE0urEhss4 2geg== MIME-Version: 1.0 X-Received: by 10.112.172.198 with SMTP id be6mr20213574lbc.5.1394408580501; Sun, 09 Mar 2014 16:43:00 -0700 (PDT) Received: by 10.112.129.164 with HTTP; Sun, 9 Mar 2014 16:43:00 -0700 (PDT) In-Reply-To: References: Date: Sun, 9 Mar 2014 23:43:00 +0000 Message-ID: Subject: Re: Error when adding user with multiple groups with bsdconfig From: Tom Evans To: "Lundberg, Johannes" Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Cc: FreeBSD Current X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 09 Mar 2014 23:43:03 -0000 On Fri, Jan 10, 2014 at 12:37 AM, Lundberg, Johannes wrote: > Hi > > I'm on 11-CURRENT amd64. I wanted to add a user using "bsdconfig" but got > an error when adding to several groups. > > Error message: > ERROR!: pw > pw: group `wheel daemon operator dialer network` does not exist. > > Creating a user who is only added to one group (for example wheel) works > fine. > > I have submitted a PR. What command line did you use? A user can only have one primary group (-g), but can be in multiple groups (-G). -g group Set the account's primary group to the given group. gro= up may be defined by either its name or group number. -G grouplist Set additional group memberships for an account. groupl= ist is a comma, space or tab-separated list of group names or group numbers. The user's name is added to the group lists in /etc/group, and removed from any groups not specified in grouplist. Note: a user should not be added to their pri=E2=80= =90 mary group with grouplist. Also, group membership changes do not take effect for current user login sessions, requir=E2=80= =90 ing the user to reconnect to be affected by the changes. Cheers Tom