1 / 32

AutoBash: Improving Configuration Management with Operating System Causality Analysis

AutoBash is a solution for frustrating configuration management problems. It automatically tries and explains solutions, provides undo capability, and runs regression tests.

Télécharger la présentation

AutoBash: Improving Configuration Management with Operating System Causality Analysis

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. AutoBash: Improving Configuration Management with Operating System Causality Analysis Ya-Yunn Su, Mona Attariyan, and Jason Flinn University of Michigan

  2. Motivation • Configuration management is frustrating! • Users may have to • Change environment variables • Edit configuration files • Manage inter-application dependencies • Current approach: • Ask friends, search on-line, read manual, … • Try potential solutions • Carefully undo wrong solutions

  3. AutoBash solves these problems Problems with current approach • Applying solutions is time-consuming • Undoing a wrong solution can be hard • Hard to know how a problem was solved • A “solution” may cause new problems Automatically tries many solutions Provides undo capability Explains solution to user Automatically runs regression tests

  4. - ) Health Monitoring Mode - ( Periodically tests system health Least user effort Substantial user involvement Observation Mode Replay Mode Helps user fix the problem Automatically searches for a solution AutoBash overview Problem Detected

  5. Outline • Motivation • AutoBash design and implementation • Observation mode • Replay mode • Health monitoring mode • Evaluation • Conclusion

  6. Observation mode • A modified bash shell • User types in commands to solve the problem % command 1 % test if app works % undo testing % undo command 1 % command 2

  7. Verifying a solution is tedious • AutoBash automatically tests using predicates • Predicate: • Tests if an application functions correctly • Returns true/false if the test passes/fails % command 1 % test if app works % undo testing wget http://localhost/~$USER % rollback command 1 • Predicate example for a web server % command 2

  8. % command 1 % test if app works % undo testing % rollback command 1 % command 2 Undoing testing is tedious • Predicate testing has no side effects • Executed speculatively and rolled back • Speculator [SOSP ‘05] • Process-level speculative execution • Speculative execution makes predicate testing safe

  9. Undo can be hard • AutoBash speculatively executes each action • Light-weight checkpoint and rollback % command 1 % test if app works % undo testing % undo command 1 % rollback command 1 % command 2 • Speculative execution makes undo easy

  10. Predicate Database Regression testing is hard • AutoBash automatically runs regression tests • Executes predicates in the predicate database • Ensures all predicates pass CVS predicates P0 P1 P2 Web server predicates P3 P4 P5 GCC cross-compiler predicates P6 P7 P8

  11. Regression tests can be slow • Problem: running all predicates can be slow • Only need to run predicates affected by an action • Uses causality tracking to find affected predicates

  12. Tracking causality • Output set • kernel objects an action causally affects • Input set • kernel objects a predicate causally depends on Action: touch foo Output set = {file foo} Predicate: grep “test” bar Input set = {file bar}

  13. Analyzing causality • AutoBash calculates the intersection • Determines which predicates to run Action: touch foo file: foo file: bar Do not run predicate Predicate: grep “test” bar

  14. exit sh fork & exec Process touch touch File metadata foo create exit touch File content foo file foo Directory entry foo Tracking output sets • An output set is tracked for each action sh Output set Process sh Action: sh create_file.sh create_file.sh: touch foo

  15. Process sh fork & exec Process sh Process grep Process grep Process grep grep File metadata bar File metadatabar File metadata bar read exit File content bar grep file bar File contentbar File content bar Directory entry bar Directory entry bar Directory entry bar Process grep’s input set Tracking input sets • An input set is tracked for each predicate sh sh Predicate: sh testfile.sh testfile.sh: grep “test” bar Process sh Predicate’s input set

  16. Understanding solutions can be hard • AutoBash generates causal explanation • Analyzes input and output sets

  17. Causal explanation Actions ls –l /home/$USER chmod +x /home/$USER chmod +x /home/$USER/ public_html metadata: /home/$USER metadata: /home/$USER/ public_html Kernel objects Predicates wget index.html wget ~$USER/cgi-bin/test.pl wget ~$USER/index.html

  18. Outline • Motivation • AutoBash design and implementation • Observation mode • Replay mode • Health monitoring mode • Evaluation • Conclusion

  19. Replay mode • Problem: finding a solution is time-consuming • Automatically searches for a solution • No user input needed • Speculative execution provides isolation • User continues foreground task • AutoBash runs replay mode in background

  20. Solution Database Predicate Database P0 P0 P0 P1 P1 P1 P2 P2 P2 S0 P3 P3 P3 S1 P4 P4 P4 S2 S3 S4 S5 How replay mode works S0 S1 S2 • Initial predicate testing: • Tracks input set for each predicate • Determines passed/failed predicates

  21. Solution Database Predicate Database P0 P0 P1 P1 P2 P2 S0 P3 P3 S1 P4 P4 S2 S3 S4 S5 How replay mode works S0 S1 S2 • (2) Solution execution: • Speculatively executes a solution • Tracks solution output set

  22. Solution Database Predicate Database P0 P0 P1 P1 P2 P2 S0 P3 P3 S1 P4 P4 S2 S3 S4 S5 P0 P2 How replay mode works S1 S2 Predicate fails S0 • (3) Verifying solution: • Calculates intersection • Runs predicates with intersection

  23. Solution Database Predicate Database P0 P0 P1 P1 P2 P2 S0 P3 P3 S1 P4 P4 S2 S3 S4 S5 P0 P2 How replay mode works S0 S1 S2 Discards solution with no intersection

  24. Solution Database Predicate Database P0 P0 P0 P1 P1 P1 P2 P2 P2 S0 P3 P3 P3 S1 P4 P4 P4 S2 S3 S4 S5 P0 P0 P1 P2 P2 P3 P4 How replay mode works S0 S1 S2 Predicate passes Predicates pass • (4) Regression tests: • Calculates intersection • Runs predicates affected by solution

  25. Solution Database Predicate Database P0 P0 P0 P1 P1 P1 P2 P2 P2 S0 P3 P3 P3 S1 P4 P4 P4 S2 S3 S4 S5 P0 P1 P2 P3 P4 How replay mode works S0 S1 S2 Predicate passes S2 • Speculative execution provides safety • Causality analysis provides speed

  26. Health monitoring mode • Periodically executes all predicates • If any predicate fails, AutoBash • Runs replay mode to search for a solution • Reports to the user to run observation mode

  27. Outline • Motivation • AutoBash Design and Implementation • Observation mode • Replay mode • Health monitoring mode • Evaluation • Conclusion

  28. Evaluation • Questions: • What is the overhead of speculative execution? • How effective is causality analysis? • Methodology: • Evaluated CVS, gcc cross compiler, web server • Manually created 10 bugs and 10 solutions • Manually created 5-8 predicates

  29. Total replay time (GCC) Without speculative execution With speculative execution 1 2 3 4 5 6 7 8 9 10 • Speculative execution overhead is negligible

  30. Total replay time (GCC) Without causality analysis With causality analysis 1 2 3 4 5 6 7 8 9 10 • Causal analysis improves predicate re-testing time by 67-99%

  31. Conclusion • Configuration management is frustrating • AutoBash automates most tedious parts • Speculative executionmakes AutoBash safe • Causality analysismakes AutoBash fast

  32. Questions? • Supported by

More Related