From owner-freebsd-questions Fri Feb 2 17: 2:25 2001 Delivered-To: freebsd-questions@freebsd.org Received: from mail.thpoon.com (cr103675-a.bloor1.on.wave.home.com [24.42.106.79]) by hub.freebsd.org (Postfix) with SMTP id BB03A37B401 for ; Fri, 2 Feb 2001 17:02:05 -0800 (PST) Received: (qmail 60901 invoked from network); 3 Feb 2001 01:02:04 -0000 Received: from unknown (HELO tea.thpoon.com) (mail@192.168.1.2) by cr103675-a.bloor1.on.wave.home.com with SMTP; 3 Feb 2001 01:02:04 -0000 Received: from antipode by tea.thpoon.com with local (Exim 3.12 #1 (Debian)) id 14Or5Y-0006xM-00; Fri, 02 Feb 2001 20:02:04 -0500 To: cjclark@alum.mit.edu Cc: freebsd-questions@FreeBSD.ORG Subject: Re: Change group ID in a shell script References: <87vgqteb00.fsf@tea.thpoon.com> <20010202004144.A30084@dell.dannyland.org> <87r91hea7x.fsf@tea.thpoon.com> <20010202005517.B307@dell.dannyland.org> <87lmrpe7kv.fsf@tea.thpoon.com> <20010202160421.W91447@rfx-216-196-73-168.users.reflex> X-Face: 0=A/O5-+sE[Tf%X>rYr?Y5LD4,:^'jaJ!4jC&UR*ZrrK2>^`g22Qeb]!:d;}2YJ|Hq"LHdF OX`jWX|AT-WVFQ(TPhFVak)0nt$aEdlOq=1~D,:\z5QlVOrZ2(H,mKg=Xr|'VlHA="r From: Arcady Genkin Date: 02 Feb 2001 20:02:04 -0500 In-Reply-To: <20010202160421.W91447@rfx-216-196-73-168.users.reflex> Message-ID: <877l38efzn.fsf@tea.thpoon.com> Lines: 24 User-Agent: Gnus/5.0808 (Gnus v5.8.8) XEmacs/21.1 (Channel Islands) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG "Crist J. Clark" writes: > > I solved the problem by writing a Perl script instead of a shell > > script (using Perl's `setpgrp'). I would still like to know how I > > could do that in a shell script, though. > > It does not seem like it would matter for your purposes. The group ID > of a newly created file has nothing to do with the group of the user > creating it (aside from possibly giving permissions to write the > file) on a BSD system. Ooops, you are right. Then I haven't solved the problem (I only tested the script on the Solaris side until I read your message). In this case, let me rephrase the question into two: 1. How do I change process's user group in a shell script? 2. How do I make sure files are created with a certain group ownership in a shell script? Thanks, -- Arcady Genkin Nostalgia isn't what it used to be. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message