[PLUG] Permissions problem

Rogan Creswick creswick at gmail.com
Fri Mar 15 16:19:11 UTC 2013


On Fri, Mar 15, 2013 at 8:59 AM, John Jason Jordan <johnxj at comcast.net>wrote:

>
> The permissions for all folders and files on the disk are drwxr-xr-x. I
> could try chown again, but I am wondering if I messed up when I did
> that on the other computer. I am jjj:jjj on both computers. There is
> also a 2 GB SD card mounted on the laptop  (0123-4567), and from the
> command line I get:
>

I /think/ I know what's going on, but bear with me for a bit of background
first.

The user name "jjj" and group name "jjj" are not really related to the
permissions on the drive.  They're really just convenient aliases for uid
and gid's, which are the numbers you see on the machine where the drive
isn't working.

When you run ls -la, the current computer looks up the numbers (probably in
/usr/passwd and /usr/group, or something similar) and if there are entries
in there, then it prints the name (eg: jjj) instead of the number.

Now, it looks like your desktop computer has "jjj" associated with uid
1000, and gid 1000, but your laptop has jjj associated with a different uid
/ gid pair. (strictly speaking the uid and gid are mapped to *different*
"jjj" names, but that doesn't really matter for this situation).

You could probably make this problem go away by setting the same UID / GID
for jjj on each computer (eg: changing the laptop to map jjj to 1000 for
uid / gid).

*However* that is much easier said than done.  Someone else on here may
know a way to go about that, but the thought makes me nervous. In ye good
olde days of Linux, you could "just" make sure the new ID on your
(1000,1000) is unused (but, it probably is /not/ unused), and then change
all the permissions from jjj:jjj to 1000:1000 (and all permutations, since
the user may own things the group doesn't and etc...).

Now, I'm not so certain it's that simple.  I don't trust the close coupling
between applications, interfaces, settings daemons, etc... to treat the
linux permissions system as a black box.  There may well be UID/GIDs tucked
away in other locations now.

--Rogan


>
> [jjj at Devil8 media]$ ls -la
> total 12
> drwxr-xr-x   4 root root  100 Mar 15 08:20 .
> drwxr-xr-x. 30 root root 4096 Nov 17 08:00 ..
> drwx------   3 jjj  jjj  4096 Dec 31  1969 0123-4567
> -rw-------   1 root root    0 Mar 13 20:05 .hal-mtab-lock
> drwxr-xr-x  10 1000 1000 4096 Mar 14 22:43 Movies
>
> Clearly the permissions for the 2 GB SD card (which works as expected)
> and the 3 TB USB drive are different, which must be the source of the
> problem. What I can't figure out is what "10 1000 1000" means on the
> Movies drive or how to get chown (or chmod?) to change the permissions
> on it to match the 0123-4567 drive. I read the man pages for chown and
> chmod and now I'm more confused than before.
>
> Suggestions?
> _______________________________________________
> PLUG mailing list
> PLUG at lists.pdxlinux.org
> http://lists.pdxlinux.org/mailman/listinfo/plug
>



More information about the PLUG mailing list