existing ubuntu ec2 instance that has data should look like new server, after deleting everything

0

my question is i have got an existing Ubuntu ec2 instance that has got DNS mapping and setup. I need to delete of all the installation with files and folders and make it look like a fresh server. so how can i approch it

posta un anno fa215 visualizzazioni
2 Risposte
1

Any reason why you can’t create a new instance so it’s fresh and terminate the old one?

profile picture
ESPERTO
con risposta un anno fa
0

Hello

Assuming this instance needs to be publicly accessible and is configured without a load balancer or an elastic IP. I don't believe that there is a straightforward way to achieve a clean installation state. However, I would recommend the following

  1. Uninstall all the software using apt purge
  2. Use apt autoremove to remove any unused package
  3. Remove any user directories/log files
  4. If ssh multiple SSH keys are configured, remove the keys from authorized_hosts

Hope this helps.

profile picture
Bisina
con risposta un anno fa

Accesso non effettuato. Accedi per postare una risposta.

Una buona risposta soddisfa chiaramente la domanda, fornisce un feedback costruttivo e incoraggia la crescita professionale del richiedente.

Linee guida per rispondere alle domande