Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[build] make packages installation quieter & faster #13070

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Commits on Dec 16, 2022

  1. [build] quiet & speed up packages installation

    Many apt and pip commands are called inside chroot during SONiC build
    process.
    Though they are not interactive, they generate a lot of scrolling output
    in the console that slows down the whole SONiC installation process.
    
    https://shallowsky.com/blog/linux/performance-of-scrolling-output.html
    
    Most of this output has no added value and makes troubleshooting more
    complex.
    It can be safely disabled by setting the right environment variables
    and/or options. Note they cannot completely prevent underlying
    calls to dpkg from displaying a few output. Only a redirection to
    /dev/null can prevent the dpdk output from being displayed
    
    Also since there are several wrappers to apt (apt-get/apt/aptitude)
    and since almost all of these apt calls are done inside chroot,
    it is preferable from a maintenance and efficiency perspective to
    - create a shell function with all these parameters to install packages
    - cascade contiguous chroot and apt or pip commands to avoid mutiple
      context allocations
    
    Signed-off-by: Guillaume Lambert <guillaume.lambert@orange.com>
    guillaumelambert committed Dec 16, 2022
    Configuration menu
    Copy the full SHA
    ac5ddf6 View commit details
    Browse the repository at this point in the history