Ask Your Question
0

Grizzly: how can I delete instances that don't show up in "nova list" ? Is there any way to shut them down and free their resources?

asked 2014-01-07 11:18:58 -0600

amber_nic gravatar image

updated 2014-01-07 12:28:21 -0600

Hi all,

yesterday by mistake I erased the wrong uuids at nova's instance_system_metadata table and couldn't manage my farm. The solution (answered by larsks) was to wipeout nova's database, create it again, sync it and then restart all my nova services. Now I can manage it again.

I have two instances that keep on running but I obviously don't have their uuids. My question is: how can I delete them? Is there any table where their uuids are stored so I can obtain them and delete them? Is there maybe another alternative to that to just stop them and free their floating ips?

Any clues will be appreciated.

edit retag flag offensive close merge delete

Comments

what I have understood is that instances are not in db but exist on compute. If this is the case set the following nova.conf running_deleted_instance_action=reap Restart your services. This should take care. Also you can look at this directory /var/lib/nova/instances/* to see the instances.

dheeru gravatar imagedheeru ( 2014-01-07 12:58:47 -0600 )edit

3 answers

Sort by ยป oldest newest most voted
0

answered 2014-05-14 08:34:49 -0600

vikki gravatar image

Change the status from database and then try to delete.

edit flag offensive delete link more

Comments

how to change the status from database?please tell me,thank you.

shengchao liu gravatar imageshengchao liu ( 2014-05-14 08:38:30 -0600 )edit
1

answered 2014-05-14 15:20:54 -0600

updated 2014-05-17 02:39:38 -0600

Try

Nova list

It will list all your instances. Then try

nova delete "server-id/name"

This will remove the server from database. If you want to see the Instance details in Database. you can see that Instances table in nova database.

Example:

  • mysql
  • use nova
  • select uuid, hostname from instances

It will list the UUID's and name of the instances. Hope that gives you some help!

EDIT


You can restart the instances. You can do it Through Horizon by going into the instances tab and then in actions column. OR You can execute

nova reboot SERVER

To perform a hard reboot run

nova reboot --hard SERVER

To reset the state of the instance run

nova reset-state --active UUID

OR

nova delete UUID

for deleting the instance. Hope that helps!!

edit flag offensive delete link more

Comments

an accident power off on my host,so the instance's state become error,the power state become shutdown,what can i do for this?

shengchao liu gravatar imageshengchao liu ( 2014-05-14 19:38:27 -0600 )edit
1

Shengchao, I have edited the answer. please give it a read.

Syed Awais Ali gravatar imageSyed Awais Ali ( 2014-05-15 06:42:53 -0600 )edit

thank you,i will try it next time.

shengchao liu gravatar imageshengchao liu ( 2014-05-16 10:39:15 -0600 )edit

In fact I delete the state-error instance from the database,so I can terminate the instance from the horizon,but I think this is not a good action,can I recover the instance to normal state?

shengchao liu gravatar imageshengchao liu ( 2014-05-29 19:31:24 -0600 )edit
0

answered 2014-05-14 08:24:09 -0600

shengchao liu gravatar image

my instance could not delete,and the power state is "shutdown",i can not manage it.what can i do?

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

2 followers

Stats

Asked: 2014-01-07 11:18:58 -0600

Seen: 776 times

Last updated: May 17 '14