From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <5d457b13215e1d6e20e08f2858df07a2@swtch.com> To: 9fans@cse.psu.edu Subject: Re: [9fans] ORCLOSE From: "Russ Cox" Date: Mon, 3 Apr 2006 20:08:58 -0500 In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Topicbox-Message-UUID: 2e3c96f2-ead1-11e9-9d60-3106f5b1d025 > that's often not a reliable sign. networks go down. dhcp and > ppp may reassign addresses. Sorry. 9P does not address such concerns. There is no notion of re-establishing a connection. If your connection is dropped, your ORCLOSE files get removed, all your other files get closed (including lock files, making them available for use by others). If you are concerned about keeping a single 9P session across multiple network instances, you can use a 9P filter like aan or recover. Aan just sits on top of any network connection, allowing special clients and servers to reconnect and pick up where they left off. Neither side knows that the connection got lost. Recover is a client-only solution. A program runs on the client that keeps track of the fids the client is using. If the connection is lost, then recover redials and reestablishes the fid state as needed. It handles ORCLOSE specially: it strips that bit out of the open mode and turns Tclunks on previously-ORCLOSE fids into Tremoves. It also refuses to reopen exclusive-use files. Recover is not in the distribution yet. I wrote it for the old 9P and revised it for 9P2000 but never quite finished it. Gorka finished it and tested it last summer but I haven't gotten around to putting it in. So for now it's ozinferno^Wvapor-ware. Sorry. Russ