¿Cómo le hago para regresar a Ubuntu desde cero, sin instalar desde cero la distribución de Ubuntu?
En el tux Angelverde nos dan una solución:
Ejecutar en terminal lo siguiente:
sudo su root -c "echo apt-get clean && apt-get update --fix-broken && echo -e '#\x21/bin/bash\\n\\nfor pkg in \x60dpkg --get-selections | egrep -v deinstall | awk \x27{print \$1}\x27 | egrep -v \x27(x11-common|libc|libss2|libstdc|libpam|libgcc|liblaunch pad|libtext-wrap|lsb-base|passwd|upstart|dpkg|debconf|perl-base|python|apt|initscripts|sysv|coreutils|bash|my sql|virtuoso|mythtv|anjuta)\x27\x60 ; do pkgs=\"\$pkgs \$pkg\"; done\\necho \"Se esta ejecutando el siguiente comando Apt-Get:\\\n--------------------------------------\\\n\\\napt-get -y -m --force-yes install --reinstall\$pkgs\\\n\\\nSalida del Comando:\\\n-------------------\\\n\" > reinstallationlog.txt\\napt-get -y -m --force-yes install --reinstall\$pkgs | tee -a reinstallationlog.txt' > reinstall.sh && clear && echo -e \"\\nSetting Script Permissions...\\\n------------------------------\" && chown -v root:root reinstall.sh && chmod +x -v reinstall.sh && echo -e \"\\nStarting Package Re-Installation Process...\\n-------------------------------------------\" && sh reinstall.sh && echo -e \"\\nThe re-installation process is complete. A log of the process can be found in the file called 'reinstallationlog.txt'.\""
Segunda opción:
Crear un scrip que contenga esto:
#!/bin/bash
for pkg in `dpkg --get-selections | egrep -v
deinstall | awk '{print $1}' | egrep -v
'(x11-common|libc|libss2|libstdc|libpam|libgcc|liblaunchpad|libtext-wrap|lsb-base|passwd|upstart|dpkg|debconf|perl-base|python|apt|initscripts|sysv|coreutils|bash|mysql|virtuoso|mythtv|anjuta)'`
; do pkgs="$pkgs $pkg"; done
echo "Se esta ejecutando el siguiente
comando Apt-Get:\n--------------------------------------\n\napt-get -y
-m --force-yes install --reinstall$pkgs\n\nSalida del
Comando:\n-------------------\n" > reinstallationlog.txt
apt-get -y -m --force-yes install --reinstall$pkgs | tee -a reinstallationlog.txt
Lo guardamos con un nombre que indentifiquemos en la carpeta de usuario (home), ejemplo: reinstalar.sh
Antes de iniciar sesión oprimimos ctrl+alt+F1, iniciamos sesión, le damos permisos:
sudo chown root:root reinstalar.sh
sudo chmod 755 reinstalar.sh
Lo ejecutamos:
sudo ./reinstalar.sh
Reiniciamos con:
sudo reboot
¡Y a disfrutar se ha dicho!
Fuente | El tux Angelverde
0 comentarios:
Publicar un comentario