Patent attributes
Methods and apparatus for identifying consistent snapshot points for file systems in a distributed storage service in which a client may access a file system in backend storage via two or more access nodes. A snapshot coordinator initiates a two-phase commit to perform a snapshot epoch transition. The coordinator sends prepare messages to the nodes. In response, a node sends a response to the coordinator, stops issuing writes to the file system, sets a timer, and waits for a commit message. Upon receiving a response from all nodes, the coordinator sends a commit message. Upon receiving the commit or the timer expiring, the nodes increment an epoch counter and begin issuing writes to the file system tagged with the new epoch and indicating that a copy-on-write operation be performed. The transition is successful if all nodes respond to the request message; otherwise, the two-phase commit is retried.