Date created: 01/21/20 08:50:16. Last modified: 05/11/21 10:23:05

'apt' & 'dpkg' Notes

List installed packages:

apt list --installed

or

aptitude search '~i!~M'

or

dpkg --get-selections | grep -v deinstall

 

Export and install a list of packages:

dpkg --get-selections | grep -v deinstall > ~/Desktop/packages

sudo dpkg --set-selections < ~/Desktop/packages && sudo apt-get -u dselect-upgrade

 

Force APT to use IPv4 or IPv6:

apt-get -o Acquire::ForceIPv4=true update
apt-get -o Acquire::ForceIPv6=true update