forked from sonic-net/sonic-buildimage
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Build]: Fix dpkg lock (sonic-net#15735)
Fix sonic-net#15722 We don't need to use a lock file every time we call dpkg. For some commands, like dpkg --print-architecture or dpkg --compare-versions, this action is not required. Moreover, sometimes these commands are called by apt-get and dpkg -i, and we get a deadlock in this case. How I did it Use dpkg lock only for dpkg commands that use /var/lib/dpkg/lock or /var/lib/dpkg/lock-frontend. I mean dpkg -i, dpkg -P, ... How to verify it Check there is no dpkg lock errors in build log. Check build time of docker-sonic-vs.gz: old: 08:57:14[ building ] [ target/docker-sonic-vs.gz ] 09:12:47 [ finished ] [ target/docker-sonic-vs.gz ] new: 01:45:12[ building ] [ target/docker-sonic-vs.gz ] 01:50:39 [ finished ] [ target/docker-sonic-vs.gz ]
- Loading branch information
Showing
2 changed files
with
38 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters