GRASS 4.0 and directory location/protection

John Miller wrote:

I have a question regarding setting up GRASS for use by multiple users
for all you experienced system managers.

...stuff deleted...

To continue, for various reasons our spearfish database is in a
different file system partition to our user's directories. When a
user creates a mapset using the spearfish database I would like the
subdirectories associated with their mapset to be created under their
own directory where they are subject to disk quota limits etc.

Can this be done?

This is how I set it up here. I created a local grass database
directory, say /grass. In that I created world writable
subdirectories 'spearfish' and 'global'. And in each of these
subdirectories I created symbolic links to the remote file-servers
GRASS database e.g.:
ln -s /remote/grass/spearfish/PERMANENT /grass/spearfish/PERMANENT

This remote filesystem can then be read-only. Also individual users
can use this setup in their own quota limited area without needing
system privileges.

--
Tschuess ...rick...
_______________________________________________________________________________
Richard Wagener |
Bldg. 426, rm. 43 | IP: wagener@bnl.gov
Environmental Chemistry Division | DEC: 44048::rwagener
Brookhaven National Laboratory | phone: 1-516-282-5886
Upton, New York 11973, U.S.A. | fax: 1-516-282-2887
_______________________________________________________________________________

We're running Sun 3s and 4s here--our solution might pertain to other
systems as well. What we do here is to have the sticky bit set for
both the database directory and the location directory, and leave them
both group/others writable and readable. In other words,

% chmod 1777 /home/grass/data # the database
% chmod 1777 /home/grass/data/spearfish # the location

Individual mapsets within a location, however, are left writable only
by the owner:

% chmod -R 755 /home/grass/data/spearfish/PERMANENT # main mapset
% chmod -R 755 /home/grass/data/spearfish/hmueller # a user's own mapset

This means that anyone can create a new location in the Grass
database, and have it protected from other users; anyone can
create a mapset within a location, and have it protected from other
users; and anyone can read (but not write) other users' files within
Grass.

Of course, if you want to deny access, then do
% chmod -R 700 /home/grass/data/spearfish
or
% chmod -R 700 /home/grass/data/spearfish/hmueller

See the manual page for chmod (in both section 1 and section 2) for
details.

Hal Mueller "Senator, you're no Paul Tsongas."
hmueller@orca.tamu.edu