[GRASS-user] GRASS and reading mapsets on NTFS

Glynn Clements glynn at gclements.plus.com
Sat Jan 17 06:27:33 EST 2009


Patrick Giraudoux wrote:

> I have just migrated from a computer double boot (Windows/Ubuntu Hardy) 
> with user data on a FAT32 partition to a new one with a NTFS partition 
> instead. All went OK except that I can read mapsets only when grass 
> (6.3) is started with sudo. If not, I can access locations in the 
> grassdata folder but maptsets are not read. Googling a bit within the 
> list I understand that grass can read only with owner rights (and not 
> only read/write permission)

To be precise, it requires that you own the current mapset (where new
maps are stored). You can read data from other mapsets provided that
you have the necessary filesystem permissions.

> and this explains the difference. I agree 
> with comments that this it looks like a bit over the  top regarding 
> security (I may be wrong...).

As Hamish says, it's not a security feature; it's to prevent users
from accidentally shooting each other in the foot by trying to share a
mapset directory without fully understanding the implications.

E.g. although you can delete files which you don't own (so long as you
have write permission on the containing directory), you can't delete
directories unless they are empty, and if you don't have write
permission on a directory (and can't chmod it because you aren't the
owner), you can't empty it.

If you allow another user to write to your mapset directory, and they
don't take care to ensure that their umask gives you write permission
(or they use a command which uses e.g. 0755 instead of using 0777 and
leaving the rest to the umask), you may end up with a mapset directory
which is unusable.

> As anyone an idea about a workaround ?

Mount the filesystem with ownership set to your user account, as
suggested by Hamish.

Or remove the check from lib/gis/mapset_msc.c and re-compile.

-- 
Glynn Clements <glynn at gclements.plus.com>


More information about the grass-user mailing list