Re: Running Process + Disk Image

From: Valentin Nechayev (netch@segfault.kiev.ua)
Date: 04/06/03


From: Valentin Nechayev <netch@segfault.kiev.ua>
Date: Sun, 6 Apr 2003 08:21:01 +0300


>>> Jim wrote:

J> Can anyone tell me how it might be possible for a
J> process to write() to it's Own disk image.
J> When I try to do this open (fd, O_RDWR | O_SYNC | O_APPEND)
J> returns an EXTBSY error, basically telling me that the running
J> process can't write to it's Own image because it's tied up.
J>
J> I want to be able to have the process update it's own disk image
J> each time it's run, i.e, read in some data, parse for a struct,
J> then ++var a member, and write the image back to disk!

It is Vary Bad Style (tm)

Use data file separated from your binary.

-netch-