Path: utzoo!mnetor!uunet!husc6!bbn!rochester!udel!mmdf From: blank%ucscd.UCSC.EDU@ucscc.ucsc.edu (John Weber) Newsgroups: comp.os.minix Subject: Re: sharing text on exec Message-ID: <1670@louie.udel.EDU> Date: 21 Mar 88 23:33:29 GMT Sender: mmdf@udel.EDU Lines: 36 Marty writes: > I'm looking into a mechanism for sharing text on exec on Minix. > It's relatively straightforward to save the inode/device for each execed file. > Except short of leaving the file open (i.e. one file descriptor per execed > process) how do you prohibit the file system from writing over that file? > Any other good ways to uniquely identify files and be able to correctly identify > whether the previously execed file is inconsistent with what is currently on > disk? > marty > ARPA: leisner.henr@xerox.com > GV: leisner.henr > NS: martin leisner:henr801c:xerox > UUCP: nsc!nscimg!amps!marty > Seems to me that the simplest solution is to add a flag in the in core inode, i_incore, and set or reset it as necessary. The click offset of the beginning of the text segment could also be stored in the incore inode. This would solve both the "text busy" problem, and the location problem. +-----------------+-----------------------------------------------+ |',',',',','###_|'| John Weber, "Hey, what do I know? I just | |',',',','###_|','| work here..." | |',',','###_|','##| UUCP: ...!ucbvax!ucscc!ucscd!blank | |',','###_|','####| or !ucscc!ucscb!blank | |','###_|','######| ARPA: blank@ucscb.ucsc.edu | |'###_|','########| blank@ucscd.ucsc.edu | |##_|','##########| BITNET: blank%ucscd.BITNET | |_|','############| | +-----------------+-----------------------------------------------+