Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix #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