LVM DS in 5.0.2

Hi! I Have FC SAN and 2 LUN each 2TB on it. Read doc and try create LVM DS without clvm. Create all how in manula but this not working. I create vg-one-110 and vg-one-111

SYSTEM DS - normal 2TB
IMAGE DS - only 50GB.

Try create 100GB IMAGE - [ImageAllocate] Not enough space in datastore.

onedatastore list
ID NAME SIZE AVAIL CLUSTERS IMAGES TYPE DS TM STAT
0 system - - 0 0 sys - ssh off
110 SAN 2T 100% 0 0 sys - fs_lvm on
111 IMAGES 50G 94% 0 1 img fs fs_lvm on

log.

Sat Aug 27 09:26:41 2016 [Z0][VM][I]: New LCM state is PROLOG
Sat Aug 27 09:26:42 2016 [Z0][TM][I]: Command execution fail: /var/lib/one/remotes/tm/fs_lvm/clone node03:/var/lib/one//datastores/111/4ab694b1f7bbf342a2d6a705b828d571 node03:/var/lib/one//datastores/0/5/disk.0 5 111
Sat Aug 27 09:26:42 2016 [Z0][TM][I]: cat: /var/lib/one/datastores/111/4ab694b1f7bbf342a2d6a705b828d571: No such file or directory
Sat Aug 27 09:26:42 2016 [Z0][TM][I]: stat: cannot stat ‘/var/lib/one/datastores/111/4ab694b1f7bbf342a2d6a705b828d571’: No such file or directory
Sat Aug 27 09:26:42 2016 [Z0][TM][E]: clone: Command " set -e
Sat Aug 27 09:26:42 2016 [Z0][TM][I]: mkdir -p /var/lib/one/datastores/0/5
Sat Aug 27 09:26:42 2016 [Z0][TM][I]:
Sat Aug 27 09:26:42 2016 [Z0][TM][I]: sudo lvcreate -L2252M -n lv-one-5-0 vg-one-0
Sat Aug 27 09:26:42 2016 [Z0][TM][I]: qemu-img convert -O raw “/var/lib/one/datastores/111/4ab694b1f7bbf342a2d6a705b828d571” "/dev/vg-one-0/lv-one-5-0"
Sat Aug 27 09:26:42 2016 [Z0][TM][I]: rm -f "/var/lib/one/datastores/0/5/disk.0"
Sat Aug 27 09:26:42 2016 [Z0][TM][I]: ln -s “/dev/vg-one-0/lv-one-5-0” “/var/lib/one/datastores/0/5/disk.0"” failed: Volume group “vg-one-0” not found
Sat Aug 27 09:26:42 2016 [Z0][TM][E]: Error cloning /var/lib/one/datastores/111/4ab694b1f7bbf342a2d6a705b828d571 to lv-one-5-0
Sat Aug 27 09:26:42 2016 [Z0][TM][I]: ExitCode: 5
Sat Aug 27 09:26:42 2016 [Z0][TM][E]: Error executing image transfer script: Error cloning /var/lib/one/datastores/111/4ab694b1f7bbf342a2d6a705b828d571 to lv-one-5-0
Sat Aug 27 09:26:42 2016 [Z0][VM][I]: New LCM state is PROLOG_FAILURE

Why nebula try use vg-one-0? VG vg-one-0 not present in my system!

What I do wrong?

Thanks!

Hi

The VM is deployed on the ‘system’ datastore instead on the ‘SAN’ datastore. You could try to define a cluster with only the needed resources included - datastores: SYS, IMAGES, files; hosts: needed hosts; Network neede networks.

Kind Regards,
Anton Todorov

Hi, when you use FS_LVM driver, you have to name your volume groups by following convention:

vg-one-{DS_ID}

Hi! I do this. I have vg-one-110 and vg-one-111. And DS_ID 110 and 111

And not work? I personaly use block lvm driver with clvm, but what I read from docs, i understand it, that you have to some filesystem ds for holding images. When vm is deployed, it just copy that image to fs_lvm ds. I dont know about persisteent images, so I rather used clvm and gfs2. So I have block lvm driver and fs driver for qcow2 images.

I don’t want use clvm and any clustered FS.

Re-install Opennebula. Have 3 node. node1 - sunstone, node2 and 3 - compute. LUN 2T connect to all nodes. Try to deploq VMs. Some VMs start, some have status FAILURE. In log:

Tue Aug 30 15:25:24 2016 [Z0][VM][I]: New LCM state is BOOT
Tue Aug 30 15:25:24 2016 [Z0][VMM][I]: Generating deployment file: /var/lib/one/vms/56/deployment.0
Tue Aug 30 15:25:24 2016 [Z0][VMM][I]: Successfully execute transfer manager driver operation: tm_context.
Tue Aug 30 15:25:25 2016 [Z0][VMM][I]: ExitCode: 0
Tue Aug 30 15:25:25 2016 [Z0][VMM][I]: Successfully execute network driver operation: pre.
Tue Aug 30 15:25:25 2016 [Z0][VMM][I]: Command execution fail: cat << EOT | /var/tmp/one/vmm/kvm/deploy ‘/var/lib/one//datastores/100/56/deployment.0’ ‘172.16.4.107’ 56 172.16.4.107
Tue Aug 30 15:25:25 2016 [Z0][VMM][I]: error: Failed to create domain from /var/lib/one//datastores/100/56/deployment.0
Tue Aug 30 15:25:25 2016 [Z0][VMM][I]: error: Cannot access storage file ‘/var/lib/one//datastores/100/56/disk.0’ (as uid:9869, gid:9869): No such file or directory
Tue Aug 30 15:25:25 2016 [Z0][VMM][E]: Could not create domain from /var/lib/one//datastores/100/56/deployment.0
Tue Aug 30 15:25:25 2016 [Z0][VMM][I]: ExitCode: 255
Tue Aug 30 15:25:25 2016 [Z0][VMM][I]: Failed to execute virtualization driver operation: deploy.
Tue Aug 30 15:25:25 2016 [Z0][VMM][E]: Error deploying virtual machine: Could not create domain from /var/lib/one//datastores/100/56/deployment.0
Tue Aug 30 15:25:25 2016 [Z0][VM][I]: New LCM state is BOOT_FAILURE

What I do wrong? I think it’s not normal.
All templates from MarketPlace.

Please post your datastore configuration what use in opennebula.

Hi @UAnton, try add BRIDGE_LIST on datastore create process.

I had similar issue, and I solve it using this param.

look my post

regards,
-Carlos

Hi! Thank you very mush for answer! I try after 3 days!

Hi! Try add BRIDGE_LIST on test cluster, but have same error when deploy VMs.

Sun Sep 18 11:14:07 2016 [Z0][VM][I]: New state is ACTIVE
Sun Sep 18 11:14:07 2016 [Z0][VM][I]: New LCM state is PROLOG
Sun Sep 18 11:14:08 2016 [Z0][VM][I]: New LCM state is BOOT
Sun Sep 18 11:14:08 2016 [Z0][VMM][I]: Generating deployment file: /var/lib/one/vms/96/deployment.0
Sun Sep 18 11:14:08 2016 [Z0][VMM][I]: Successfully execute transfer manager driver operation: tm_context.
Sun Sep 18 11:14:08 2016 [Z0][VMM][I]: ExitCode: 0
Sun Sep 18 11:14:08 2016 [Z0][VMM][I]: Successfully execute network driver operation: pre.
Sun Sep 18 11:14:08 2016 [Z0][VMM][I]: Command execution fail: cat << EOT | /var/tmp/one/vmm/kvm/deploy '/var/lib/one//datastores/105/96/deployment.0' 'node03' 96 node03
Sun Sep 18 11:14:08 2016 [Z0][VMM][I]: error: Failed to create domain from /var/lib/one//datastores/105/96/deployment.0
Sun Sep 18 11:14:08 2016 [Z0][VMM][I]: error: Cannot access storage file '/var/lib/one//datastores/105/96/disk.0' (as uid:9869, gid:9869): No such file or directory
Sun Sep 18 11:14:08 2016 [Z0][VMM][E]: Could not create domain from /var/lib/one//datastores/105/96/deployment.0
Sun Sep 18 11:14:08 2016 [Z0][VMM][I]: ExitCode: 255
Sun Sep 18 11:14:08 2016 [Z0][VMM][I]: Failed to execute virtualization driver operation: deploy.
Sun Sep 18 11:14:08 2016 [Z0][VMM][E]: Error deploying virtual machine: Could not create domain from /var/lib/one//datastores/105/96/deployment.0
Sun Sep 18 11:14:08 2016 [Z0][VM][I]: New LCM state is BOOT_FAILURE

It’s trying to find a disk, not an LV, this looks like there is a problem in the datastore definition file, particularly the DISK_TYPE in the system datastore.