Re: [ovirt-users] [ovirt-shell] update hostnic/nic ???

2016-01-15 Thread Bloemen , Jurriën

On 15-01-16 12:20, Juan Hernández wrote:

On 01/14/2016 01:28 PM, Bloemen, Jurriën wrote:



On 14-01-16 12:16, Juan Hernández wrote:


On 01/14/2016 11:24 AM, Bloemen, Jurriën wrote:


Hi,

First I created a bonding interface:

# add nic --parent-host-name server01 --name bond0 --network-name
VLAN602 --bonding-slaves-host_nic host_nic.name=eno1
--bonding-slaves-host_nic host_nic.name=eno2

This works great but no IP is set on VLAN602.

Then I'm trying to add an ip address to a network with the following
command:

# update hostnic --parent-host-name server01 --network-name VLAN602
--boot_protocol static --ip-address 10.10.10.10 --ip-netmask 255.255.255.0

==
ERROR


wrong number of arguments, try 'help update' for help.


Looking at this document
https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Virtualization/3.6-Beta/html/RHEVM_Shell_Guide/nic.html
I need to use "nic" instead of "hostnic" but then I don't have the
options to say this is a --parent-host-name. Only VM related command
options.

So I think the documentation is behind.

Can somebody help me with what the command is to add a IP to a
VLAN/Network for a host?




The command should be like this:

  # update nic bond0 --parent-host-name server01 --network-name VLAN602
--boot_protocol static --ip-address 10.10.10.10 --ip-netmask 255.255.255.0

Note that the it is "nic" instead of "hostnic" and that you need to
specify the name of that NIC, in this case "bond0".

The command will work if you type it like that, but auto-completion
won't work. This is a bug in the CLI, indirectly caused by the fact that
the name of the URL segment used in the RESTAPI is "nics" (from
/hosts/{host:id}/*nics*) but the name of the XML schema complex type is
"HostNIC".



Thanks! That works!

Another question:

Now I got the message that my network is out-of-sync. How can i force
within the ovirt-shell that it syncs the networks?



hmz pressed sent by accident

What I want to say is:

Now I got the message that my network is out-of-sync. How can i force
within the ovirt-shell that it syncs the networks?
Because when I press "Sync All Networks" the IP address disappears

But when I check the box "Sync Network" within the VLAN602 options it
gets pushed to the host.

Is there a difference between the both? And how do I run both via
ovirt-shell?




The "sync network" operation is not supported by ovirt-shell.

If you want to set the network configuration, and make it persistent,
then you will need to use one of the "setupNetworks" operations. These
aren't fully usable with ovirt-shell either, so if you want to use it
you will need to use directly the API or one of the SDKs. For example,
lets assume that you have a host with network interfaces eth0, eth1, and
eth2, and that you want to configure eth1 and eth2 as a bond, to put
your VLAN and IP address on top. You can do that with a script like this:

---8<---
#!/bin/sh -ex

url="https://engine.example.com/ovirt-engine/api;
user="admin@internal"
password="..."

curl \
--verbose \
--cacert /etc/pki/ovirt-engine/ca.pem \
--user "${user}:${password}" \
--request POST \
--header "Content-Type: application/xml" \
--header "Accept: application/xml" \
--data '

  

  
VLAN602
  
  
bond0
  
  
static

  

  

  
  

  bond0
  

  
  


  
eth1
  
  
eth2
  

  

   
 
' \
"${url}/1ff7a191-2f3b-4eff-812b-9f91a30c3acc/setupnetworks"
--->8---

If you prefer to use one of the SDKs, the Python SDK for example, then
it should look like this:

---8<---
#!/usr/bin/python

from ovirtsdk.api import API
from ovirtsdk.xml import params

# Connect to the server:
api = API(

url="https://engine.example.com/ovirt-engine/api;,
username="admin@internal",
password="...",
ca_file="/etc/pki/ovirt-engine/ca.pem",
debug=True
)

# Find the host:
host = api.hosts.get(name="myhost")

# Set up the networks:
host.setupnetworks(
  params.Action(
modified_bonds=params.HostNics(
  host_nic=[
params.HostNIC(
  name="bond0",
  bonding=params.Bonding(
options=params.Options(
  option=[
params.Option(name="mode", value="4"),
params.Option(name="miimon", value="100"),
  ],
),

Re: [ovirt-users] Users Digest, Vol 52, Issue 87 What's going on open channel devices when migrating ...

2016-01-15 Thread Jean-Pierre Ribeauville
Hi,

Do you mean  this sleep :

 # read() returns immediately (non-blocking) if no one is
# listening on the other side of the virtio-serial port.
# So in order not to be in a tight-loop and waste CPU
# time, we just sleep for a while and hope someone will
# be there when we will awake from our nap.
time.sleep(1)


Thx.

Regards,

J..P
-Message d'origine-
De : users-boun...@ovirt.org [mailto:users-boun...@ovirt.org] De la part de 
users-requ...@ovirt.org
Envoyé : vendredi 15 janvier 2016 10:54
À : users@ovirt.org
Objet : Users Digest, Vol 52, Issue 87

Send Users mailing list submissions to
users@ovirt.org<mailto:users@ovirt.org>

To subscribe or unsubscribe via the World Wide Web, visit
http://lists.ovirt.org/mailman/listinfo/users
or, via email, send a message with subject or body 'help' to
users-requ...@ovirt.org<mailto:users-requ...@ovirt.org>

You can reach the person managing the list at
users-ow...@ovirt.org<mailto:users-ow...@ovirt.org>

When replying, please edit your Subject line so it is more specific than "Re: 
Contents of Users digest..."


Today's Topics:

   1. Re:  What's going on open channel devices whenmigrating the
  Guest ? (Vinzenz Feenstra)
   2. Re:  Scripting Guests migration , shutdown and reboot  ( from
  ovirt)  ? (Vinzenz Feenstra)


--

Message: 1
Date: Fri, 15 Jan 2016 10:51:50 +0100
From: Vinzenz Feenstra <vfeen...@redhat.com<mailto:vfeen...@redhat.com>>
To: Jean-Pierre Ribeauville 
<jpribeauvi...@axway.com<mailto:jpribeauvi...@axway.com>>
Cc: "users@ovirt.org<mailto:users@ovirt.org>" 
<users@ovirt.org<mailto:users@ovirt.org>>
Subject: Re: [ovirt-users] What's going on open channel devices when
migrating the Guest ?
Message-ID: 
<90f5ce30-927a-48a3-ac82-97118a132...@redhat.com<mailto:90f5ce30-927a-48a3-ac82-97118a132...@redhat.com>>
Content-Type: text/plain; charset="utf-8"


> On Jan 15, 2016, at 10:08 AM, Jean-Pierre Ribeauville 
> <jpribeauvi...@axway.com<mailto:jpribeauvi...@axway.com>> wrote:
>
> Hi,
>
> I?m using a channel device between host and guest to exchange datas every 20 
> seconds.
>
> On the Guest size , there is an open /dev/virtio file on which we read
> continuously what?s sent by the host.
>
> My question is the following :
> When migrating the Guest to another host ,  and the migrating back to
> the first one , the Guest software doesn?t receive anymore datas from the 
> host unless I restart the Guest software to re-open the /dev/virtio file.
>
> Is there any way to detect in the Guest that migration has been done so we 
> have to reopen  the file ?

Well you can look how we do it in the ovirt-guest-agent. But we?re not 
reopening the unix domain socket - We?re basically on read failure just 
rescheduling the read - That causes no problems after migrations - it just 
continues

Our python code for that is here: 
https://github.com/oVirt/ovirt-guest-agent/blob/master/ovirt-guest-agent/VirtIoChannel.py

HTH

>
> Any hint is welcome .
>
> Thanks for help.
>
>
> J.P. Ribeauville
>
> P: +33.(0).1.47.17.20.49
> .
> Puteaux 3 Etage 5  Bureau 4
>
> jpribeauvi...@axway.com<mailto:jpribeauvi...@axway.com> 
> <mailto:jpribeauvi...@axway.com>
> http://www.axway.com <http://www.axway.com/>
>
> P Pensez ? l?environnement avant d?imprimer.
>
>
> ___
> Users mailing list
> Users@ovirt.org<mailto:Users@ovirt.org> <mailto:Users@ovirt.org>
> http://lists.ovirt.org/mailman/listinfo/users
> <http://lists.ovirt.org/mailman/listinfo/users>
-- next part --
An HTML attachment was scrubbed...
URL: 
<http://lists.ovirt.org/pipermail/users/attachments/20160115/6d80a2e0/attachment-0001.html>

--

Message: 2
Date: Fri, 15 Jan 2016 10:53:31 +0100
From: Vinzenz Feenstra <vfeen...@redhat.com<mailto:vfeen...@redhat.com>>
To: Jean-Pierre Ribeauville 
<jpribeauvi...@axway.com<mailto:jpribeauvi...@axway.com>>
Cc: "users@ovirt.org<mailto:users@ovirt.org>" 
<users@ovirt.org<mailto:users@ovirt.org>>
Subject: Re: [ovirt-users] Scripting Guests migration , shutdown and
reboot  ( from ovirt)  ?
Message-ID: 
<2fabd1e6-4148-452a-b854-7cbd84cf7...@redhat.com<mailto:2fabd1e6-4148-452a-b854-7cbd84cf7...@redhat.com>>
Content-Type: text/plain; charset="utf-8"


> On Jan 15, 2016, at 9:53 AM, Jean-Pierre Ribeauville 
> <jpribeauvi...@axway.com<mailto:jpribeauvi...@axway.com>> wrote:
>
> Hi,
>
> In order to test reliabilit

Re: [ovirt-users] [ovirt-shell] update hostnic/nic ???

2016-01-15 Thread Juan Hernández
On 01/14/2016 01:28 PM, Bloemen, Jurriën wrote:
>>
>> On 14-01-16 12:16, Juan Hernández wrote:
>>> On 01/14/2016 11:24 AM, Bloemen, Jurriën wrote:
 Hi,

 First I created a bonding interface:

 # add nic --parent-host-name server01 --name bond0 --network-name
 VLAN602 --bonding-slaves-host_nic host_nic.name=eno1
 --bonding-slaves-host_nic host_nic.name=eno2

 This works great but no IP is set on VLAN602.

 Then I'm trying to add an ip address to a network with the following
 command:

 # update hostnic --parent-host-name server01 --network-name VLAN602
 --boot_protocol static --ip-address 10.10.10.10 --ip-netmask 255.255.255.0

 ==
 ERROR
 


 wrong number of arguments, try 'help update' for help.
 

 Looking at this document
 https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Virtualization/3.6-Beta/html/RHEVM_Shell_Guide/nic.html
 I need to use "nic" instead of "hostnic" but then I don't have the
 options to say this is a --parent-host-name. Only VM related command
 options.

 So I think the documentation is behind.

 Can somebody help me with what the command is to add a IP to a
 VLAN/Network for a host?


>>> The command should be like this:
>>>
>>>   # update nic bond0 --parent-host-name server01 --network-name VLAN602
>>> --boot_protocol static --ip-address 10.10.10.10 --ip-netmask 255.255.255.0
>>>
>>> Note that the it is "nic" instead of "hostnic" and that you need to
>>> specify the name of that NIC, in this case "bond0".
>>>
>>> The command will work if you type it like that, but auto-completion
>>> won't work. This is a bug in the CLI, indirectly caused by the fact that
>>> the name of the URL segment used in the RESTAPI is "nics" (from
>>> /hosts/{host:id}/*nics*) but the name of the XML schema complex type is
>>> "HostNIC".
>>>
>> Thanks! That works!
>>
>> Another question:
>>
>> Now I got the message that my network is out-of-sync. How can i force
>> within the ovirt-shell that it syncs the networks?
> 
> hmz pressed sent by accident
> 
> What I want to say is:
> 
> Now I got the message that my network is out-of-sync. How can i force
> within the ovirt-shell that it syncs the networks?
> Because when I press "Sync All Networks" the IP address disappears
> 
> But when I check the box "Sync Network" within the VLAN602 options it
> gets pushed to the host.
> 
> Is there a difference between the both? And how do I run both via
> ovirt-shell?
> 

The "sync network" operation is not supported by ovirt-shell.

If you want to set the network configuration, and make it persistent,
then you will need to use one of the "setupNetworks" operations. These
aren't fully usable with ovirt-shell either, so if you want to use it
you will need to use directly the API or one of the SDKs. For example,
lets assume that you have a host with network interfaces eth0, eth1, and
eth2, and that you want to configure eth1 and eth2 as a bond, to put
your VLAN and IP address on top. You can do that with a script like this:

---8<---
#!/bin/sh -ex

url="https://engine.example.com/ovirt-engine/api;
user="admin@internal"
password="..."

curl \
--verbose \
--cacert /etc/pki/ovirt-engine/ca.pem \
--user "${user}:${password}" \
--request POST \
--header "Content-Type: application/xml" \
--header "Accept: application/xml" \
--data '

  

  
VLAN602
  
  
bond0
  
  
static

  

  

  
  

  bond0
  

  
  


  
eth1
  
  
eth2
  

  

   
 
' \
"${url}/1ff7a191-2f3b-4eff-812b-9f91a30c3acc/setupnetworks"
--->8---

If you prefer to use one of the SDKs, the Python SDK for example, then
it should look like this:

---8<---
#!/usr/bin/python

from ovirtsdk.api import API
from ovirtsdk.xml import params

# Connect to the server:
api = API(
url="https://engine.example.com/ovirt-engine/api;,
username="admin@internal",
password="...",
ca_file="/etc/pki/ovirt-engine/ca.pem",
debug=True
)

# Find the host:
host = api.hosts.get(name="myhost")

# Set up the networks:
host.setupnetworks(
  params.Action(
modified_bonds=params.HostNics(
  host_nic=[
params.HostNIC(
  name="bond0",
  bonding=params.Bonding(

Re: [ovirt-users] [BUG] Cannot remove quota

2016-01-15 Thread Ondra Machacek

One possible way is to change DataCenter quota mode to Disabled.
Then you can remove quota which is assigned to vm.

On 01/15/2016 10:41 AM, zhangjian2011 wrote:


HI, all:

  I found that if the quota is applied to a VM,

then the quota can’t be remove. (Even if I change DataCenter to Audit Mode)

  the screenshot as below:

  NOW I found the workaround is delete vm.

  How can I remove the quota  without delete the VM



___
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users


___
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users


[ovirt-users] have to run gluster peer detach to remove a host form a gluster cluster.

2016-01-15 Thread Nathanaël Blanchet



Hi all,

When I want to remove an host from a gluster cluster, engines tells me
that it fails to remove the host.
Once I run a manual gluster peer detach , then the host is
successfully removed.
It seems to be bug, doesn't it?

--
Nathanaël Blanchet

Supervision réseau
Pôle Infrastrutures Informatiques
227 avenue Professeur-Jean-Louis-Viala
34193 MONTPELLIER CEDEX 5   
Tél. 33 (0)4 67 54 84 55
Fax  33 (0)4 67 54 84 14
blanc...@abes.fr



___
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users


[ovirt-users] adding an ip on a host that run a vm connected to that bridge

2016-01-15 Thread Nathanaël Blanchet
Why is it forbiden to add an address (static or dhcp) to bridge on a 
host that runs a vm which is connected to that bridge?
As a workaround, I can put manually an address for that bridge on that 
host and refresh capabilities.

Is it a desired feature?

--
Nathanaël Blanchet

Supervision réseau
Pôle Infrastrutures Informatiques
227 avenue Professeur-Jean-Louis-Viala
34193 MONTPELLIER CEDEX 5   
Tél. 33 (0)4 67 54 84 55
Fax  33 (0)4 67 54 84 14
blanc...@abes.fr

___
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users


[ovirt-users] Network interface profiles disappeared after upgrading to 3.6.1

2016-01-15 Thread nicolas

Hi,

We recently upgraded from 3.5.3 to 3.6.1. Everything went fairly smooth, 
however, today we realized we're facing some issues.


Users cannot add network interfaces on the User Portal to their VMs. It 
seems that when they click on "New", the "Profile" checkbox is empty so 
they cannot choose any value.


It's worth mentioning that we only upgraded the manager, not yet the 
hosts. Also, a red banner keeps popping out every few seconds with this 
error: (TypeError) __gwt$exception: : Cannot read property 'r' 
of null


It's also worth mentioning that I can add interfaces from the admin 
portal.


I don't actually know if it's related, but in the logs I see this:

2016-01-15 17:53:35,241 ERROR 
[org.ovirt.engine.core.bll.GetConfigurationValueQuery] (default 
task-165) [] Query execution failed due to insufficient permissions.
2016-01-15 17:53:35,241 ERROR 
[org.ovirt.engine.api.restapi.resource.AbstractBackendResource] (default 
task-165) [] Operation Failed: query execution failed due to 
insufficient permissions.


All interfaces have the "Everyone" -> "UserProfileEditor" permission.

Is that some new permission that has to be granted in order to allow 
users see the network interfaces or is it a bug?


Thanks.

Nicolás

___
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users


Re: [ovirt-users] Network interface profiles disappeared after upgrading to 3.6.1

2016-01-15 Thread nicolas

In the JavaScript console I see this:

Fri Jan 15 18:38:17 GMT+000 2016
SEVERE: Uncaught exception: 
com.google.gwt.core.client.JavaScriptException: (TypeError)

 __gwt$exception: : NMk(...) is null
at Unknown.POm(Unknown Source)
at Unknown.ZFk(Unknown Source)
at Unknown.aGk(Unknown Source)
at Unknown.SJk(Unknown Source)
at Unknown.VJk(Unknown Source)
at Unknown.yIk(Unknown Source)
at Unknown.BIk(Unknown Source)
at Unknown.bTc(Unknown Source)
at Unknown.B6h(Unknown Source)
at Unknown.VS(Unknown Source)
at Unknown.mT(Unknown Source)
at Unknown.jAd/c.onreadystatechange<(Unknown Source)
at Unknown.Yp(Unknown Source)
at Unknown.aq(Unknown Source)
at Unknown._p/<(Unknown Source)
at Unknown.anonymous(Unknown Source)

Also tried granting the VnicProfileUser and even NetworkAdmin 
permissions, no difference. In the server.log file I could find this:


2016-01-15 18:28:53,871 ERROR [io.undertow.servlet] (default task-28) 
Exception while dispatching incoming RPC call: 
com.google.gwt.user.client.rpc.RpcTokenException: Invalid RPC token 
(Invalid XSRF token)
at 
org.ovirt.engine.ui.frontend.server.gwt.XsrfProtectedRpcServlet.validateXsrfToken(XsrfProtectedRpcServlet.java:31) 
[frontend.jar:]
at 
org.ovirt.engine.ui.frontend.server.gwt.AbstractXsrfProtectedRpcServlet.onAfterRequestDeserialized(AbstractXsrfProtectedRpcServlet.java:56) 
[frontend.jar:]
at 
com.google.gwt.rpc.server.RpcServlet.processCall(RpcServlet.java:171) 
[gwt-servlet.jar:]
at 
com.google.gwt.rpc.server.RpcServlet.processPost(RpcServlet.java:233) 
[gwt-servlet.jar:]
at 
com.google.gwt.user.server.rpc.AbstractRemoteServiceServlet.doPost(AbstractRemoteServiceServlet.java:62) 
[gwt-servlet.jar:]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:707) 
[jboss-servlet-api_3.1_spec-1.0.0.Final.jar:1.0.0.Final]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:790) 
[jboss-servlet-api_3.1_spec-1.0.0.Final.jar:1.0.0.Final]
at 
io.undertow.servlet.handlers.ServletHandler.handleRequest(ServletHandler.java:86) 
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
at 
io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:130) 
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
at 
org.ovirt.engine.core.utils.servlet.HeaderFilter.doFilter(HeaderFilter.java:94) 
[utils.jar:]
at 
io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:60) 
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
at 
io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:132) 
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
at 
org.ovirt.engine.ui.frontend.server.gwt.GwtCachingFilter.doFilter(GwtCachingFilter.java:132) 
[frontend.jar:]
at 
io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:60) 
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
at 
io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:132) 
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
at 
org.ovirt.engine.core.branding.BrandingFilter.doFilter(BrandingFilter.java:73) 
[branding.jar:]
at 
io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:60) 
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
at 
io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:132) 
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
at 
org.ovirt.engine.core.utils.servlet.LocaleFilter.doFilter(LocaleFilter.java:65) 
[utils.jar:]
at 
io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:60) 
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
at 
io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:132) 
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
at 
org.ovirt.engine.core.aaa.filters.SessionMgmtFilter.doFilter(SessionMgmtFilter.java:31) 
[aaa.jar:]
at 
io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:60) 
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
at 
io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:132) 
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
at 
org.ovirt.engine.core.aaa.filters.LoginFilter.doFilter(LoginFilter.java:75) 
[aaa.jar:]
at 
io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:60) 
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
at 
io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:132) 
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
at 
org.ovirt.engine.core.aaa.filters.NegotiationFilter.doFilter(NegotiationFilter.java:132) 
[aaa.jar:]
at 
io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:60) 
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
 

Re: [ovirt-users] Network interface profiles disappeared after upgrading to 3.6.1

2016-01-15 Thread Einav Cohen
please file a BZ [1] on this issue with the necessary 
details as explained on the "OVirt Engine Debug 
Obfuscated UI" wiki page [2]. 
My guess is that the server side "Invalid XSRF token" 
message is not related. 


Thanks,
Einav

[1] https://bugzilla.redhat.com/enter_bug.cgi?product=ovirt-engine

[2] http://www.ovirt.org/OVirt_Engine_Debug_Obfuscated_UI

- Original Message -
> From: nico...@devels.es
> To: users@ovirt.org
> Sent: Friday, January 15, 2016 1:47:01 PM
> Subject: Re: [ovirt-users] Network interface profiles disappeared after 
> upgrading to 3.6.1
> 
> In the JavaScript console I see this:
> 
> Fri Jan 15 18:38:17 GMT+000 2016
> SEVERE: Uncaught exception:
> com.google.gwt.core.client.JavaScriptException: (TypeError)
>   __gwt$exception: : NMk(...) is null
>   at Unknown.POm(Unknown Source)
>   at Unknown.ZFk(Unknown Source)
>   at Unknown.aGk(Unknown Source)
>   at Unknown.SJk(Unknown Source)
>   at Unknown.VJk(Unknown Source)
>   at Unknown.yIk(Unknown Source)
>   at Unknown.BIk(Unknown Source)
>   at Unknown.bTc(Unknown Source)
>   at Unknown.B6h(Unknown Source)
>   at Unknown.VS(Unknown Source)
>   at Unknown.mT(Unknown Source)
>   at Unknown.jAd/c.onreadystatechange<(Unknown Source)
>   at Unknown.Yp(Unknown Source)
>   at Unknown.aq(Unknown Source)
>   at Unknown._p/<(Unknown Source)
>   at Unknown.anonymous(Unknown Source)
> 
> Also tried granting the VnicProfileUser and even NetworkAdmin
> permissions, no difference. In the server.log file I could find this:
> 
> 2016-01-15 18:28:53,871 ERROR [io.undertow.servlet] (default task-28)
> Exception while dispatching incoming RPC call:
> com.google.gwt.user.client.rpc.RpcTokenException: Invalid RPC token
> (Invalid XSRF token)
>  at
> org.ovirt.engine.ui.frontend.server.gwt.XsrfProtectedRpcServlet.validateXsrfToken(XsrfProtectedRpcServlet.java:31)
> [frontend.jar:]
>  at
> org.ovirt.engine.ui.frontend.server.gwt.AbstractXsrfProtectedRpcServlet.onAfterRequestDeserialized(AbstractXsrfProtectedRpcServlet.java:56)
> [frontend.jar:]
>  at
> com.google.gwt.rpc.server.RpcServlet.processCall(RpcServlet.java:171)
> [gwt-servlet.jar:]
>  at
> com.google.gwt.rpc.server.RpcServlet.processPost(RpcServlet.java:233)
> [gwt-servlet.jar:]
>  at
> com.google.gwt.user.server.rpc.AbstractRemoteServiceServlet.doPost(AbstractRemoteServiceServlet.java:62)
> [gwt-servlet.jar:]
>  at javax.servlet.http.HttpServlet.service(HttpServlet.java:707)
> [jboss-servlet-api_3.1_spec-1.0.0.Final.jar:1.0.0.Final]
>  at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
> [jboss-servlet-api_3.1_spec-1.0.0.Final.jar:1.0.0.Final]
>  at
> io.undertow.servlet.handlers.ServletHandler.handleRequest(ServletHandler.java:86)
> [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
>  at
> io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:130)
> [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
>  at
> org.ovirt.engine.core.utils.servlet.HeaderFilter.doFilter(HeaderFilter.java:94)
> [utils.jar:]
>  at
> io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:60)
> [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
>  at
> io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:132)
> [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
>  at
> org.ovirt.engine.ui.frontend.server.gwt.GwtCachingFilter.doFilter(GwtCachingFilter.java:132)
> [frontend.jar:]
>  at
> io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:60)
> [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
>  at
> io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:132)
> [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
>  at
> org.ovirt.engine.core.branding.BrandingFilter.doFilter(BrandingFilter.java:73)
> [branding.jar:]
>  at
> io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:60)
> [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
>  at
> io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:132)
> [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
>  at
> org.ovirt.engine.core.utils.servlet.LocaleFilter.doFilter(LocaleFilter.java:65)
> [utils.jar:]
>  at
> io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:60)
> [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
>  at
> io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:132)
> [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
>  at
> org.ovirt.engine.core.aaa.filters.SessionMgmtFilter.doFilter(SessionMgmtFilter.java:31)
> [aaa.jar:]
>  at
> io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:60)
> [undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
>  at
> 

Re: [ovirt-users] Network interface profiles disappeared after upgrading to 3.6.1

2016-01-15 Thread Nicolás
Done. For those having the same issue: 
https://bugzilla.redhat.com/show_bug.cgi?id=1299049


Regards,

Nicolás

El 15/01/16 a las 18:58, Einav Cohen escribió:

please file a BZ [1] on this issue with the necessary
details as explained on the "OVirt Engine Debug
Obfuscated UI" wiki page [2].
My guess is that the server side "Invalid XSRF token"
message is not related.


Thanks,
Einav

[1] https://bugzilla.redhat.com/enter_bug.cgi?product=ovirt-engine

[2] http://www.ovirt.org/OVirt_Engine_Debug_Obfuscated_UI

- Original Message -

From: nico...@devels.es
To: users@ovirt.org
Sent: Friday, January 15, 2016 1:47:01 PM
Subject: Re: [ovirt-users] Network interface profiles disappeared after 
upgrading to 3.6.1

In the JavaScript console I see this:

Fri Jan 15 18:38:17 GMT+000 2016
SEVERE: Uncaught exception:
com.google.gwt.core.client.JavaScriptException: (TypeError)
   __gwt$exception: : NMk(...) is null
at Unknown.POm(Unknown Source)
at Unknown.ZFk(Unknown Source)
at Unknown.aGk(Unknown Source)
at Unknown.SJk(Unknown Source)
at Unknown.VJk(Unknown Source)
at Unknown.yIk(Unknown Source)
at Unknown.BIk(Unknown Source)
at Unknown.bTc(Unknown Source)
at Unknown.B6h(Unknown Source)
at Unknown.VS(Unknown Source)
at Unknown.mT(Unknown Source)
at Unknown.jAd/c.onreadystatechange<(Unknown Source)
at Unknown.Yp(Unknown Source)
at Unknown.aq(Unknown Source)
at Unknown._p/<(Unknown Source)
at Unknown.anonymous(Unknown Source)

Also tried granting the VnicProfileUser and even NetworkAdmin
permissions, no difference. In the server.log file I could find this:

2016-01-15 18:28:53,871 ERROR [io.undertow.servlet] (default task-28)
Exception while dispatching incoming RPC call:
com.google.gwt.user.client.rpc.RpcTokenException: Invalid RPC token
(Invalid XSRF token)
  at
org.ovirt.engine.ui.frontend.server.gwt.XsrfProtectedRpcServlet.validateXsrfToken(XsrfProtectedRpcServlet.java:31)
[frontend.jar:]
  at
org.ovirt.engine.ui.frontend.server.gwt.AbstractXsrfProtectedRpcServlet.onAfterRequestDeserialized(AbstractXsrfProtectedRpcServlet.java:56)
[frontend.jar:]
  at
com.google.gwt.rpc.server.RpcServlet.processCall(RpcServlet.java:171)
[gwt-servlet.jar:]
  at
com.google.gwt.rpc.server.RpcServlet.processPost(RpcServlet.java:233)
[gwt-servlet.jar:]
  at
com.google.gwt.user.server.rpc.AbstractRemoteServiceServlet.doPost(AbstractRemoteServiceServlet.java:62)
[gwt-servlet.jar:]
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:707)
[jboss-servlet-api_3.1_spec-1.0.0.Final.jar:1.0.0.Final]
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
[jboss-servlet-api_3.1_spec-1.0.0.Final.jar:1.0.0.Final]
  at
io.undertow.servlet.handlers.ServletHandler.handleRequest(ServletHandler.java:86)
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
  at
io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:130)
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
  at
org.ovirt.engine.core.utils.servlet.HeaderFilter.doFilter(HeaderFilter.java:94)
[utils.jar:]
  at
io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:60)
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
  at
io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:132)
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
  at
org.ovirt.engine.ui.frontend.server.gwt.GwtCachingFilter.doFilter(GwtCachingFilter.java:132)
[frontend.jar:]
  at
io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:60)
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
  at
io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:132)
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
  at
org.ovirt.engine.core.branding.BrandingFilter.doFilter(BrandingFilter.java:73)
[branding.jar:]
  at
io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:60)
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
  at
io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:132)
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
  at
org.ovirt.engine.core.utils.servlet.LocaleFilter.doFilter(LocaleFilter.java:65)
[utils.jar:]
  at
io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:60)
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
  at
io.undertow.servlet.handlers.FilterHandler$FilterChainImpl.doFilter(FilterHandler.java:132)
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
  at
org.ovirt.engine.core.aaa.filters.SessionMgmtFilter.doFilter(SessionMgmtFilter.java:31)
[aaa.jar:]
  at
io.undertow.servlet.core.ManagedFilter.doFilter(ManagedFilter.java:60)
[undertow-servlet-1.1.8.Final.jar:1.1.8.Final]
  at

Re: [ovirt-users] Python API question

2016-01-15 Thread Colin Coe
Hi again all

I've just noticed that the snapshot status appears not to update.

Consider the code below:
---
api.vms.get(VM_NAME).snapshots.add(params.Snapshot(description=SNAPSHOT_NAME,
vm=api.vms.get(VM_NAME), persist_memorystate=True))

# Wait for snapshot to finish
snap = api.vms.get(name=VM_NAME).snapshots.list()[-1]
while (snap.get_snapshot_status() == 'locked'):
   print "Waiting for snapshot creation to finish (status is %s)" %
snap.get_snapshot_status()
---

What I find is that even though the WebUI reports the snapshot is created,
snap.get_snapshot_status() still reports 'locked'.

I'm using RHEV 3.5.7 with RHEL-H 7.1 hosts with vdsm-4.16.30-1.el7ev.x86_64.

Am I misunderstanding how this works or have I found a bug?

Thanks

On Fri, Jan 15, 2016 at 6:04 PM, Juan Hernández  wrote:

> On 01/15/2016 05:23 AM, Colin Coe wrote:
> > Hi all
> >
> > I've written a Python script to take nightly snapshots of VMs which are
> > kept for x days.  After x days the snapshot is deleted.
> >
> > I can't work out how to wait for the snapshot deletion to complete.  I
> > know how to do it for creating the snapshot but I've not been able to
> > get it right for the deletion.
> >
> >
> >
> api.vms.get(VM_NAME).snapshots.add(params.Snapshot(description=SNAPSHOT_NAME,
> > vm=api.vms.get(VM_NAME), persist_memorystate=True))
> >   while api.vms.get(VM_NAME).status.state == 'image_locked':
> >   sleep(1)
> >
> > Any ideas?
> >
> > Thanks
> >
> > CC
> >
> >
>
> The more reliable way to wait till the snapshot is effectively deleted
> is just to try to get it, and finish when the result is "None":
>
>   snapshot.delete()
>
>   while vm.snapshots.get(id=snapshot.get_id()) is not None:
> sleep(1)
>
> Alternatively you can use the return of the delete operation. It returns
> an "Action" object, that contains a reference to the job that was
> started to delete the snapshot. The XML representation looks like this:
>
>   
>  id="f6e4279a-a8e1-44a3-86db-d53336b0eb5a"/>
> 
>   complete
> 
>   
>
> As you can see that contains a link to the job. With the Python SDK you
> can use it as follows:
>
>   # Get the id of the job:
>   action = snapshot.delete()
>   job_id = action.get_job().get_id()
>
>   # Wait till the job is finished:
>   while api.jobs.get(id=job_id).get_status().get_state() != 'FINISHED':
> time.sleep(1)
>
> This is less reliable, because actions may or may not return a job, and
> that depends on how the action is implemented in the engine, and there
> is no backwards compatibility guarantee for that. A minor change in the
> engine may result in the job not being returned.
>
> So my suggestion is to use the simple loop to check if the snapshot exists.
>
> --
> Dirección Comercial: C/Jose Bardasano Baos, 9, Edif. Gorbea 3, planta
> 3ºD, 28016 Madrid, Spain
> Inscrita en el Reg. Mercantil de Madrid – C.I.F. B82657941 - Red Hat S.L.
>
___
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users


[ovirt-users] Default profile

2016-01-15 Thread Colin Coe
Hi all

Is it possible to set the default profile (on the User Portal login page
and for all users) to the AD domain name rather than "Internal"?

Also, can the "Connect Automatically" check box (on the User Portal login
page) be set to default to un-checked?

Running RHEV 3.5

Thanks

CC
___
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users


Re: [ovirt-users] Default profile

2016-01-15 Thread Oved Ourfali
On Jan 16, 2016 9:00 AM, "Colin Coe"  wrote:
>
> Hi all
>
> Is it possible to set the default profile (on the User Portal login page
and for all users) to the AD domain name rather than "Internal"?
>

As far as I know it remembers that per the user, so first time you login it
will remember that.

> Also, can the "Connect Automatically" check box (on the User Portal login
page) be set to default to un-checked?
>

Not in 3.5.
I think Ravi did some changes around that in 3.6, but not sure. I think it
isn't available in 3.6 as well.
Ravi?

> Running RHEV 3.5
>
> Thanks
>
> CC
>
> ___
> Users mailing list
> Users@ovirt.org
> http://lists.ovirt.org/mailman/listinfo/users
>
___
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users


Re: [ovirt-users] Default profile

2016-01-15 Thread Colin Coe
Hi and thanks for the quick response!

The profile is only remembered in the browser cache.  Most of our VDI users
use IGEL thin clients in SPICE appliance mode.  This means they have to
remember to set the profile every time they login. For our remaining users
connecting from standard PCs if their profile deleted (the "help" desk's
first move if there is a problem on the PC) or if they connect from a
difference PC they also have to set the profile.

I'll put in a request to GSS for this as a feature request.

Thanks again

CC

On Sat, Jan 16, 2016 at 3:50 PM, Oved Ourfali  wrote:

>
> On Jan 16, 2016 9:00 AM, "Colin Coe"  wrote:
> >
> > Hi all
> >
> > Is it possible to set the default profile (on the User Portal login page
> and for all users) to the AD domain name rather than "Internal"?
> >
>
> As far as I know it remembers that per the user, so first time you login
> it will remember that.
>
> > Also, can the "Connect Automatically" check box (on the User Portal
> login page) be set to default to un-checked?
> >
>
> Not in 3.5.
> I think Ravi did some changes around that in 3.6, but not sure. I think it
> isn't available in 3.6 as well.
> Ravi?
>
> > Running RHEV 3.5
> >
> > Thanks
> >
> > CC
> >
> > ___
> > Users mailing list
> > Users@ovirt.org
> > http://lists.ovirt.org/mailman/listinfo/users
> >
>
___
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users


[ovirt-users] Scripting Guests migration , shutdown and reboot ( from ovirt) ?

2016-01-15 Thread Jean-Pierre Ribeauville
Hi,

In order to test reliability   of some of my softwares running on Guest and 
Hosts, I would like to script
from RHEV-M manager host , via command line interface, sequences for rebooting 
, migrate and shutdown/run KVM Guests.

What's your hint to achieve this ?


I cannot use virsh on the host cos theses domains are transient ones , so they 
disappear from the host  virsh list as soon as they are off.


Thx for your help.

Regards,

J.P. Ribeauville


P: +33.(0).1.47.17.20.49
.
Puteaux 3 Etage 5  Bureau 4

jpribeauvi...@axway.com
http://www.axway.com



P Pensez à l'environnement avant d'imprimer.



___
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users


[ovirt-users] What's going on open channel devices when migrating the Guest ?

2016-01-15 Thread Jean-Pierre Ribeauville
Hi,

I'm using a channel device between host and guest to exchange datas every 20 
seconds.

On the Guest size , there is an open /dev/virtio file on which we read 
continuously what's
sent by the host.

My question is the following :
When migrating the Guest to another host ,  and the migrating back to the first 
one ,
the Guest software doesn't receive anymore datas from the host unless I restart 
the Guest software to re-open the /dev/virtio file.

Is there any way to detect in the Guest that migration has been done so we have 
to reopen  the file ?

Any hint is welcome .

Thanks for help.


J.P. Ribeauville


P: +33.(0).1.47.17.20.49
.
Puteaux 3 Etage 5  Bureau 4

jpribeauvi...@axway.com
http://www.axway.com



P Pensez à l'environnement avant d'imprimer.



___
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users


Re: [ovirt-users] AAA/ldap/3.6 Issues - WARNING [ovirt-engine-extension-aaa-ldap.authn::LDAP-authn] Cannot initialize LDAP framework, deferring initialization.

2016-01-15 Thread Ondra Machacek

Hi,

if I read your logs correctly than you are using IPv6 and no IPv4, right?
ovirt-engine-extension-aaa-ldap-setup was designed to be easy
and support only very basic setups, so there is not support to properly 
configure it.


If the above is true, you have two options, which should help you.
1)
Do what you did below, and apply the configuration, then add to file:
/etc/ovirt-engine/aaa/ldap-test-server.properties
this line:
pool.default.socketfactory.resolver.supportIPv6 = true

2)
In question: "Use DNS (Yes, No) [Yes]:"
answer "no"

Hope it will help you,
Ondra

On 01/15/2016 05:50 AM, David LeVene wrote:

Hey,

I’m running into an issue which I’m not sure where to go from here. I’m
trying to use LDAP authentication and am following the setup guide from
here

https://gerrit.ovirt.org/gitweb?p=ovirt-engine-extension-aaa-ldap.git;a=blob;f=README;hb=HEAD

I have tested the ldap credentials manually using ldapsearch, and I get
results as expected with the user I’m binding with - but when I use
ovirt I run into problems.

I hope someone can provide me some guidance, or other things to try!

DNS resolves;

Can manually do  ldap lookups using ldapsearch

Can telnet to hostname 389 successfully

Below are the steps taken;

# ovirt-engine-extension-aaa-ldap-setup

[ INFO  ] Stage: Initializing

[ INFO  ] Stage: Environment setup

   Configuration files:
['/etc/ovirt-engine-extension-aaa-ldap-setup.conf.d/10-packaging.conf']

   Log file:
/tmp/ovirt-engine-extension-aaa-ldap-setup-20160115151231-o0d7hp.log

   Version: otopi-1.4.0 (otopi-1.4.0-1.el7.centos)

[ INFO  ] Stage: Environment packages setup

[ INFO  ] Stage: Programs detection

[ INFO  ] Stage: Environment customization

   Welcome to LDAP extension configuration program

   Please specify profile name that will be visible to users: LDAP

   Available LDAP implementations:

1 - 389ds

2 - 389ds RFC-2307 Schema

3 - Active Directory

4 - IPA

5 - Novell eDirectory RFC-2307 Schema

6 - OpenLDAP RFC-2307 Schema

7 - OpenLDAP Standard Schema

8 - Oracle Unified Directory RFC-2307 Schema

9 - RFC-2307 Schema (Generic)

   10 - RHDS

   11 - RHDS RFC-2307 Schema

   12 - iPlanet

   Please select: 1

   NOTE:

   It is highly recommended to use DNS resolution for LDAP server.

   If for some reason you intend to use hosts or plain address
disable DNS usage.

   Use DNS (Yes, No) [Yes]:

   Available policy method:

1 - Single server

2 - DNS domain LDAP SRV record

3 - Round-robin between multiple hosts

4 - Failover between multiple hosts

   Please select: 1

   Please enter host address: ldap-test-server

[ INFO  ] Trying to resolve host 'ldap-test-server'

   NOTE:

   It is highly recommended to use secure protocol to access the
LDAP server.

   Protocol startTLS is the standard recommended method to do so.

   Only in cases in which the startTLS is not supported,
fallback to non standard ldaps protocol.

   Use plain for test environments only.

   Please select protocol to use (startTLS, ldaps, plain)
[startTLS]: plain

[ INFO  ] Connecting to LDAP using 'ldap://ldap-test-server:389'

[ INFO  ] Connection succeeded

   Enter search user DN (empty for anonymous):
uid=ovirt-test,ou=Special Users,dc=test

   Enter search user password:

[ INFO  ] Attempting to bind using 'uid=ovirt-test,ou=Special Users,dc=test'

[ INFO  ] Stage: Setup validation

   NOTE:

   It is highly recommended to test drive the configuration
before applying it into engine.

   Perform at least one Login sequence and one Search sequence.

   Select test sequence to execute (Done, Abort, Login, Search)
[Abort]: Login

   Enter search user name: uid=ovirt-test,ou=Special Users,dc=test

   Enter search user password:

[ INFO  ] Executing login sequence...

   Login output:

   2016-01-15 15:13:25 INFO


   2016-01-15 15:13:25 INFO
Initialization 

   2016-01-15 15:13:25 INFO


   2016-01-15 15:13:25 INFOLoading extension 'LDAP-authn'

   2016-01-15 15:13:25 INFOExtension 'LDAP-authn' loaded

   2016-01-15 15:13:25 INFOLoading extension 'LDAP-authz'

   2016-01-15 15:13:25 INFOExtension 'LDAP-authz' loaded

   2016-01-15 15:13:25 INFOInitializing extension 'LDAP-authn'

   2016-01-15 15:13:25 INFO
[ovirt-engine-extension-aaa-ldap.authn::LDAP-authn] Creating LDAP pool
'authz'

   

Re: [ovirt-users] What's going on open channel devices when migrating the Guest ?

2016-01-15 Thread Vinzenz Feenstra

> On Jan 15, 2016, at 10:08 AM, Jean-Pierre Ribeauville 
>  wrote:
> 
> Hi,
>  
> I’m using a channel device between host and guest to exchange datas every 20 
> seconds.
>  
> On the Guest size , there is an open /dev/virtio file on which we read 
> continuously what’s 
> sent by the host.
>  
> My question is the following : 
> When migrating the Guest to another host ,  and the migrating back to the 
> first one ,  
> the Guest software doesn’t receive anymore datas from the host unless I 
> restart the Guest software to re-open the /dev/virtio file.
>  
> Is there any way to detect in the Guest that migration has been done so we 
> have to reopen  the file ?

Well you can look how we do it in the ovirt-guest-agent. But we’re not 
reopening the unix domain socket - We’re basically on read failure just 
rescheduling the read - That causes no problems after migrations - it just 
continues 

Our python code for that is here: 
https://github.com/oVirt/ovirt-guest-agent/blob/master/ovirt-guest-agent/VirtIoChannel.py

HTH

>  
> Any hint is welcome .
>  
> Thanks for help.
>  
>  
> J.P. Ribeauville
>  
> P: +33.(0).1.47.17.20.49
> .
> Puteaux 3 Etage 5  Bureau 4
>  
> jpribeauvi...@axway.com 
> http://www.axway.com 
>  
> P Pensez à l’environnement avant d’imprimer.
>  
>  
> ___
> Users mailing list
> Users@ovirt.org 
> http://lists.ovirt.org/mailman/listinfo/users 
> 
___
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users


Re: [ovirt-users] Scripting Guests migration , shutdown and reboot ( from ovirt) ?

2016-01-15 Thread Vinzenz Feenstra

> On Jan 15, 2016, at 9:53 AM, Jean-Pierre Ribeauville 
>  wrote:
> 
> Hi,
>  
> In order to test reliability   of some of my softwares running on Guest and 
> Hosts, I would like to script
> from RHEV-M manager host , via command line interface, sequences for 
> rebooting , migrate and shutdown/run KVM Guests.
>  
> What’s your hint to achieve this ?

Well you could use the Python SDK http://www.ovirt.org/Python-sdk

>  
>  
> I cannot use virsh on the host cos theses domains are transient ones , so 
> they disappear from the host  virsh list as soon as they are off.
> 
>  
> Thx for your help.
>  
> Regards,
>  
> J.P. Ribeauville
>  
> P: +33.(0).1.47.17.20.49
> .
> Puteaux 3 Etage 5  Bureau 4
>  
> jpribeauvi...@axway.com 
> http://www.axway.com 
>  
> P Pensez à l’environnement avant d’imprimer.
>  
>  
> ___
> Users mailing list
> Users@ovirt.org 
> http://lists.ovirt.org/mailman/listinfo/users 
> 
___
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users


[ovirt-users] [BUG] Cannot remove quota

2016-01-15 Thread zhangjian2011


HI, all:

 I found that if the quota is applied to a VM,

then the quota can’t be remove. (Even if I change DataCenter to Audit Mode)

 the screenshot as below:

 NOW I found the workaround is delete vm.

 How can I remove the quota  without delete the VM



___
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users


[ovirt-users] NIC Out of Sync

2016-01-15 Thread Bloemen , Jurriën
Hi all,

I got the following situation:

[cid:part1.05080201.06050205@dmc.amcnetworks.com]

This can easily be fixed via the webinterface but I need to script this via the 
ovirt-shell.

I found the following but this does not do the trick:

ovirt-shell # action host twinp108 commitnetconfig

Well it saves the config but the out-of-sync icon remains.

Do I need to set a boolean first or something?
Is there another way of fixing this because all the documentation I found does 
not cover this?

--
Kind regards,

Jurriën

This message (including any attachments) may contain information that is 
privileged or confidential. If you are not the intended recipient, please 
notify the sender and delete this email immediately from your systems and 
destroy all copies of it. You may not, directly or indirectly, use, disclose, 
distribute, print or copy this email or any part of it if you are not the 
intended recipient
___
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users


Re: [ovirt-users] Python API question

2016-01-15 Thread Juan Hernández
On 01/15/2016 05:23 AM, Colin Coe wrote:
> Hi all
> 
> I've written a Python script to take nightly snapshots of VMs which are
> kept for x days.  After x days the snapshot is deleted.
> 
> I can't work out how to wait for the snapshot deletion to complete.  I
> know how to do it for creating the snapshot but I've not been able to
> get it right for the deletion.
> 
>  
> api.vms.get(VM_NAME).snapshots.add(params.Snapshot(description=SNAPSHOT_NAME,
> vm=api.vms.get(VM_NAME), persist_memorystate=True))
>   while api.vms.get(VM_NAME).status.state == 'image_locked':
>   sleep(1)
> 
> Any ideas?
> 
> Thanks
> 
> CC
> 
> 

The more reliable way to wait till the snapshot is effectively deleted
is just to try to get it, and finish when the result is "None":

  snapshot.delete()

  while vm.snapshots.get(id=snapshot.get_id()) is not None:
sleep(1)

Alternatively you can use the return of the delete operation. It returns
an "Action" object, that contains a reference to the job that was
started to delete the snapshot. The XML representation looks like this:

  


  complete

  

As you can see that contains a link to the job. With the Python SDK you
can use it as follows:

  # Get the id of the job:
  action = snapshot.delete()
  job_id = action.get_job().get_id()

  # Wait till the job is finished:
  while api.jobs.get(id=job_id).get_status().get_state() != 'FINISHED':
time.sleep(1)

This is less reliable, because actions may or may not return a job, and
that depends on how the action is implemented in the engine, and there
is no backwards compatibility guarantee for that. A minor change in the
engine may result in the job not being returned.

So my suggestion is to use the simple loop to check if the snapshot exists.

-- 
Dirección Comercial: C/Jose Bardasano Baos, 9, Edif. Gorbea 3, planta
3ºD, 28016 Madrid, Spain
Inscrita en el Reg. Mercantil de Madrid – C.I.F. B82657941 - Red Hat S.L.
___
Users mailing list
Users@ovirt.org
http://lists.ovirt.org/mailman/listinfo/users