[Ovirt-devel] cobbler removing iso (invalid image name)

Michael DeHaan mdehaan at redhat.com
Wed Feb 18 13:38:38 UTC 2009


Perry Myers wrote:
> Mike Butler wrote:
>> I seemed to have find myself encountering the same issue as 
>> referenced in this message...
>> http://www.redhat.com/archives/ovirt-devel/2009-February/msg00021.html
>> I removed a cobbler image using this syntax...
>> cobbler image remove --name=Windows_Server_2003
>> (it did remove the file from�/var/lib/cobbler/config/images.d/)
>>
>> ...then if I try to add an image or remove another I get the 
>> following error no matter what i try...
>> "invalid image name (Windows_Server_2003)"
>> When restarting the cobblerd service I get the following...
>> � raise CX(_("invalid image name (%s)") % image_name)
>> cobbler.cexceptions.CX: 'invalid image name (Windows_Server_2003)'
>> [FAILED]
>
> cc'ing Mike DeHaan since this is a cobbler issue.
>
> Perry

Ok, did some looking at the code.   What happens is you have a system 
record pointing to a image record that no longer exists.   This threw me 
previously because it sounds like it's about the image, what it is 
complaining about is the system record no longer has a parent.

(A)   Cobbler should not be allowing this when a system record still on 
the image.   This is a bug which I'll fix for 1.4.3

(B)   To actually delete the image, ovirt should be calling deletes with 
the "recursive" option in the cobbler API to delete the image or should 
otherwise point the system back at another profile before deleting it.

As a workaround, you can manually edit 
/var/lib/cobbler/config/systems.d/$name to point it back to a profile 
you have from "cobbler profile list", be sure you toggle the netboot 
enabled flag to "0" at the same time.   In general, never hand edit the 
cobbler config when you can use the tools, but this is just to get your 
configuration fixed up.


--Michael




More information about the ovirt-devel mailing list