[one-users] call one.image.allocate xml-rpc API, the new image file can't be created

liudewei liudewei at neusoft.com
Sun Mar 27 19:26:35 PDT 2011


Hi,All

When I call one.image.allocate of  xml-rpc API ,the new image file can't be created .
but,oneimage register is no problem!

 oneimage list command ,the following:

 35 oneadmin         0328_mkImg_1   OS   Mar 28, 2011 02:12 Yes  No disa     0 
  
 oneimage show 35, the f
IMAGE  INFORMATION                                                              
ID             : 35                  
NAME           : 0328_mkImg_1        
TYPE           : OS                  
REGISTER TIME  : 03/28 10:12:57      
PUBLIC         : Yes                 
PERSISTENT     : No                  
SOURCE         : /opt/nebula/images/afa5ebb70546e3786197e607b4092f1e13c5a5e4
STATE          : disa                
RUNNING_VMS    : 0                   
IMAGE TEMPLATE                                                                  
DESCRIPTION=0328_mkImg_1 desc
DEV_PREFIX=hd
NAME=0328_mkImg_1
PATH=/one_images/8/images/disk.0
TYPE=OS
ollowing:
  
 the file name is "afa5ebb70546e3786197e607b4092f1e13c5a5e4", the directory " /opt/nebula/images" has not the file!;

 I packing the image template String is :
 
StringBuffer template = new StringBuffer();
template.append("NAME=").append("\"").append(name).append("\"").append("\n"); 
template.append("DESCRIPTION=").append("\"").append(desc).append("\"").append("\n");
template.append("PUBLIC = ").append("YES").append("\n"); 
template.append("TYPE=").append("OS").append("\n"); 
template.append("PERSISTENT=").append("NO").append("\n"); 
template.append("DEV_PREFIX=").append("\"hd\"").append("\n"); // 可选. 
//template.append("BUS=").append("").append("\n"); 
template.append("PATH=").append("/one_images/").append(vminfo.getVmId()).append("/images/disk.0").append("\n"); 
     
opennebula.org document say:
When a new image template is allocated, the core will insert the image in the system in DISABLED state. The developer has to request the extended information for the new image, and copy (or create) the file to the SOURCE attribute (added by the core). After the file is copied (or created), the image has to be enabled. 
but the file is not created, Why? oneimage register is ok!

     Thank for your answering!

Hope to get quickly reply!

Thanks and Regars!
david.
 
2011-03-28 



liudewei 
---------------------------------------------------------------------------------------------------
Confidentiality Notice: The information contained in this e-mail and any accompanying attachment(s) 
is intended only for the use of the intended recipient and may be confidential and/or privileged of 
Neusoft Corporation, its subsidiaries and/or its affiliates. If any reader of this communication is 
not the intended recipient, unauthorized use, forwarding, printing,  storing, disclosure or copying 
is strictly prohibited, and may be unlawful.If you have received this communication in error,please 
immediately notify the sender by return e-mail, and delete the original message and all copies from 
your system. Thank you. 
---------------------------------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opennebula.org/pipermail/users-opennebula.org/attachments/20110328/1e1735e0/attachment-0002.htm>


More information about the Users mailing list