Rancher 1.1.2 Container stuck in Restarting

I have a container that is stuck in the “Restarting” phase (it’s been that way for a while).

That container is long gone on that host, and I need to get Rancher to stop showing it’s Restarting.

In checking the database, I can see:

SELECT id, state, allocation_state, health_state FROM instance WHERE id BETWEEN 9823 AND 9825;

id state allocation_state health_state
9823 purged inactive healthy
9824 restarting active unhealthy
9825 purged inactive healthy

SELECT id, state FROM instance_host_map WHERE instance_id BETWEEN 9823 AND 9825;

id instance_id state
9527 9823 purged
9528 9824 active
9529 9825 purged


SELECT id, kind, uuid, state FROM instance_link WHERE instance_id BETWEEN 9823 AND 9825

id instance_id kind uuid state
21127 9823 instanceLink 68d36369-b67f-414a-9cb7-2d27046a3d27 purged
21128 9824 instanceLink 41146b21-b1b5-47f8-bbc5-ae239c005843 active
21129 9824 instanceLink 874f4ed8-948c-480b-8b47-9700aa4767d1 active
21130 9824 instanceLink 3b355541-d42e-4f3a-a706-94743a1abad6 active
21131 9825 instanceLink c00d826b-51d0-47ed-a2d7-bac61583e3b2 purged
21132 9825 instanceLink 5954aecb-d153-4c34-9d41-0203912b2475 purged
21133 9825 instanceLink 5f60b4a0-565d-4729-96ed-106defb1198f purged

Can I simply do:

UPDATE `instance` SET `state` = 'purged', `allocation_state` = 'inactive', `health_state` = 'healthy' WHERE `id` = 9824;
UPDATE `instance_host_map` SET `state` = 'purged' WHERE `instance_id` = 9824;
UPDATE `instance_link` SET `state`='purged' WHERE `instance_id` = 9824;

To get it to stop showing this non-existent container as “Restarting”?
If not, how can I fix it?

Bump – anybody? This is an annoying issue

There’s a good chance its a bug that was fixed already; I’m sorry but we’re just not going to spend time trying to debug a minor problem in a two-and-a-half year old release.

@vincent, no doubt, and thank you for responding. I can’t upgrade to resolve this, so I’m trying to mask it.

I just am trying to suss out if I can reset those DB fields and get Rancher to stop labeling it as restarting. I know manually setting these fields is inherently wrong, but without the old container running, that’s the only method I can think of to fix it