Error deleting template

rileonar

Active Member
Jul 18, 2016
8
2
43
Hi,

I've created a VM, then converted to Template.

Now I don't need it anymore, but I can't delete it.

Basically I tried to remove the disk selecting the item and clicking to "Remove".
The first time the disk has been transformed in "Unused Disk 0" (as usual when a disk is removed).
But when I try to remove the "Unused Disk 0" item I get the following error:

"rbd error: rbd: error setting snapshot context: (2) No such file or directory (500)"

What can I do to remove the template and its disk?

Many thanks in advance.

Riccardo
 
pls mark this thread as [SOLVED]

How I solved it....

VM Template to delete has ID 102 and name "to-be-deleted".
Connected to VM node and typed this command:

# cat /etc/pve/qemu-server/102.conf
bootdisk: virtio0
cores: 2
memory: 2048
name: to-be-deleted
net0: virtio=32:36:65:37:39:34,bridge=vmbr0,link_down=1
numa: 0
ostype: l26
smbios1: uuid=340a2c5e-e21c-4dd9-9561-7fec70b5f3ce
sockets: 1
template: 1
unused0: ssd:base-102-disk-1
vga: qxl

Connected to storage node and typed these commands:

# rbd info ssd/base-102-disk-1
rbd image 'base-102-disk-1':
size 10240 MB in 2560 objects
order 22 (4096 kB objects)
block_name_prefix: rbd_data.f68aa74b0dc51
format: 2
features: layering
flags:

# rados -p ssd listwatchers rbd_header.f68aa74b0dc51
watcher=192.168.60.104:0/995580311 client.1009882 cookie=1
watcher=192.168.60.104:0/995580311 client.1009882 cookie=5

# rbd rm --pool ssd base-102-disk-1
Removing image: 100% complete...done.

Then from Proxmox GUI I selected the template and hit the "Remove" button: the template is gone!

Hope This Helps....
Riccardo
 
  • Like
Reactions: atec666

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!