Hi Steve,

> I want a directory for files shared between users on the same machine
> (music, photos etc.).  Is there a convention for where that should be?

No.  I use /home so users files are still under /home even if they're
shared, e.g. /home/joint, or /home/lab.

> Should I be using NFS (bear in mind it's all on one machine), or is it
> easiest just to make a directory and assign users to a group?

The latter.  If you set the group ID bit on the directory then items
created in the directory will inherit the same group, and
sub-directories will also initially have the bit set.

    $ id
    uid=1000(ralph) gid=1000(ralph) groups=4(adm),20(dialout),24(cdrom),
    25(floppy),29(audio),30(dip),44(video),46(plugdev),100(users),
    107(lpadmin),108(scanner),109(admin),1000(ralph),1002(geneweb)
    $ mkdir shared
    $ ls -ld shared
    drwxr-xr-x  2 ralph ralph 4096 2006-09-17 11:03 shared
    $ chgrp users shared
    $ chmod g+sw shared
    $ ls -ld shared
    drwxrwsr-x  2 ralph users 4096 2006-09-17 11:03 shared
    $ cd shared
    $ touch foo; mkdir bar
    $ ls -la
    total 16
    drwxrwsr-x   3 ralph users 4096 2006-09-17 11:04 .
    drwxrwxrwt  10 root  root  8192 2006-09-17 11:04 ..
    drwxr-sr-x   2 ralph users 4096 2006-09-17 11:04 bar
    -rw-r--r--   1 ralph users    0 2006-09-17 11:04 foo
    $

Cheers,


Ralph.



-- 
ubuntu-uk mailing list
ubuntu-uk@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-uk

Reply via email to