[GRASS-user] Disabling some safety checks in grass 6.3?

Glynn Clements glynn at gclements.plus.com
Fri Sep 15 01:38:50 EDT 2006

Jonathan Greenberg wrote:

> Understanding the risks, how do I disable the following security checks:
> 1) Concurrent use of a single grass mapset
> "[username] is currently running GRASS in selected mapset. Concurrent use
> not allowed."

Remove this part from $GISBASE/etc/Init.sh

	# Check for concurrent use
	"$ETC/lock" "$lockfile" $$
	case $? in
	    0) ;;
	    	echo $USER is currently running GRASS in selected mapset. Concurrent use not allowed.
	    	rm -rf "$tmp"  # remove session files from tmpdir
	    	exit 1 ;;
	    	echo Unable to properly access "$lockfile"
	    	echo Please notify system personel.
	    	exit 1 ;;

> Along these lines, if I'm careful to only be READING from (possibly) the
> same files (e.g. I'm not writing to the same file), should I be more or less
> "safe"?

Yes. However, apart from ensuring that multiple processes don't write
to the same map, you also need to ensure that you don't attempt
concurrent writes (or read+write) on certain fixed files, e.g. the
WIND file, $GISRC, monitor sockets etc.

Using multiple sessions will eliminate the issues with $GISRC and
monitor sockets. You can eliminate potential issues with the WIND file
by creating a named region for each session and manually setting the
WIND_OVERRIDE environment variable to the name of the region.

Glynn Clements <glynn at gclements.plus.com>

More information about the grass-user mailing list