Hello, I would like to make sure that I understand how locking works in Lustre. The OSTs maintain the locks for all of the objects they control, so in this respect it is a distributed locking system. However, to perform the higher-level locking services (e.g., giving a lock on the entire file to the first requestor) it would seem to require a centralized lock server, unless all of the locks from all of the OSTs are acquired. So my question is whether clients talk to a central lock server to acquire the locks, and, if so, how are the locking services divided between a central server and the OSTs? Many thanks! Phil Dickens
On Jul 13, 2007 14:44 -0400, Phil Dickens wrote:> I would like to make sure that I understand how locking works > in Lustre. The OSTs maintain the locks for all of the objects > they control, so in this respect it is a distributed locking > system. However, to perform the higher-level locking services > (e.g., giving a lock on the entire file to the first requestor) > it would seem to require a centralized lock server, unless all > of the locks from all of the OSTs are acquired. > > So my question is whether clients talk to a central lock server > to acquire the locks, and, if so, how are the locking services > divided between a central server and the OSTs?The file striping is determined the first time a file is opened, so every client that opens the file will know which OSTs to ask for locks on a given file. There is no central lock server for file extent locks. Cheers, Andreas -- Andreas Dilger Principal Software Engineer Cluster File Systems, Inc.
Phil Dickens wrote:> > Hello, > > I would like to make sure that I understand how locking works > in Lustre. The OSTs maintain the locks for all of the objects > they control, so in this respect it is a distributed locking > system. However, to perform the higher-level locking services > (e.g., giving a lock on the entire file to the first requestor) > it would seem to require a centralized lock server, unless all > of the locks from all of the OSTs are acquired. > > So my question is whether clients talk to a central lock server > to acquire the locks, and, if so, how are the locking services > divided between a central server and the OSTs?Hopefully you can see this: http://clusterfs-intra.com/cfscom/faq-io.html#9
Hi Nathan, I have read the FAQ. However, I still have two questions: 1) in the case ofan extent lock that spans multiple OSTs, does theclient talk to all of the OSTs in the extent and acquire each of their locks? 2) The Lustre data sheet says that in the case of nodes sharing files each get the largest locks that will allow all of them to continue to write at their max speed. This suggests a higher-level locking mechanism that acquires locks on the clients behalf. Is this true? If not, what am I missing here? Many thanks!! Phil Dickens On Fri, 20 Jul 2007, Nathaniel Rutman wrote:> Phil Dickens wrote: >> >> Hello, >> >> I would like to make sure that I understand how locking works >> in Lustre. The OSTs maintain the locks for all of the objects >> they control, so in this respect it is a distributed locking >> system. However, to perform the higher-level locking services >> (e.g., giving a lock on the entire file to the first requestor) >> it would seem to require a centralized lock server, unless all >> of the locks from all of the OSTs are acquired. >> >> So my question is whether clients talk to a central lock server >> to acquire the locks, and, if so, how are the locking services >> divided between a central server and the OSTs? > Hopefully you can see this: > http://clusterfs-intra.com/cfscom/faq-io.html#9 >