Nova Resource:Deployment-prep/Decommission an instance

From Wikitech
Jump to navigation Jump to search

When you're ready to get rid of an instance:

  • Shut it down and leave it a while to see if anyone screams - maybe leave it a few weeks. Obviously if you were the only person to ever use an instance this may be unnecessary.
  • Delete it in Horizon
  • Log onto the puppetmaster and: (this is so the host is gone from Puppet DB and no longer shows up in queries etc.)
    • sudo puppet node deactivate deployment-NAME.deployment-prep.eqiad.wmflabs
    • sudo puppet node clean deployment-NAME.deployment-prep.eqiad.wmflabs

Every once in a while someone should go on deployment-cumin02 and sudo cumin 'P{*}' id --force to find instances that no longer exist but that someone forgot to run the puppet node commands above for. Any errors you get are pointers to hosts that are not up - before running the above commands you should check to see if they've actually been deleted or are just shut down. For these hosts the error should probably be about failing to resolve the .deployment-prep.eqiad.wmflabs DNS name.