[one-users] Template instantiation failed - Problems managing deployment files

Carlos Jiménez cjimenez at eneotecnologia.com
Thu Aug 23 03:09:35 PDT 2012


Hello,

Thank you André for your reply.
I checked oneadmin user/group ownership in /var/lib/one directory and 
its contents (datastore included). All directories and files were 
correctly owned.
[root at host1 10]# ls -la
drwxrwxr-x. 2 oneadmin oneadmin      4096 Aug 23 10:38 .
drwxr-xr-x. 4 oneadmin oneadmin      4096 Aug 23 10:38 ..
lrwxrwxrwx. 1 oneadmin oneadmin        42 Aug 23 10:38 disk.0 -> 
../../100/07e46220fd4ecd3f8400861bf8f0d5b4
-rw-rw----. 1 oneadmin oneadmin 130252800 Aug 23 10:53 disk.1

After your e-mail I've checked NFS Server and added the no_root_squash 
option to the directory I'm exporting via nfs. This is the result:
/var/lib/one 192.168.180.0/255.255.255.0(rw,no_root_squash,sync)

After reloading nfs changes, I've tried to create a new VM and I get the 
same results: PROLOG and then FAILED status. This is the output of the log:
Thu Aug 23 10:59:05 2012 [DiM][I]: New VM state is ACTIVE.
Thu Aug 23 10:59:05 2012 [LCM][I]: New VM state is PROLOG.
Thu Aug 23 10:59:05 2012 [VM][I]: Virtual Machine has no context
Thu Aug 23 10:59:18 2012 [TM][I]: ln: Linking 
../../100/07e46220fd4ecd3f8400861bf8f0d5b4 in 
Host2:/var/lib/one//datastores/0/12/disk.0
Thu Aug 23 10:59:18 2012 [TM][I]: ExitCode: 0
Thu Aug 23 11:00:38 2012 [TM][I]: clone: Cloning 
../../100/e1b27fe18ab33781415b0b5d5b423c1c in 
Host2:/var/lib/one//datastores/0/12/disk.1
Thu Aug 23 11:00:38 2012 [TM][I]: ExitCode: 0
Thu Aug 23 11:00:39 2012 [LCM][I]: New VM state is BOOT
Thu Aug 23 11:00:39 2012 [VMM][I]: Generating deployment file: 
/var/lib/one/12/deployment.0
Thu Aug 23 11:00:39 2012 [VMM][I]: ExitCode: 0
Thu Aug 23 11:00:39 2012 [VMM][I]: Successfully execute network driver 
operation: pre.
Thu Aug 23 11:00:40 2012 [VMM][I]: Command execution fail: cat << EOT | 
/var/tmp/one/vmm/kvm/deploy /var/lib/one//datastores/0/12/deployment.0 
Host2 12 Host2
Thu Aug 23 11:00:40 2012 [VMM][I]: error: Failed to create domain from 
/var/lib/one//datastores/0/12/deployment.0
Thu Aug 23 11:00:40 2012 [VMM][I]: error: internal error process exited 
while connecting to monitor: kvm: -drive 
file=/var/lib/one//datastores/0/12/disk.0,if=none,id=drive-scsi0-0-0,format=raw: 
could not open disk image /var/lib/one//datastores/0/12/disk.0: 
Permission denied
Thu Aug 23 11:00:40 2012 [VMM][I]:
Thu Aug 23 11:00:40 2012 [VMM][E]: Could not create domain from 
/var/lib/one//datastores/0/12/deployment.0
Thu Aug 23 11:00:40 2012 [VMM][I]: ExitCode: 255
Thu Aug 23 11:00:40 2012 [VMM][I]: Failed to execute virtualization 
driver operation: deploy.
Thu Aug 23 11:00:40 2012 [VMM][E]: Error deploying virtual machine: 
Could not create domain from /var/lib/one//datastores/0/12/deployment.0
Thu Aug 23 11:00:41 2012 [DiM][I]: New VM state is FAILED

I've even modified user and group used by libvirt in /etc/libvirt/qemu.conf:
user = "oneadmin"
group = "oneadmin"

and restarted the libvirt daemon. However, the result is the same as 
previously.

Does anybody have any other idea? Could it be a problem with 
user/group/other permissions?


Thank you,

Carlos.



On 08/22/2012 03:59 PM, André Monteiro wrote:
> Hello,
> It's definetly a problem with permissions, check the path of the 
> datastore and verify owner/group! It should be oneadmin/oneadmin
>
>
> --
> André Monteiro
>
>
>
>
> On Wed, Aug 22, 2012 at 2:02 PM, Carlos Jiménez 
> <cjimenez at eneotecnologia.com <mailto:cjimenez at eneotecnologia.com>> wrote:
>
>     Hi guys,
>
>     I have a computer with OpenNebula 3.6 and CentOS 6.2 acting as a
>     frontend and two hosts computers with CentOS 6.2 and qemu-kvm. A
>     fourth computer running Debian is acting as NFS Server to share
>     /var/lib/one directory among all the computers.
>     I've configured a cluster with both hosts and a new datastore (ID
>     100).
>
>     I've created two images, one for OS and the other for the CD and a
>     new template with both images. This is the output of "onetemplate
>     show 3" command:
>     TEMPLATE 3 INFORMATION
>     ID             : 3
>     NAME           : Template2
>     USER           : oneadmin
>     GROUP          : oneadmin
>     REGISTER TIME  : 08/22 13:21:49
>
>     PERMISSIONS
>     OWNER          : um-
>     GROUP          : ---
>     OTHER          : ---
>
>     TEMPLATE CONTENTS
>     CPU="0.5"
>     DISK=[
>       IMAGE="Centos OS",
>       IMAGE_UNAME="oneadmin" ]
>     DISK=[
>       IMAGE="Centos CD",
>       IMAGE_UNAME="oneadmin" ]
>     GRAPHICS=[
>       LISTEN="0.0.0.0",
>       TYPE="vnc" ]
>     MEMORY="512"
>     NAME="Template2"
>     NIC=[
>       NETWORK="vnet2",
>       NETWORK_UNAME="oneadmin" ]
>     OS=[
>       ARCH="x86_64",
>       BOOT="cdrom" ]
>     RAW=[
>       TYPE="kvm" ]
>     TEMPLATE_ID="3"
>
>     Once I instantiate the template, after a while with the status of
>     PROLOG, it changes to FAILED.
>
>     This is the log:
>
>     Wed Aug 22 14:24:39 2012 [DiM][I]: New VM state is ACTIVE.
>     Wed Aug 22 14:24:40 2012 [LCM][I]: New VM state is PROLOG.
>     Wed Aug 22 14:24:40 2012 [VM][I]: Virtual Machine has no context
>     Wed Aug 22 14:24:40 2012 [TM][I]: ln: Linking ../../100/07e46220fd4ecd3f8400861bf8f0d5b4 in Host2:/var/lib/one//datastores/0/10/disk.0
>     Wed Aug 22 14:24:40 2012 [TM][I]: ExitCode: 0
>     Wed Aug 22 14:25:13 2012 [TM][I]: clone: Cloning ../../100/e1b27fe18ab33781415b0b5d5b423c1c in Host2:/var/lib/one//datastores/0/10/disk.1
>     Wed Aug 22 14:25:13 2012 [TM][I]: ExitCode: 0
>     Wed Aug 22 14:25:14 2012 [LCM][I]: New VM state is BOOT
>     Wed Aug 22 14:25:14 2012 [VMM][I]: Generating deployment file: /var/lib/one/10/deployment.0
>     Wed Aug 22 14:25:14 2012 [VMM][I]: ExitCode: 0
>     Wed Aug 22 14:25:14 2012 [VMM][I]: Successfully execute network driver operation: pre.
>     Wed Aug 22 14:25:15 2012 [VMM][I]: Command execution fail: cat << EOT | /var/tmp/one/vmm/kvm/deploy /var/lib/one//datastores/0/10/deployment.0 Host2 10 Host2
>     Wed Aug 22 14:25:15 2012 [VMM][I]: error: Failed to create domain from /var/lib/one//datastores/0/10/deployment.0
>     Wed Aug 22 14:25:15 2012 [VMM][I]: error: failed to open file '/var/lib/one//datastores/0/10/disk.1': Permission denied
>     Wed Aug 22 14:25:15 2012 [VMM][E]: Could not create domain from /var/lib/one//datastores/0/10/deployment.0
>     Wed Aug 22 14:25:15 2012 [VMM][I]: ExitCode: 255
>     Wed Aug 22 14:25:15 2012 [VMM][I]: Failed to execute virtualization driver operation: deploy.
>     Wed Aug 22 14:25:15 2012 [VMM][E]: Error deploying virtual machine: Could not create domain from /var/lib/one//datastores/0/10/deployment.0
>     Wed Aug 22 14:25:16 2012 [DiM][I]: New VM state is FAILED
>
>
>     I suppose there are several problems: VM has no context and
>     another issues with deployment.0 and disk.1 files.
>     In the contextualization part, I suppose it is due to the lack of
>     "CONTEXT" section so I'll work on it, but could you help me with
>     the other errors?
>
>
>     Thank you,
>
>     Carlos.
>
>     _______________________________________________
>     Users mailing list
>     Users at lists.opennebula.org <mailto:Users at lists.opennebula.org>
>     http://lists.opennebula.org/listinfo.cgi/users-opennebula.org
>
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opennebula.org/pipermail/users-opennebula.org/attachments/20120823/f2f1f380/attachment-0003.htm>


More information about the Users mailing list