autoconf
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: set owner/group on FreeBSD


From: Bill Moseley
Subject: Re: set owner/group on FreeBSD
Date: Thu, 19 Sep 2002 10:18:20 -0700

At 09:34 AM 09/19/02 -0600, Bob Proulx wrote:
>Bill Moseley <address@hidden> [2002-09-18 23:56:20 -0700]:
>> bash-2.05a$ touch /tmp/foo
>> bash-2.05a$ mv /tmp/foo .
>> mv: ./foo: set owner/group (was: 3830/0): Operation not permitted
>> bash-2.05a$ ls foo
>> foo
>
>This seems to be a problem with 'mv' on the system and autoconf is
>just suffering from that.  Can you say to the list some more
>information?  

Seems to be on all FreeBSD machines I have access to, which is three.
 FreeBSD 4.6-STABLE (2)
 FreeBSD 4.7-PRERELEASE


>Is this the FreeBSD version of mv or perhaps the GNU mv?
>'mv --version' should say something.

I assume the FreeBSD version.

$ mv --version
usage: mv [-f | -i | -n] [-v] source target
       mv [-f | -i | -n] [-v] source ... directory

>And what is '.' in the context
>above?  What is the mode of the /tmp directory?  What is the mode of
>the file you created?  Are you working on two different filesystems?

"." is on /home and /tmp is on another partition (or in another case, /home
is nfs mounted).

>The output of the following commands would be useful to see.

~ >id
uid=1357(moseley) gid=1357(moseley) groups=1357(moseley), 5006(perl),
5013(apsearch)

~ >touch /tmp/foo

~ >ls -ld /tmp/foo /tmp .
drwxr-xr-x  11 moseley  moseley  1536 Sep 18 22:58 .
drwxrwxrwt   6 root     wheel     512 Sep 19 10:13 /tmp
-rw-r--r--   1 moseley  wheel       0 Sep 19 10:13 /tmp/foo

~ >df /tmp .
Filesystem  1K-blocks     Used   Avail Capacity  Mounted on
/dev/da0s1a   3969982  3140952  511432    86%    /
/dev/da0s1e  12406325  7742378 3671441    68%    /x1

~ >mv /tmp/foo . 
mv: ./foo: set owner/group (was: 1357/0): Operation not permitted

~ >ls -l foo
-rw-r--r--  1 moseley  moseley  0 Sep 19 10:13 foo

>Those two behaviors together create a good environment to work with
>files in /tmp and elsewhere.  Which you are _not_ seeing.  'mv' will
>try to rename the file if possible.  If not possible because it is on
>two different filesystems then it will copy the file and try to set
>the new copy to the same permissions, user, group as the original
>source file.  That is the part for which you are seeing error
>messages.  Which looks really strange to see where you are seeing it.

Creating the file in /tmp is setting a guid "wheel" which I am not part of.
 So the file is copied, and then the chgrp fails.  

>It looks like you are running as root and trying to write to a NFS
>mounted filesystem.  Which of course can't work.  But the errors don't
>_quite_ say that either.

Nope, not running root.  the above case is not on the nfs mounted /home, of
course.

-- 
Bill Moseley
mailto:address@hidden




reply via email to

[Prev in Thread] Current Thread [Next in Thread]