a study of linux file system evolution
play

A Study of Linux File System Evolution Lanyue Lu Andrea C. - PowerPoint PPT Presentation

A Study of Linux File System Evolution Lanyue Lu Andrea C. Arpaci-Dusseau Remzi H. Arpaci-Dusseau Shan Lu University of Wisconsin - Madison Local File Systems Are Important Local File Systems Are Important Windows Mac Linux Local File


  1. Bug Pattern Type Description Incorrect design or implementation Semantic (e.g. incorrect state update, wrong design) Concurrency Incorrect concurrent behavior (e.g. miss unlock, deadlock) Incorrect handling of memory objects Memory (e.g. resource leak, null dereference) Missing or wrong error code handling Error Code (e.g. return wrong error code)

  2. Semantic Bug Example ext3/ialloc.c, 2.6.4 find_group_other(...){ ... ... 1 group = parent_group + 1; 2 for (i = 2; i < ngroups; i++) { } ... ... }

  3. Semantic Bug Example ext3/ialloc.c, 2.6.4 find_group_other(...){ ... ... 1 group = parent_group; 2 for (i = 0; i < ngroups; i++) { } ... ... }

  4. Bug Pattern 511 450 358 229 158 80 1786 100% 80% 60% 40% Semantic 20% 0% XFS Ext4 Btrfs Ext3 Reiser JFS All

  5. Bug Pattern 511 450 358 229 158 80 1786 100% 80% 60% 40% Semantic 20% 0% XFS Ext4 Btrfs Ext3 Reiser JFS All

  6. Bug Pattern 511 450 358 229 158 80 1786 100% 80% 60% 40% Semantic 20% 0% XFS Ext4 Btrfs Ext3 Reiser JFS All

  7. Concurrency Bug Example ext4/extents.c, 2.6.30 ext4_ext_put_in_cache(...){ ... ... 1 cex = &EXT4_I(inode)->i_cached_extent; 2 cex->ec_FOO = FOO; }

  8. Concurrency Bug Example ext4/extents.c, 2.6.30 ext4_ext_put_in_cache(...){ ... ... spin_lock(i_br_lock); 1 cex = &EXT4_I(inode)->i_cached_extent; 2 cex->ec_FOO = FOO; spin_unlock(i_br_lock); }

  9. Bug Pattern 511 450 358 229 158 80 1786 100% 80% 60% Concurrency 40% Semantic 20% 0% XFS Ext4 Btrfs Ext3 Reiser JFS All

  10. Memory Bug Example btrfs/inode, 2.6.30 btrfs_new_inode(...){ 1 inode = new_inode(...); 2 ret = btrfs_set_inode_index(...); 3 if (ret){ 4 return ERR_PTY(ret); } }

  11. Memory Bug Example btrfs/inode, 2.6.30 btrfs_new_inode(...){ 1 inode = new_inode(...); 2 ret = btrfs_set_inode_index(...); 3 if (ret){ 4 return ERR_PTY(ret); } }

  12. Memory Bug Example btrfs/inode, 2.6.30 btrfs_new_inode(...){ 1 inode = new_inode(...); 2 ret = btrfs_set_inode_index(...); 3 if (ret){ 4 return ERR_PTY(ret); } }

  13. Memory Bug Example btrfs/inode, 2.6.30 btrfs_new_inode(...){ 1 inode = new_inode(...); 2 ret = btrfs_set_inode_index(...); 3 if (ret){ iput(inode); 4 return ERR_PTY(ret); } }

  14. Bug Pattern 511 450 358 229 158 80 1786 100% 80% 60% Memory Concurrency 40% Semantic 20% 0% XFS Ext4 Btrfs Ext3 Reiser JFS All

  15. Error Code Example reiserfs/xattr_acl.c, 2.6.16 reiserfs_get_acl(...) { ... ... 1 acl = posix_acl_from_disk(...); 2 *p_acl = posix_acl_dup(acl); }

  16. Error Code Example reiserfs/xattr_acl.c, 2.6.16 reiserfs_get_acl(...) { ... ... 1 acl = posix_acl_from_disk(...); if (!IS_ERR(acl)) 2 *p_acl = posix_acl_dup(acl); *p_acl = posix_acl_dup(acl); }

  17. Bug Pattern 511 450 358 229 158 80 1786 100% 80% Error Code 60% Memory Concurrency 40% Semantic 20% 0% XFS Ext4 Btrfs Ext3 Reiser JFS All

  18. 55% of file-system bugs are semantic bugs

  19. Q3: Do bugs diminish over time ?

  20. Ext3 Bug Trend 15 Number of Bugs 10 5 0 0 5 10 15 20 25 30 35 40 Linux Versions

  21. Ext3 Bug Trend 2.6.10: block reservation 2.6.11: xttra in inode 15 Number of Bugs 10 5 0 0 5 10 15 20 25 30 35 40 Linux Versions

  22. Ext3 Bug Trend 2.6.17: multiple block allocation 15 Number of Bugs 10 5 0 0 5 10 15 20 25 30 35 40 Linux Versions

  23. Ext3 Bug Trend 2.6.38: miss error handling 15 Number of Bugs 10 5 0 0 5 10 15 20 25 30 35 40 Linux Versions

  24. Bug Trend XFS Ext4 Btrfs 40 80 40 30 60 30 20 40 20 Number of Bugs 10 20 10 0 0 0 0 10 20 30 40 0 10 20 30 40 0 10 20 30 40 Ext3 ReiserFS JFS 15 40 10 30 10 20 5 5 10 0 0 0 0 10 20 30 40 0 10 20 30 40 0 10 20 30 40 Linux Version

  25. Bug Trend XFS Ext4 Btrfs 40 80 40 30 60 30 20 40 20 Number of Bugs 10 20 10 0 0 0 0 10 20 30 40 0 10 20 30 40 0 10 20 30 40 Ext3 ReiserFS JFS 15 40 10 30 10 20 5 5 10 0 0 0 0 10 20 30 40 0 10 20 30 40 0 10 20 30 40 Linux Version

  26. Bug Trend XFS Ext4 Btrfs 40 80 40 30 60 30 20 40 20 Number of Bugs 10 20 10 0 0 0 0 10 20 30 40 0 10 20 30 40 0 10 20 30 40 Ext3 ReiserFS JFS 15 40 10 30 10 20 5 5 10 0 0 0 0 10 20 30 40 0 10 20 30 40 0 10 20 30 40 Linux Version

  27. Bug Trend XFS Ext4 Btrfs 40 80 40 30 60 30 20 40 20 Number of Bugs 10 20 10 0 0 0 0 10 20 30 40 0 10 20 30 40 0 10 20 30 40 Ext3 ReiserFS JFS 15 40 10 30 10 20 5 5 10 0 0 0 0 10 20 30 40 0 10 20 30 40 0 10 20 30 40 Linux Version

  28. Semantic Concurrency Memory Error Code XFS Ext4 Btrfs 40 80 40 30 60 30 20 40 20 Number of Bugs 10 20 10 0 0 0 0 10 20 30 40 0 10 20 30 40 0 10 20 30 40 Ext3 ReiserFS JFS 15 40 10 30 10 20 5 5 10 0 0 0 0 10 20 30 40 0 10 20 30 40 0 10 20 30 40 Linux Version

  29. Semantic Concurrency Memory Error Code XFS Ext4 Btrfs 40 80 40 30 60 30 20 40 20 2.6.33: remove BKL Number of Bugs 10 20 10 0 0 0 0 10 20 30 40 0 10 20 30 40 0 10 20 30 40 Ext3 ReiserFS JFS 15 40 10 30 10 20 5 5 10 0 0 0 0 10 20 30 40 0 10 20 30 40 0 10 20 30 40 Linux Version

  30. Bug-fixing is a Constant in a file system’s lifetime

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend