Interview Prep/Ansible/Performance and Scale

How do you speed up package installs across a fleet?

BeginnerProductionPerformance and Scale
Answer

Point hosts at an internal mirror or caching proxy (Artifactory, Nexus, apt-cacher-ng, a Pulp or Satellite repo) instead of the public internet. Use cache_valid_time for apt, install lists in one task, and bake common packages into the image.

With async the downloads happen in parallel, but a thousand hosts hitting one mirror at once will saturate it, so stagger with serial or throttle. Pin versions where repeatability matters, because unpinned installs can differ between runs a week apart.

All Ansible questions Roadmap: Ansible

More on Performance and Scale