System Mangled: Como desfazer o sudo apt-get remove gnupg

1

Eu acidentalmente removi o GnuPG e destruí meu sistema! Alguém pode me ajudar a desfazer o dano que eu causei?

Porquê:

Desde que eu tinha o GnuPG2 e continuei usando acidentalmente o gpg em vez do gpg2, achei que seria melhor remover o gpg e criar um alias, então estou executando a versão mais recente.

Como:

sudo apt-get remove gnupg

Resultados:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages were automatically installed and are no longer required: caja-folder-color-switcher dconf-cli eom gir1.2-mate-menu gir1.2-mate-panel  libgtkmm-3.0-1 libmate-sensors-applet-plugin0 libmate-slab0 libmate-window-settings1 libmatedict6 libwireshark3 libwiretap3 libwsutil3 mate-applets mate-applets-common mate-common mate-control-center mate-control-center-common mate-indicator-applet mate-indicator-applet-common mate-media mate-media-common mate-netspeed
mate-netspeed-common mate-power-manager mate-power-manager-common mate-screensaver mate-screensaver-common mate-sensors-applet mate-sensors-applet-common mate-system-monitor mate-system-monitor-common mate-user-guide mate-utils mate-utils-common mint-artwork-gnome mint-artwork-mate mint-backgrounds-rosa mintdesktop mintmenu mintwelcome
mozo pluma python-mate-menu ubuntu-system-adjustments
Use 'apt-get autoremove' to remove them.
The following packages will be REMOVED:
add-apt-key apt gnupg libcryptui0a linuxmint-keyring mint-meta-core
mint-meta-mate seahorse-daemon seahorse-nautilus ubuntu-extras-keyring
ubuntu-minimal unattended-upgrades
WARNING: The following essential packages will be removed.
This should NOT be done unless you know exactly what you are doing!
  apt gnupg (due to apt)
0 upgraded, 0 newly installed, 12 to remove and 4 not upgraded.
After this operation, 13.1 MB disk space will be freed.
You are about to do something potentially harmful.
To continue type in the phrase 'Yes, do as I say!'
?] Yes, do as I say!
(Reading database ... 255894 files and directories currently installed.)
Removing mint-meta-mate (2015.12.21) ...
Removing mint-meta-core (2015.12.21) ...
Removing add-apt-key (1.0-0.5) ...
Removing unattended-upgrades (0.82.1ubuntu2.5) ...
Removing ubuntu-minimal (1.325) ...
Removing seahorse-nautilus (3.8.0-0ubuntu2) ...
Removing libcryptui0a:amd64 (3.8.0-1) ...
Removing seahorse-daemon (3.8.0-1) ...
Removing ubuntu-extras-keyring (2010.09.27) ...
OK
Removing linuxmint-keyring (2009.04.29) ...
OK
Removing apt (1.0.1ubuntu2.17) ...
Removing gnupg (1.4.16-1ubuntu2.4) ...
Processing triggers for man-db (2.6.7.1-1ubuntu1) ...
Processing triggers for libglib2.0-0:i386 (2.40.2-0ubuntu1) ...
Processing triggers for libglib2.0-0:amd64 (2.40.2-0ubuntu1) ...
Processing triggers for gconf2 (3.2.6-0ubuntu2) ...
Processing triggers for desktop-file-utils (0.22-1ubuntu1) ...
Processing triggers for mime-support (3.54ubuntu1.1) ...
Processing triggers for libc-bin (2.19-0ubuntu6.11) ...
Processing triggers for install-info (5.2.0.dfsg.1-2) ...

Agora estou em um lugar ruim, aqui está o meu novo mundo:

sudo apt-get install apt

The program 'apt-get' is currently not installed. You can install it by typing: sudo apt-get install apt

Meu sistema é lavado? Como eu me recupero desse desastre?

    
por Zenji Agamotto 17.06.2017 / 05:18

1 resposta

0

Acho que você ainda tem os pacotes em /var/cache/apt/archives/ e, se ainda tiver dpkg , poderá instalar os pacotes novamente. Faça o login como root e reinstale-os:

sudo -i
cd /var/cache/apt/archives/
# find the newest "apt" and "gnupg" package
ls -l apt_*.deb gnupg_*.deb
# inspect the filenames and install the right version
dpkg -i apt_1.0.1ubuntu2.17.deb gnupg_1.4.16-1ubuntu2.4.deb
    
por 17.06.2017 / 07:56