[GRASS-dev] Re: [GRASS GIS] #446: put user and machine name into
.gislock file
GRASS GIS
trac at osgeo.org
Wed Jan 21 07:56:43 EST 2009
#446: put user and machine name into .gislock file
--------------------------+-------------------------------------------------
Reporter: benducke | Owner: grass-dev at lists.osgeo.org
Type: enhancement | Status: new
Priority: minor | Milestone: 6.4.0
Component: default | Version: svn-trunk
Resolution: | Keywords: locking, .gislock
Platform: All | Cpu: Unspecified
--------------------------+-------------------------------------------------
Comment (by glynn):
Replying to [ticket:446 benducke]:
> If a .gislock file gets created for a user, then it might be a good idea
to store that user's current login name and machine name in the file. That
way, external GUIs that encounter a lockfile when trying to log a user
into a mapset will be able to output a more specific error message,
including the lockfile creator's identity, giving the user a better clue
as to whether the lockfile can be safely deleted or not.
The machine name should go into the file. At present, etc/lock reads the
PID and checks whether the process is still running. Obviously, this only
works if the creator process is running on the same system as the checking
process.
Also, the current format is an "int" in the platform's native format, so
you can't even report the PID correctly if it was written using a
different byte order (or sizeof(int)).
lib/init/lock.c should at least check that PID is positive before checking
for existence.
> Not sure what version of GRASS this could go into, but it seems to me it
would not affect any of the current functionality(?).
It can't go into 6.x, as existing versions of GRASS won't understand the
new format, and in the case where the database is shared via NFS, you
can't assume that all systems are using the same version of GRASS.
--
Ticket URL: <http://trac.osgeo.org/grass/ticket/446#comment:2>
GRASS GIS <http://grass.osgeo.org>
More information about the grass-dev
mailing list