Inferring and Asserting Distributed System Invariants

Author email: stewbertgrant@gmail.com
Tool name: Dinv
Description: Distributed systems are difficult to debug and understand. A key reason for this is distributed state, which is not easily accessible and must be pieced together from the states of the individual nodes in the system. We propose Dinv, an automatic approach to help developers of distributed systems uncover the runtime distributed state properties of their systems. Dinv uses static and dynamic program analyses to infer relations between variables at different nodes. For example, in a leader election algorithm, Dinv can relate the variable leader at different nodes to derive the invariant ∀ nodes i, j, leaderi = leaderj. This can increase the developer's confidence in the correctness of their system. The developer can also use Dinv to convert an inferred invariant into a distributed runtime assertion on distributed state. We applied Dinv to several popular distributed systems, such as etcd Raft, Hashicorp Serf, and Taipei-Torrent, which have between 1.7K and 144K LOC and are widely used. Dinv derived useful invariants for these systems, including invariants that capture the correctness of distributed routing strategies, leadership, and key hash distribution. We also used Dinv to assert correctness of the inferred etcd Raft invariants at runtime, using these asserts to detect injected silent bugs.
Bibtex: @inproceedings{10.1145/3180155.3180199, author = {Grant, Stewart and Cech, Hendrik and Beschastnikh, Ivan}, title = {Inferring and Asserting Distributed System Invariants}, year = {2018}, isbn = {9781450356381}, publisher = {Association for Computing Machinery}, address = {New York, NY, USA}, url = {https://doi.org/10.1145/3180155.3180199}, doi = {10.1145/3180155.3180199}, booktitle = {Proceedings of the 40th International Conference on Software Engineering}, pages = {1149–1159}, numpages = {11}, location = {Gothenburg, Sweden}, series = {ICSE ’18} }
Link to public pdf: https://dl.acm.org/doi/10.1145/3180155.3180199
Link to tool webpage: https://bitbucket.org/bestchai/dinv/
Link to demo: Not provided by authors
Category: None
Year and Conference: 2018, ICSE
Terms of use