lkml.org 
[lkml]   [2004]   [Aug]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: Effect of deleting executables of running programs
On Wed, Aug 18, 2004 at 11:16:46AM -0700, Shriram R wrote:
> a) I always thought that once a job is running, the
> executable is entirely loaded into memory and the
> abcd.out file is no longer needed.
> If so, then why does the a running job crash on
> deleting abcd.out ?

No, programs sections are paged in as needed, so the
parts that are not running may not be in memory.

That said, the Unix way of dealing with files is by
reference counting. This means that you can open a
file and delete it, and it is still kept around on
the disk until you close it (running a program counts
as having its file open). So you are susposed to be
able to delete a program and running instances will not
be affected.

Unfortunatly, as you have discovered, NFS is kinda
sorta almost like a Unix file system, but not really.
You can NOT reliably access deleted files over NFS.
This is the root of what is causing your bus errors.

> b) To what extent can I trust that the rest of the 6-7
> jobs that are running have not been affected by this
> deletion of "abcd.out" ?

They are probably OK.

Thanks,

Jim
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 14:05    [W:0.314 / U:0.012 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site