"oneprovision delete" returns "Buffer error" [SOLVED]

Hi All!

I’m trying to delete a provision but “oneprovision delete [PROVISION_ID]” returns “buffer error” for this provision. All of the resources have already been deleted. However, the provision refuses to gpo away.
Any ideas are wellcome.

Regards,
Marcus Rocha

Hello @marcusrocha,

How did you delete the resources? It may happen that the terraform state or config is not well formed and when trying to decode it, it gives that error.

Best,
Álex.

Hi @ahuertas,

As long as I can remember, I tried do delete using webapp OneProvision with cleanup. As it did not succeed, I deleted the OpenNebula resources such as Network, Cluster and Host. So, now I have a provision with non existent resources. “Buffer error” happens when I try do remote it:

[oneadmin@one ~]$ oneprovision show 23
PROVISION 23 INFORMATION
ID : 23
NAME : aws-edge-cluster-METAL
STATE : DELETING
PROVIDER : aws-north-virginia-METAL

Provision Infrastructure Resources

CLUSTERS
118: aws-edge-cluster-METAL

DATASTORES
147: aws-edge-cluster-METAL-image
148: aws-edge-cluster-METAL-system

HOSTS
29: provision-31760c2850694df0183caa1dded878f87db1c1c5f1c1d6da

NETWORKS
24: aws-edge-cluster-METAL-public

Regards,
Marcus

Hello @marcusrocha,

In such situation you need to use oneprovision <resource> delete command, instead of delete commands. Now you need to manually delete the object in the database DELETE FROM document_pool WHERE oid = 23.

Best,
Álex.

Thanks, works fine!

What is the differentiation between the oneprovision delete and the oneprovision delete

Hello @DistGent,

I guess you want to know the difference between oneprovision delete and oneprovision <resource> delete. If that the case, basically the delete one, will delete all the resources from the remote provider and your OpenNebula, the resource one, will delete just that specific resource from the remote provider and will update the provision document accordingly.

If that not the case, please rephrase your question.

Best,
Álex.