Re: [one-users] how to overload context for one specific vm in oneflow template
Hi, On Fri, Jan 23, 2015 at 2:06 PM, Madko madk...@gmail.com wrote: We'd like to have 4 VMs 1 VM with role LVS, no problem here, using a lvs VM template 3 VM with role WEB, using a web VM template. I need to set explicitly their hostnames, no digit allowed (let's say obfuscated-vm-name-a, obfuscated-vm-name-b and obfuscated-vm-name-ab) how do I set each hostname in the service template? I think the best option is to have one role for each VM. My guess is that if we came up with a new generic syntax to define a vm_template_contents for each VM, it would probably be just as inconvenient as having one Role per VM. But for your specific case, maybe you can define a string with a list of hostnames, e.g. : host_a,host_b,host_c And then create a context script to coordinate which hostname has to be set for each instance. The onegate component [1] may be useful for this. Regards. [1] http://docs.opennebula.org/4.10/advanced_administration/application_flow_and_auto-scaling/appflow_use_cli.html#sharing-information-between-vms -- Carlos Martín, MSc Project Engineer OpenNebula - Flexible Enterprise Cloud Made Simple www.OpenNebula.org http://www.opennebula.org/ | cmar...@opennebula.org | @OpenNebula http://twitter.com/opennebula On Fri, Jan 23, 2015 at 2:06 PM, Madko madk...@gmail.com wrote: Sorry I don't think it fit our use case. We'd like to have 4 VMs 1 VM with role LVS, no problem here, using a lvs VM template 3 VM with role WEB, using a web VM template. I need to set explicitly their hostnames, no digit allowed (let's say obfuscated-vm-name-a, obfuscated-vm-name-b and obfuscated-vm-name-ab) how do I set each hostname in the service template? Le Fri Jan 23 2015 at 12:11:07, Carlos Martín Sánchez cmar...@opennebula.org a écrit : Hi there, On Thu, Jan 22, 2015 at 2:18 PM, Madko madk...@gmail.com wrote: How do you set hostname to VMs inside roles when you can't use numeric hostname (ie hostname%i)? You can use the VM ID inside the context, the following works for me: CONTEXT = [ HOSTNAME = TEST_$VMID ] Or the VM name. This VM name can be changed the vm_name_template option in oneflow-server.conf [1]. CONTEXT = [ HOSTNAME = $NAME ] Does it fit your use case? Regards [1] http://docs.opennebula.org/4.10/advanced_administration/application_flow_and_auto-scaling/appflow_configure.html -- Carlos Martín, MSc Project Engineer OpenNebula - Flexible Enterprise Cloud Made Simple www.OpenNebula.org | cmar...@opennebula.org | @OpenNebula http://twitter.com/opennebula cmar...@opennebula.org On Thu, Jan 22, 2015 at 2:18 PM, Madko madk...@gmail.com wrote: That's what we were doing untill now, service template with 10 or more VM and therefor 10 or more roles (1:1 ratio) are not really convenient. But thanks for your suggestion. Maybe I'm missing something. Is it possible to change vm_template_contents to some sort of array? How do you set hostname to VMs inside roles when you can't use numeric hostname (ie hostname%i)? best regards Le Thu Jan 22 2015 at 11:25:29, Carlos Martín Sánchez cmar...@opennebula.org a écrit : Hi, On Wed, Jan 21, 2015 at 3:29 PM, Madko madk...@gmail.com wrote: Hi, is there a way to overload the vm_template_contents of only one specific VM in a role? I'd like to fix the hostnames. I only manage to overload the context of all the VMs in one role. best regards, Maybe you can create a new role with the same template, and cardinality 1. Would that work for you? Regards -- Carlos Martín, MSc Project Engineer OpenNebula - Flexible Enterprise Cloud Made Simple www.OpenNebula.org http://www.opennebula.org/ | cmar...@opennebula.org | @OpenNebula http://twitter.com/opennebula cmar...@opennebula.org ___ Users mailing list Users@lists.opennebula.org http://lists.opennebula.org/listinfo.cgi/users-opennebula.org
Re: [one-users] Users Digest, Vol 83, Issue 27
Hello, I will be out of the office starting Monday January, 19 2015 returning on Wednesday January, 29 2015. During this time I will have limited phone and email. If you are currently experiencing an outage and need immediate assistance, please call/email Chris Eldridge at (603) 498-9921 / celdri...@nessit.net. Thank you, Geoff Ness ___ Users mailing list Users@lists.opennebula.org http://lists.opennebula.org/listinfo.cgi/users-opennebula.org
Re: [one-users] Setting filesystem type for new disk crashes GlusterFS
Hi, There seems to be a problem with sparse files and glusterfs and/or the underlying FS (XFS?). No, it's only in combination with mkfs. Creating sparse files without a preset filesystem (i.e. raw images) works perfectly. By the way: How did you figure out that XFS is used? Is it known to produce problems? In addition to your suggestions, I experimented with overriding the filesystem type setting by setting FSTYPE = raw in /var/lib/one/remotes/tm/shared/mkimage. As far as I tested, that worked as well. However, we recently upgraded to Ubuntu 14.04 and GlusterFS 3.4.2. Now the bug seems to be gone. Thanks anyway! Greetings Wilma 2015-01-22 10:10 GMT+01:00 Javier Fontan jfon...@opennebula.org: There seems to be a problem with sparse files and glusterfs and/or the underlying FS (XFS?). You can disable that functionality adding an exit 1 command at the top of these scripts: * /var/lib/one/remotes/datastore/mkfs * /var/lib/one/remotes/tm/mkimage Another way of solving this is changing the what the image is created (so it is not sparse). The problem is that it will take a lot more time to create the image. The commad to change is 'dd' from those scripts. For example, for 'mkfs': exec_and_log $DD if=/dev/zero of=$DST bs=1 count=1 seek=${SIZE}M \ Could not create image $DST to exec_and_log $DD if=/dev/zero of=$DST bs=1M count=${SIZE} \ Could not create image $DST Cheers On Sat, Jan 17, 2015 at 10:43 AM, Wilma Hermann wilma.herm...@gmail.com wrote: Hi, Our OpenNebula setup uses GlusterFS to share /var/lib/one among all machines. Yesterday a customer created a new volatile disk for a VM. But this image creation crashed the gluster client on the host the VM was running on. I assume it has something to do with the fact that the customer entered 'ext3' as filesystem type. This isn't the first time this bug occured, we also had it almost one year ago and there it was also related to the filesystem type of an image. I believe that this feature is rarely used by our customers and simply wasn't used in the meantime. Now we are using OpenNebula 4.8.0 on Ubuntu 12.04.5 with glusterfs 3.2.5. Here's the log of the VM that triggered the crash: Sat Jan 10 13:24:21 2015 [Z0][VMM][I]: VM successfully rebooted-hard. Fri Jan 16 17:31:00 2015 [Z0][VMM][I]: Command execution fail: /var/lib/one/remotes/tm/shared/mkimage 51200 ext3 192.168.128.14:/var/lib/one//datastores/0/346/disk.2 346 0 Fri Jan 16 17:31:00 2015 [Z0][VMM][I]: mkimage: Making filesystem of 51200M and type ext3 at 192.168.128.14:/var/lib/one//datastores/0/346/disk.2 Fri Jan 16 17:31:00 2015 [Z0][VMM][E]: mkimage: Command set -e Fri Jan 16 17:31:00 2015 [Z0][VMM][I]: export PATH=/usr/sbin:/sbin:$PATH Fri Jan 16 17:31:00 2015 [Z0][VMM][I]: dd if=/dev/zero of=/var/lib/one/datastores/0/346/disk.2 bs=1 count=1 seek=51200M Fri Jan 16 17:31:00 2015 [Z0][VMM][I]: mkfs -t ext3 -F /var/lib/one/datastores/0/346/disk.2 failed: Warning: Permanently added '192.168.128.14' (ECDSA) to the list of known hosts. Fri Jan 16 17:31:00 2015 [Z0][VMM][I]: 1+0 records in Fri Jan 16 17:31:00 2015 [Z0][VMM][I]: 1+0 records out Fri Jan 16 17:31:00 2015 [Z0][VMM][I]: 1 byte (1 B) copied, 0.000576409 s, 1.7 kB/s Fri Jan 16 17:31:00 2015 [Z0][VMM][I]: mke2fs 1.42 (29-Nov-2011) Fri Jan 16 17:31:00 2015 [Z0][VMM][I]: Warning: could not erase sector 2: Attempt to write block to filesystem resulted in short write Fri Jan 16 17:31:00 2015 [Z0][VMM][I]: Warning: could not read block 0: Attempt to read block from filesystem resulted in short read Fri Jan 16 17:31:00 2015 [Z0][VMM][I]: Warning: could not erase sector 0: Attempt to write block to filesystem resulted in short write Fri Jan 16 17:31:00 2015 [Z0][VMM][I]: mkfs.ext3: Attempt to write block to filesystem resulted in short write while zeroing block 13107184 at end of filesystem Fri Jan 16 17:31:00 2015 [Z0][VMM][I]: Fri Jan 16 17:31:00 2015 [Z0][VMM][I]: Could not write 5 blocks in inode table starting at 1027: Attempt to write block to filesystem resulted in short write Fri Jan 16 17:31:00 2015 [Z0][VMM][E]: Could not create image /var/lib/one/datastores/0/346/disk.2 Fri Jan 16 17:31:00 2015 [Z0][VMM][I]: ExitCode: 1 Fri Jan 16 17:31:00 2015 [Z0][VMM][I]: Failed to execute transfer manager driver operation: tm_attach. Fri Jan 16 17:31:00 2015 [Z0][VMM][E]: Error attaching new VM Disk: Could not create image /var/lib/one/datastores/0/346/disk.2 After that crash all subsequent operations fail because the frontend was unable to log into that particular host (since /var/lib/one was missing and passwordless SSH did not work anymore). I have 2 questions: 1) Does anyone have an idea what's going on there? 2) Is it possible to disable this filesystem type feature. We don't need it, but I would like to prevent these accidental host crashes. Greetings Wilma