From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: f7344,707ba86df1f88f16 X-Google-Attributes: gidf7344,public X-Google-Thread: fce85,707ba86df1f88f16 X-Google-Attributes: gidfce85,public X-Google-Thread: 1164f8,707ba86df1f88f16 X-Google-Attributes: gid1164f8,public X-Google-Thread: fc7fa,707ba86df1f88f16 X-Google-Attributes: gidfc7fa,public From: Roger Tucker Subject: Re: Require help with msync() functionality in OpenVMS Cluster env. Date: 1999/12/18 Message-ID: <385A6F18.277AE9D2@mci.com>#1/1 X-Deja-AN: 562143013 Content-Transfer-Encoding: 7bit References: <82goqs$lti@news.go.dlr.de> Content-Type: text/plain; charset=us-ascii X-Trace: pm02news 945475977 166.37.15.23 (Sat, 18 Dec 1999 00:12:57 GMT) Organization: MCIWorldcom MIME-Version: 1.0 NNTP-Posting-Date: Sat, 18 Dec 1999 00:12:57 GMT Newsgroups: vmsnet.vms-posix,comp.os.vms,comp.sys.dec,comp.sys.vms This may not answer all of your questions but maybe it will be a start. msync() calls one of the sys$updsec() system service routines (SYS$UPDSEC(), SYS$UPDSECW(), $UPDSEC_64, or SYS$UPDSEC_64W) depending on the flags argument being set to MS_ASYNC and depending on if the section is a 32 bit or 64 bit section. You can read about theses services from the system service reference manual. But they flush any modified pages out to the disk file. If you also specify MS_INVALIDATE msync() uses a VMS LOCK and lock value block to notify other nodes that the section is invalid. This is done by taking out an exclusive lock, incrementing a sequence number in the lock value block, and converting the block back to NL mode. The other processes that have the global section mapped wait on a blocking-ast. If they don't have AST's disabled they will invalidate their copy of the global section and fault it from the disk the next time they read it. Two locks are used in real-life (a door bell lock and sequence number lock) to avoid a problem of a process being hung or having AST's off. The writes/reads on each machine are not synchronised. That is up to your application, but MS_INVALIDATE will force the next read on any node to get the new data from disk. NO. That is up to your application. I hope this is enough information to help. Thanks, Roger Tucker - MCIWorldCom