[Users] engine-image-uploader and /tmp size problem on fedora18

Hello, Summary I'm testing engine-image-uploader to transport 2 vms (named infra and c2) from an environment to another one that are not interconnected. They are both 3.2.1 on fedora 18 (the second one is all-in-one) I have problems with engine-image-uploader at destination, due to not enough space in /tmp the error is: # engine-image-uploader -e EXP_DOMAIN upload /data/users/gcecchi/c2_and_infra.ovf Please provide the REST API password for the admin@internal oVirt Engine user (CTRL+D to abort): ERROR: Not enough space in /tmp: 11648Mb are needed. But on fedora 18 /tmp is on tmpfs in ram by default and so it is on my system.... so I would like to tweak this path.... how? Details: At first site I created an export domain and exported these vms after shutdown them. Under master/vms ./master/vms: total 8 drwxr-xr-x. 2 vdsm kvm 4096 Apr 30 23:42 42197b2d-3e64-4587-97e7-4d91e1d71b62 drwxr-xr-x. 2 vdsm kvm 4096 May 1 00:04 5fa80246-64a3-401b-9ba3-2e1e04ff0413 ./master/vms/42197b2d-3e64-4587-97e7-4d91e1d71b62: total 8 -rw-r--r--. 1 vdsm kvm 7867 Apr 30 23:42 42197b2d-3e64-4587-97e7-4d91e1d71b62.ovf ./master/vms/5fa80246-64a3-401b-9ba3-2e1e04ff0413: total 12 -rw-r--r--. 1 vdsm kvm 8951 May 1 00:04 5fa80246-64a3-401b-9ba3-2e1e04ff0413.ovf Under images ./images: total 8 drwxr-xr-x. 2 vdsm kvm 4096 Apr 30 23:41 3cf2c068-0fcc-49e3-9939-5aaeb96de2ed drwxr-xr-x. 2 vdsm kvm 4096 May 1 00:00 fd0659b0-c75b-433b-8866-13cb6218bf81 ./images/3cf2c068-0fcc-49e3-9939-5aaeb96de2ed: total 3145736 -rw-rw----. 1 vdsm kvm 3221225472 Apr 30 23:42 0fa86f2f-9b5c-4e72-861e-104920846d0b -rw-r--r--. 1 vdsm kvm 268 Apr 30 23:41 0fa86f2f-9b5c-4e72-861e-104920846d0b.meta ./images/fd0659b0-c75b-433b-8866-13cb6218bf81: total 8781832 -rw-rw----. 1 vdsm kvm 8992587776 May 1 00:04 679c2055-9b5b-47d7-94ff-04d543282f74 -rw-r--r--. 1 vdsm kvm 268 May 1 00:00 679c2055-9b5b-47d7-94ff-04d543282f74.meta So I have c2 ovf <--> 42197b2d-3e64-4587-97e7-4d91e1d71b62.ovf images <---> 3cf2c068-0fcc-49e3-9939-5aaeb96de2ed infra ovf <--> 5fa80246-64a3-401b-9ba3-2e1e04ff0413.ovf images <---> fd0659b0-c75b-433b-8866-13cb6218bf81 I created the compressed ovf archive that is about 6Gb On the all-in-one target environment (that is 6Gb in ram) after providing the ovf file I run the upload command. The configuration is: export domain EXP_DOMAIN on /data/export_domain with Filesystem Size Used Avail Use% Mounted on /dev/sdb6 305G 234G 68G 78% /data and tekkaman.localdomain.local:/data/export_domain 305G 234G 68G 78% /rhev/data-center/mnt/tekkaman.localdomain.local:_data_export__domain Other filesystems information: $ df -h Filesystem Size Used Avail Use% Mounted on devtmpfs 2.9G 0 2.9G 0% /dev tmpfs 3.0G 156K 3.0G 1% /dev/shm tmpfs 3.0G 5.1M 3.0G 1% /run tmpfs 3.0G 0 3.0G 0% /sys/fs/cgroup /dev/mapper/fedora-root 53G 33G 18G 65% / tmpfs 3.0G 68K 3.0G 1% /tmp /dev/sda1 477M 99M 353M 22% /boot ... tekkaman.localdomain.local:/ISO 53G 33G 18G 65% /rhev/data-center/mnt/tekkaman.localdomain.local:_ISO During upload I notice this strange addition in df command output: Filesystem Size Used Avail Use% Mounted on ... tekkaman.localdomain.local:/data/export_domain 305G 236G 66G 79% /tmp/tmpORTazo But after sometime I get the error and also the same in /var/log/ovirt-engine/engine-image-uploader.log 2013-05-01 17:28:41::ERROR::engine-image-uploader::1221::root:: Not enough space in /tmp: 11648Mb are needed. Is there a way to change this path? Also because in fedora 18 by default it is a tmpfs file system.... Thanks, Gianluca

----- Original Message -----
From: "Gianluca Cecchi" <gianluca.cecchi@gmail.com> To: "users" <users@ovirt.org> Sent: Wednesday, May 1, 2013 6:51:33 PM Subject: [Users] engine-image-uploader and /tmp size problem on fedora18
Hello,
Summary I'm testing engine-image-uploader to transport 2 vms (named infra and c2) from an environment to another one that are not interconnected. They are both 3.2.1 on fedora 18 (the second one is all-in-one) I have problems with engine-image-uploader at destination, due to not enough space in /tmp
the error is: # engine-image-uploader -e EXP_DOMAIN upload /data/users/gcecchi/c2_and_infra.ovf Please provide the REST API password for the admin@internal oVirt Engine user (CTRL+D to abort): ERROR: Not enough space in /tmp: 11648Mb are needed.
But on fedora 18 /tmp is on tmpfs in ram by default and so it is on my system.... so I would like to tweak this path.... how?
Try: TMPDIR=/var/tmp engine-image-uploader -e EXP_DOMAIN upload ...
Details: At first site I created an export domain and exported these vms after shutdown them.
Under master/vms ./master/vms: total 8 drwxr-xr-x. 2 vdsm kvm 4096 Apr 30 23:42 42197b2d-3e64-4587-97e7-4d91e1d71b62 drwxr-xr-x. 2 vdsm kvm 4096 May 1 00:04 5fa80246-64a3-401b-9ba3-2e1e04ff0413
./master/vms/42197b2d-3e64-4587-97e7-4d91e1d71b62: total 8 -rw-r--r--. 1 vdsm kvm 7867 Apr 30 23:42 42197b2d-3e64-4587-97e7-4d91e1d71b62.ovf
./master/vms/5fa80246-64a3-401b-9ba3-2e1e04ff0413: total 12 -rw-r--r--. 1 vdsm kvm 8951 May 1 00:04 5fa80246-64a3-401b-9ba3-2e1e04ff0413.ovf
Under images ./images: total 8 drwxr-xr-x. 2 vdsm kvm 4096 Apr 30 23:41 3cf2c068-0fcc-49e3-9939-5aaeb96de2ed drwxr-xr-x. 2 vdsm kvm 4096 May 1 00:00 fd0659b0-c75b-433b-8866-13cb6218bf81
./images/3cf2c068-0fcc-49e3-9939-5aaeb96de2ed: total 3145736 -rw-rw----. 1 vdsm kvm 3221225472 Apr 30 23:42 0fa86f2f-9b5c-4e72-861e-104920846d0b -rw-r--r--. 1 vdsm kvm 268 Apr 30 23:41 0fa86f2f-9b5c-4e72-861e-104920846d0b.meta
./images/fd0659b0-c75b-433b-8866-13cb6218bf81: total 8781832 -rw-rw----. 1 vdsm kvm 8992587776 May 1 00:04 679c2055-9b5b-47d7-94ff-04d543282f74 -rw-r--r--. 1 vdsm kvm 268 May 1 00:00 679c2055-9b5b-47d7-94ff-04d543282f74.meta
So I have c2 ovf <--> 42197b2d-3e64-4587-97e7-4d91e1d71b62.ovf images <---> 3cf2c068-0fcc-49e3-9939-5aaeb96de2ed
infra ovf <--> 5fa80246-64a3-401b-9ba3-2e1e04ff0413.ovf images <---> fd0659b0-c75b-433b-8866-13cb6218bf81
I created the compressed ovf archive that is about 6Gb
On the all-in-one target environment (that is 6Gb in ram) after providing the ovf file I run the upload command.
The configuration is:
export domain EXP_DOMAIN on /data/export_domain with Filesystem Size Used Avail Use% Mounted on /dev/sdb6 305G 234G 68G 78% /data
and tekkaman.localdomain.local:/data/export_domain 305G 234G 68G 78% /rhev/data-center/mnt/tekkaman.localdomain.local:_data_export__domain
Other filesystems information:
$ df -h Filesystem Size Used Avail Use% Mounted on devtmpfs 2.9G 0 2.9G 0% /dev tmpfs 3.0G 156K 3.0G 1% /dev/shm tmpfs 3.0G 5.1M 3.0G 1% /run tmpfs 3.0G 0 3.0G 0% /sys/fs/cgroup /dev/mapper/fedora-root 53G 33G 18G 65% / tmpfs 3.0G 68K 3.0G 1% /tmp /dev/sda1 477M 99M 353M 22% /boot ... tekkaman.localdomain.local:/ISO 53G 33G 18G 65% /rhev/data-center/mnt/tekkaman.localdomain.local:_ISO
During upload I notice this strange addition in df command output: Filesystem Size Used Avail Use% Mounted on ... tekkaman.localdomain.local:/data/export_domain 305G 236G 66G 79% /tmp/tmpORTazo
But after sometime I get the error and also the same in
/var/log/ovirt-engine/engine-image-uploader.log
2013-05-01 17:28:41::ERROR::engine-image-uploader::1221::root:: Not enough space in /tmp: 11648Mb are needed.
Is there a way to change this path? Also because in fedora 18 by default it is a tmpfs file system....
Thanks, Gianluca _______________________________________________ Users mailing list Users@ovirt.org http://lists.ovirt.org/mailman/listinfo/users

On Wed, May 1, 2013 at 5:59 PM, Alon Bar-Lev wrote:
Try:
TMPDIR=/var/tmp engine-image-uploader -e EXP_DOMAIN upload ...
OK. it worked. Thanks I noticed that in engine-image-uploader there is this definition mount_dir = tempfile.mkdtemp() and in python manual tempfile.mkdtemp([suffix=''[, prefix='tmp'[, dir=None]]]) It could be useful to create a parameter to put in config file (/etc/ovirt-engine/imageuploader.conf by default) so that one can set "dir=" ... or make a reference in manual page. I notice that only one of the two VMs contained in the .ovf archive was uploaded (c2). Does engine-image-uploader support more than one VM in ovf file or do I need to leave inside it only the files related to one VM at a time? Gianluca

----- Original Message -----
From: "Gianluca Cecchi" <gianluca.cecchi@gmail.com> To: "Alon Bar-Lev" <alonbl@redhat.com> Cc: "users" <users@ovirt.org> Sent: Wednesday, May 1, 2013 7:42:35 PM Subject: Re: [Users] engine-image-uploader and /tmp size problem on fedora18
On Wed, May 1, 2013 at 5:59 PM, Alon Bar-Lev wrote:
Try:
TMPDIR=/var/tmp engine-image-uploader -e EXP_DOMAIN upload ...
OK. it worked. Thanks I noticed that in engine-image-uploader there is this definition
mount_dir = tempfile.mkdtemp()
and in python manual tempfile.mkdtemp([suffix=''[, prefix='tmp'[, dir=None]]])
It could be useful to create a parameter to put in config file (/etc/ovirt-engine/imageuploader.conf by default) so that one can set "dir=" ... or make a reference in manual page.
I think that best is to allow overriding the TMPDIR.
I notice that only one of the two VMs contained in the .ovf archive was uploaded (c2). Does engine-image-uploader support more than one VM in ovf file or do I need to leave inside it only the files related to one VM at a time?
Gianluca

On Wed, May 1, 2013 at 6:47 PM, Alon Bar-Lev wrote:
I notice that only one of the two VMs contained in the .ovf archive was uploaded (c2). Does engine-image-uploader support more than one VM in ovf file or do I need to leave inside it only the files related to one VM at a time?
Gianluca
Ok. I extracted the ovf and removed the files of one VM (c2) and then created a new ovf and was able to upload the other VM now (infra) I was also able to import the VM, add a nic to it and start ok on the new infrastructure. SO far so good. This way implies power off of the source VM. Is there a way to export a running VM or is it on the roadmap? Or some way to make a snapshot of a running VM and export it without powering down the original VM? Thanks, Gianluca

On 05/02/2013 01:10 AM, Gianluca Cecchi wrote:
On Wed, May 1, 2013 at 6:47 PM, Alon Bar-Lev wrote:
I notice that only one of the two VMs contained in the .ovf archive was uploaded (c2). Does engine-image-uploader support more than one VM in ovf file or do I need to leave inside it only the files related to one VM at a time?
Gianluca
Ok. I extracted the ovf and removed the files of one VM (c2) and then created a new ovf and was able to upload the other VM now (infra) I was also able to import the VM, add a nic to it and start ok on the new infrastructure.
SO far so good. This way implies power off of the source VM. Is there a way to export a running VM or is it on the roadmap? Or some way to make a snapshot of a running VM and export it without powering down the original VM?
you can take a live snapshot. i don't remember if we allow exporting a snapshot of a running VM (no technical reason not to). if we for some reason don't, you could clone the snapshot to a VM, then export that VM (ugly, so i hope we support exporting a snapshot of a running VM)

On Sun, May 12, 2013 at 3:48 PM, Itamar Heim wrote:
you can take a live snapshot. i don't remember if we allow exporting a snapshot of a running VM (no technical reason not to).
I think there is no way. I tried on 3.2.1 and after a live snapshot if you select the line of the VM, the "export" is greyed out. If I further select "Snapshots" in bottom pane, then the details pane gets the line marked with 2013-May-12, 18:03 Ok test for export already selected but there is no option to export anything... At the moment if you have only one snapshot you get two lines in "Snapshots" details pane 2013-May-12, 18:03 Ok test for export Current Ok Active VM BTW: you can sort of select all the lines but the "Active VM' one. It would be fine to have the "export' link above selectable when you select a line different from the "Active VM" one. How to officially ask to implement this or something similar to export live snapshots?
if we for some reason don't, you could clone the snapshot to a VM, then export that VM (ugly, so i hope we support exporting a snapshot of a running VM)
yes, ugly and not feasible in my opinion. Thanks, Gianluca

----- Original Message -----
From: "Gianluca Cecchi" <gianluca.cecchi@gmail.com> To: "Itamar Heim" <iheim@redhat.com> Cc: "Alon Bar-Lev" <alonbl@redhat.com>, "users" <users@ovirt.org>, "Omer Frenkel" <ofrenkel@redhat.com> Sent: Sunday, May 12, 2013 7:14:00 PM Subject: Re: [Users] engine-image-uploader and /tmp size problem on fedora18
On Sun, May 12, 2013 at 3:48 PM, Itamar Heim wrote:
you can take a live snapshot. i don't remember if we allow exporting a snapshot of a running VM (no technical reason not to).
I think there is no way. I tried on 3.2.1 and after a live snapshot if you select the line of the VM, the "export" is greyed out. If I further select "Snapshots" in bottom pane, then the details pane gets the line marked with
2013-May-12, 18:03 Ok test for export
already selected but there is no option to export anything... At the moment if you have only one snapshot you get two lines in "Snapshots" details pane
2013-May-12, 18:03 Ok test for export Current Ok Active VM
BTW: you can sort of select all the lines but the "Active VM' one. It would be fine to have the "export' link above selectable when you select a line different from the "Active VM" one. How to officially ask to implement this or something similar to export live snapshots?
if we for some reason don't, you could clone the snapshot to a VM, then export that VM (ugly, so i hope we support exporting a snapshot of a running VM)
yes, ugly and not feasible in my opinion.
yes but tested it's possible.
Thanks, Gianluca
participants (4)
-
Alon Bar-Lev
-
Gianluca Cecchi
-
Itamar Heim
-
Omer Frenkel