Re: [one-users] Create Swap locally

2013-11-16 Thread Alberto Picón Couselo

Hi, Rubén.

I will try your tips as soon as possible and I will report the results.

Best Regards and thank you very much for your help,
Alberto Picón

El 15/11/2013 10:18, Ruben S. Montero escribió:

Hi

This could be done by modifying the mkswap script from the shared 
driver. As you'll see it is just calling mkimage, so you either use 
that script for mkswap with the following modifications, or update 
mkimage so the changes will affect to all volatile disks. So my 
proposal would be:


1.- Create a local storage area in the hosts e.g. /var/scratch
2.- Update the scrtip to create the volumes in that directory
3.- Link the file in /var/scratch to the path currently used in mkimage
4.- Update the delete script so when a file linked to /var/scratch is 
deleted it'll follow the link.


Good luck,

Ruben

PS: OpenNebula 4.4 does also report storage size for system DS and 
considers the space left to make scheduling decisions. To apply this 
to 4.4 it'd need to update the monitor_ds.sh probe to report the size 
of /var/scratch.



On Thu, Nov 14, 2013 at 11:08 PM, Alberto Picón Couselo 
alpic...@gmail.com mailto:alpic...@gmail.com wrote:


Hello everybody,

Is it possible to add a swap file to a VM template that is
located/created on the fly using the local filesystem of the
hypervisor?.

I think that this feature could improve performance a lot.
Sometimes is impossible to avoid VMs to write to swap and
currently all the swap files are mounted over NFS using 0 datastore.

Can you please give me a clue to achieve this feature?

Best Regards,
Alberto Picón



___
Users mailing list
Users@lists.opennebula.org mailto:Users@lists.opennebula.org
http://lists.opennebula.org/listinfo.cgi/users-opennebula.org




--
--
Ruben S. Montero, PhD
Project co-Lead and Chief Architect
OpenNebula - Flexible Enterprise Cloud Made Simple
www.OpenNebula.org http://www.OpenNebula.org | 
rsmont...@opennebula.org mailto:rsmont...@opennebula.org | @OpenNebula



___
Users mailing list
Users@lists.opennebula.org
http://lists.opennebula.org/listinfo.cgi/users-opennebula.org


___
Users mailing list
Users@lists.opennebula.org
http://lists.opennebula.org/listinfo.cgi/users-opennebula.org


[one-users] Context CDROM seen as hard drive

2013-11-16 Thread Daniel Dehennin
Hello,

Running the debian installer with some preseed under ONE 4.2/Wheezy[1]
gives me some troubles during partitioning.

Here is my deployment.0:

#+begin_src xml
domain type='kvm' xmlns:qemu='http://libvirt.org/schemas/domain/qemu/1.0'
nameone-21/name
vcpu2/vcpu
cputune
shares512/shares
/cputune
memory524288/memory
os
type arch='x86_64'hvm/type
boot dev='hd'/
/os
devices
emulator/usr/bin/kvm/emulator
disk type='file' device='disk'
source file='/var/lib/one//datastores/0/21/disk.0'/
target dev='vda'/
driver name='qemu' type='qcow2' cache='none' 
io='threads'/
/disk
disk type='file' device='cdrom'
source file='/var/lib/one//datastores/0/21/disk.1'/
target dev='vdb'/
readonly/
driver name='qemu' type='raw'/
/disk
interface type='bridge'
source bridge='baby-gnu'/
virtualport type='openvswitch'/
mac address='02:00:0a:02:00:00'/
model type='virtio'/
/interface
graphics type='vnc' listen='0.0.0.0' port='5921' keymap='fr'/
/devices
features
acpi/
/features
/domain
#+end_src

The disk.1 is seen by Linux as a disk:

root@wheezy:/home/system# udevadm info -q env -p /block/vdb
DEVLINKS=/dev/disk/by-label/CONTEXT 
/dev/disk/by-path/pci-:00:05.0-virtio-pci-virtio2
DEVNAME=/dev/vdb
DEVPATH=/devices/pci:00/:00:05.0/virtio2/block/vdb
DEVTYPE=disk
ID_FS_LABEL=CONTEXT
ID_FS_LABEL_ENC=CONTEXT
ID_FS_TYPE=iso9660
ID_FS_USAGE=filesystem
ID_FS_VERSION=Joliet\x20Extension
ID_PATH=pci-:00:05.0-virtio-pci-virtio2
ID_PATH_TAG=pci-_00_05_0-virtio-pci-virtio2
MAJOR=254
MINOR=16
SUBSYSTEM=block
UDEV_LOG=3
USEC_INITIALIZED=2487053

It's missing the “ID_CDROM=1”.

The Debian installer is then not completely automatic since it ask to
select which disk to use.

Any hints to make it appear as a CDROM?

Regards.

Footnotes: 
[1]  libvirt-bin version 0.9.12-11+deb7u4

-- 
Daniel Dehennin
Récupérer ma clef GPG:
gpg --keyserver pgp.mit.edu --recv-keys 0x7A6FE2DF


pgpK6e6KaoIbs.pgp
Description: PGP signature
___
Users mailing list
Users@lists.opennebula.org
http://lists.opennebula.org/listinfo.cgi/users-opennebula.org