Automated Testing of Debian Packages Status Update Lucas Nussbaum - - PowerPoint PPT Presentation

automated testing of debian packages status update
SMART_READER_LITE
LIVE PREVIEW

Automated Testing of Debian Packages Status Update Lucas Nussbaum - - PowerPoint PPT Presentation

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion Automated Testing of Debian Packages Status Update Lucas Nussbaum lucas@debian.org Lucas Nussbaum Automated Testing of Debian


slide-1
SLIDE 1

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Automated Testing of Debian Packages Status Update

Lucas Nussbaum – lucas@debian.org

Lucas Nussbaum Automated Testing of Debian Packages 1 / 32

slide-2
SLIDE 2

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Summary

1

Introduction

2

Tests

3

Building packages more efficiently

4

Piuparts and false positives

5

State of the archive

6

Collab-qa project

7

Conclusion

Lucas Nussbaum Automated Testing of Debian Packages 2 / 32

slide-3
SLIDE 3

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Summary

1

Introduction

2

Tests

3

Building packages more efficiently

4

Piuparts and false positives

5

State of the archive

6

Collab-qa project

7

Conclusion

Lucas Nussbaum Automated Testing of Debian Packages 3 / 32

slide-4
SLIDE 4

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Introduction

At the end of the etch release cycle, quite a lot of QA was done : Several builds of all packages in etch Several piuparts runs on all packages in etch ⇒ about 200 RC bugs filed and fixed in etch

Lucas Nussbaum Automated Testing of Debian Packages 4 / 32

slide-5
SLIDE 5

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Such tests are a good thing

give the same level of attention to all packages in Debian not only rely on humans to find bugs avoid regressions keep maintainers busy :-)

Lucas Nussbaum Automated Testing of Debian Packages 5 / 32

slide-6
SLIDE 6

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Such tests are a good thing, but ...

They were run too late in the release process They caused some packages to miss etch Lots of things weren’t tested ⇒ We need to be more efficient/organized during the lenny cycle

Lucas Nussbaum Automated Testing of Debian Packages 6 / 32

slide-7
SLIDE 7

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion Rebuilding packages Piuparts

Summary

1

Introduction

2

Tests Rebuilding packages Piuparts

3

Building packages more efficiently

4

Piuparts and false positives

5

State of the archive

6

Collab-qa project Conclusion

Lucas Nussbaum Automated Testing of Debian Packages 7 / 32

slide-8
SLIDE 8

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion Rebuilding packages Piuparts

Tests

Rebuilding packages from source Piuparts runs Other tests : lintian, linda, ...

Lucas Nussbaum Automated Testing of Debian Packages 8 / 32

slide-9
SLIDE 9

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion Rebuilding packages Piuparts

Rebuilding packages

packages with "Arch : all" are only built on the developer’s machine packages with "Arch : any" are only built automatically before they reach unstable (and only on $ARCH != Uploader’s arch) After that, the build environment changes : newer/older compiler and libraries build-dependencies not available anymore (b-deps are not considered for testing propagation) Problems : Everyone should be able to build your package Stable releases must be self-contained (security updates !)

Lucas Nussbaum Automated Testing of Debian Packages 9 / 32

slide-10
SLIDE 10

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion Rebuilding packages Piuparts

Rebuilding packages : tools

pbuilder : builds a package inside a chroot very easy to set up you should use it ! talk on saturday afternoon sbuild (the Debian package) : relies on schroot a bit harder to set up, but more powerful

Lucas Nussbaum Automated Testing of Debian Packages 10 / 32

slide-11
SLIDE 11

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion Rebuilding packages Piuparts

Piuparts

Tests installation and removal of packages Process : cleans up a chroot (removes everything except apt) installs the package to test and its dependencies Removes everything, purge all dependencies Purges the package to test ⇒ test of the package maintainer scripts (preinst, postinst, prerm, postrm) under the most extreme conditions

Lucas Nussbaum Automated Testing of Debian Packages 11 / 32

slide-12
SLIDE 12

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion Rebuilding packages Piuparts

Piuparts (2)

Also tests other things : upgrades running processes after removal dangling symlinks files left after removal/purge, files from other packages modified

Lucas Nussbaum Automated Testing of Debian Packages 12 / 32

slide-13
SLIDE 13

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Summary

1

Introduction

2

Tests

3

Building packages more efficiently

4

Piuparts and false positives

5

State of the archive

6

Collab-qa project

7

Conclusion

Lucas Nussbaum Automated Testing of Debian Packages 13 / 32

slide-14
SLIDE 14

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Rebuilding packages : resources usage

Rebuilding all packages in Debian Etch : about 10 days on a single computer Most packages are fast to build :

0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 1 10 100 1000 10000 F(x) package build time (s), logarithmic scale Lucas Nussbaum Automated Testing of Debian Packages 14 / 32

slide-15
SLIDE 15

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Rebuilding packages : resources usage (2)

But some packages take a long time (numbers from etch) : Source package Time

  • penoffice.org

7 h 14 min latex-cjk-chinese-arphic 6 h 18 min linux-2.6 5 h 43 min gcc-4.1 2 h 52 min gcj-4.1 2 h 44 min gnat-4.1 1 h 52 min gcc-3.4 1 h 50 min installation-guide 1 h 45 min axiom 1 h 44 m k3d 1 h 39 min (On Dual-Opteron 2 GHz, 2 GB RAM)

Lucas Nussbaum Automated Testing of Debian Packages 15 / 32

slide-16
SLIDE 16

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Parallel Rebuilds on an HPC grid

Rebuilding Debian on a computer grid I could use 100s of nodes But it’s useless because openoffice.org takes too long

. . .

node 40 node 39 node 37 node 38 node 1

  • penoffice.org

linux−2.6 ~ 7.5 hours

⇒ Full rebuild of etch in about 7.5 hours on 40 nodes

Lucas Nussbaum Automated Testing of Debian Packages 16 / 32

slide-17
SLIDE 17

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Leveraging multi-cores

dual-core laptops quad-core desktops Already available. Wouldn’t it be nice to make use of them ?

Lucas Nussbaum Automated Testing of Debian Packages 17 / 32

slide-18
SLIDE 18

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

#209008 : common interface for parallel building

DEB_BUILD_OPTIONS_PARALLEL=n

  • r

DEB_BUILD_OPTIONS="parallel=n" Red bike shed problem ? Will hopefully be included in the next policy update (no ETA, AFAIK)

Lucas Nussbaum Automated Testing of Debian Packages 18 / 32

slide-19
SLIDE 19

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Parallel build of linux-2.6

1 2 3 4 5 6 1 2 4 8 Build time (hours) parallel=n linux-2.6 ideal speed-up

On a dual-Opteron (both dual-cores), 2 GB RAM

Lucas Nussbaum Automated Testing of Debian Packages 19 / 32

slide-20
SLIDE 20

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Summary

1

Introduction

2

Tests

3

Building packages more efficiently

4

Piuparts and false positives

5

State of the archive

6

Collab-qa project

7

Conclusion

Lucas Nussbaum Automated Testing of Debian Packages 20 / 32

slide-21
SLIDE 21

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Piuparts and false positives

Piuparts generates A LOT of false positives To be tested, a package must be able to install non-interactively debconf is nice (Noninteractive frontend) but doesn’t solve everything (e.g packages that need access a database) ⇒ Make all packages use debconf (except essential ones) : policy bug #206684 ⇒ After that, not much to do about false positives

Lucas Nussbaum Automated Testing of Debian Packages 21 / 32

slide-22
SLIDE 22

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Piuparts : Future work

Improve piuparts now (supposed to be) maintained collaboratively ! piatti.debian.org : dual Xeon in helsinki Used by liw to run piuparts over the archive Idea : Xen instances for interested DD to reproduce/investigate results Other ideas ?

Lucas Nussbaum Automated Testing of Debian Packages 22 / 32

slide-23
SLIDE 23

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Summary

1

Introduction

2

Tests

3

Building packages more efficiently

4

Piuparts and false positives

5

State of the archive

6

Collab-qa project

7

Conclusion

Lucas Nussbaum Automated Testing of Debian Packages 23 / 32

slide-24
SLIDE 24

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Trivia

john - active password cracking tool webcalendar - PHP-Based multi-user calendar What do john and webcalendar have in common ?

Lucas Nussbaum Automated Testing of Debian Packages 24 / 32

slide-25
SLIDE 25

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Trivia

john - active password cracking tool webcalendar - PHP-Based multi-user calendar What do john and webcalendar have in common ? both were in sarge, and are in unstable both are useful software (I use both)

Lucas Nussbaum Automated Testing of Debian Packages 24 / 32

slide-26
SLIDE 26

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Trivia

john - active password cracking tool webcalendar - PHP-Based multi-user calendar What do john and webcalendar have in common ? both were in sarge, and are in unstable both are useful software (I use both) neither john nor webcalendar are in etch

Lucas Nussbaum Automated Testing of Debian Packages 24 / 32

slide-27
SLIDE 27

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Many packages missed the release

Packages in unstable, but not in etch, were reviewed after the etch release 433 packages (excl. packages uploaded after the freeze) in many cases (>50%), the maintainer simply forgot to request an unblock

  • r wasn’t aware of his package’s RC bugs

Example bugs : #402245, #381817, #384558, #414845, and many others ⇒ We need a way to keep maintainers informed of their packages’ status

Lucas Nussbaum Automated Testing of Debian Packages 25 / 32

slide-28
SLIDE 28

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Proposal : DDPO by mail

DDPO is nice But only if you use it Ideally : browser’s start page for maintainers, but... Idea : send one monthly email to each maintainer with the most important information about his packages

  • pen RC bugs

packages not in testing important bugs with patches

Lucas Nussbaum Automated Testing of Debian Packages 26 / 32

slide-29
SLIDE 29

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Proposal : DDPO by mail (2)

  • pt-out, so it has to stay as useful as possible

ignore mechanism (per package, per bug, per problem) Current implementation status : BTS metadata imported to a postgres DB on merkel.d.o (could be used to generate interesting stats as well) But bugs need to be fixed Use bts.turmzimmer.net as input instead (easier !) Testing status for all packages ⇒ Ready to start sending mails

Lucas Nussbaum Automated Testing of Debian Packages 27 / 32

slide-30
SLIDE 30

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Summary

1

Introduction

2

Tests

3

Building packages more efficiently

4

Piuparts and false positives

5

State of the archive

6

Collab-qa project

7

Conclusion

Lucas Nussbaum Automated Testing of Debian Packages 28 / 32

slide-31
SLIDE 31

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Collaborative Quality Assurance : collab-qa project

QA tasks used to be done by (motivated) individuals Working as a team brings more fun And is more scalable collab-qa project on alioth : share results of QA tests (archive rebuilds, piuparts runs) keep them for history makes things more fun and more efficient

Lucas Nussbaum Automated Testing of Debian Packages 29 / 32

slide-32
SLIDE 32

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

collab-qa status

<Lunar> I think I’m becoming a perverse... I enjoy reporting FTBFS. Worked on : Packages that missed etch (not finished yet) Archive rebuilds (up to date for 14/06/2007) File conflicts between packages Plans to work on : Piuparts runs put your idea here Don’t hesitate to join !

Lucas Nussbaum Automated Testing of Debian Packages 30 / 32

slide-33
SLIDE 33

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Summary

1

Introduction

2

Tests

3

Building packages more efficiently

4

Piuparts and false positives

5

State of the archive

6

Collab-qa project

7

Conclusion

Lucas Nussbaum Automated Testing of Debian Packages 31 / 32

slide-34
SLIDE 34

Introduction Tests Building packages more efficiently Piuparts State of the archive collab-qa Conclusion

Conclusion

Let’s make QA rock for lenny ! Join the collab-qa team /join #debian-qa subscribe to debian-qa@lists.debian.org request membership on alioth Open questions : What do you think of that "DDPO by mail" idea ? What about a "Packages in a questionable state" team ?

Lucas Nussbaum Automated Testing of Debian Packages 32 / 32