Com o seguinte comando você pode obter uma lista de pacotes instalados, classificados por prioridade:
dpkg-query -Wf '${Package;-40}${Priority}\n' | sort -b -k2,2 -k1,1
Uma descrição de prioridades é dada no Manual de Normas Debian .
Na minha instalação eu obtenho o seguinte (eu só mostro obrigatório , importante e padrão pacotes):
apt important
aptitude important
apt-utils important
bsdmainutils important
cron important
debconf-i18n important
dmidecode important
gnupg important
gpgv important
groff-base important
info important
install-info important
iptables important
iputils-ping important
isc-dhcp-client important
isc-dhcp-common important
libapt-inst1.3 important
libapt-pkg4.11 important
libboost-iostreams1.46.1 important
libcwidget3 important
libept1 important
libgdbm3 important
libgdbm3 important
libgudev-1.0-0 important
libnewt0.52 important
libpcre3 important
libpipeline1 important
libpopt0 important
libreadline6 important
libssl1.0.0 important
libsysfs2 important
libusb-0.1-4 important
libxapian22 important
logrotate important
man-db important
manpages important
medibuntu-keyring important
nano important
netbase important
net-tools important
python important
readline-common important
rsyslog important
ubuntu-extras-keyring important
ubuntu-keyring important
vim-common important
vim-tiny important
wget important
whiptail important
adduser required
base-files required
base-passwd required
bash required
bsdutils required
busybox-initramfs required
coreutils required
cpio required
dash required
debconf required
debianutils required
diffutils required
dpkg required
e2fslibs required
e2fsprogs required
findutils required
gcc-4.6-base required
gcc-4.6-base required
grep required
gzip required
hostname required
ifupdown required
initscripts required
insserv required
iproute required
klibc-utils required
libacl1 required
libacl1 required
libattr1 required
libattr1 required
libblkid1 required
libbz2-1.0 required
libc6 required
libc6 required
libc-bin required
libcomerr2 required
libcomerr2 required
libdb5.1 required
libdbus-1-3 required
libdevmapper1.02.1 required
libdrm2 required
libdrm-intel1 required
libdrm-nouveau1a required
libdrm-radeon1 required
libffi6 required
libgcc1 required
libgcc1 required
libglib2.0-0 required
libklibc required
liblocale-gettext-perl required
liblzma2 required
libmount1 required
libncurses5 required
libncursesw5 required
libnih1 required
libnih-dbus1 required
libpam0g required
libpam-modules required
libpam-modules-bin required
libpam-runtime required
libpciaccess0 required
libpcre3 required
libplymouth2 required
libpng12-0 required
libselinux1 required
libselinux1 required
libslang2 required
libss2 required
libssl1.0.0 required
libstdc++6 required
libstdc++6 required
libtext-charwidth-perl required
libtext-iconv-perl required
libtext-wrapi18n-perl required
libtinfo5 required
libudev0 required
libuuid1 required
libuuid1 required
locales required
login required
lsb-base required
lzma required
makedev required
mawk required
module-init-tools required
mount required
mountall required
multiarch-support required
ncurses-base required
ncurses-bin required
passwd required
perl-base required
plymouth required
procps required
python2.7-minimal required
python-minimal required
sed required
sensible-utils required
sysvinit-utils required
sysv-rc required
tar required
tzdata required
udev required
upstart required
ureadahead required
util-linux required
xz-utils required
zlib1g required
zlib1g required
at standard
bash-completion standard
bc standard
bind9-host standard
dc standard
dnsutils standard
file standard
ftp standard
gettext-base standard
less standard
libbind9-60 standard
libcap2 standard
libdb5.1 standard
libdns69 standard
libedit2 standard
libevent-2.0-5 standard
libgc1c2 standard
libgcrypt11 standard
libgcrypt11 standard
libgnutls26 standard
libgnutls26 standard
libgpg-error0 standard
libgpg-error0 standard
libgpm2 standard
libgssapi-krb5-2 standard
libgssapi-krb5-2 standard
libidn11 standard
libidn11 standard
libisc62 standard
libk5crypto3 standard
libk5crypto3 standard
libkeyutils1 standard
libkeyutils1 standard
libkrb5-3 standard
libkrb5-3 standard
libkrb5support0 standard
libkrb5support0 standard
libldap-2.4-2 standard
libldap-2.4-2 standard
liblockfile1 standard
liblwres60 standard
libmagic1 standard
libpci3 standard
libsasl2-2 standard
libsasl2-2 standard
libsqlite3-0 standard
libsqlite3-0 standard
libtasn1-3 standard
libtasn1-3 standard
libxml2 standard
lsof standard
m4 standard
make standard
mime-support standard
mlocate standard
openssh-client standard
patch standard
pciutils standard
perl standard
perl-modules standard
python-apt standard
python-central standard
telnet standard
time standard
ucf standard
wamerican standard
whois standard
O Sistema Básico é definido como um sistema contendo apenas pacotes necessários e importantes .
Pacotes marcados como padrão não são estritamente necessários para um sistema em funcionamento, mas você pode ter dificuldades se sentir falta deles.
Então, para remover todos os pacotes desnecessários ( opcional e extra ), você pode executar o seguinte comando:
sudo apt-get --simulate purge $(dpkg-query -Wf '${Package;-40}${Priority}\n' |
awk '$2 ~ /optional|extra/ { print $1 }')
Eu adicionei a opção --simulate
para estar seguro e ver o que apt
diz.
Estranhamente, ele pede para remover também alguns pacotes necessários: e2fsprogs
, util-linux
, hostname
e upstart
, então é necessário reinstalar esses pacotes. Eu iria baixar os pacotes com antecedência ( apt-get download <packages>
), para evitar problemas de rede depois.
Leve também em consideração que para um Wifi funcional você pode precisar de algum pacote opcional ou extra , removido no procedimento acima.