[ovirt-devel] OVS-based cluster adding vdsm report 'RTNETLINK answers: File exists' error in supervdsm.log in release 4.0.2

2016-08-09 Thread lifuqiong
Hi,
I want to test ovs in vdsm of release 4.0.2. And according Petr's 
helpful advice, created an ovs-based cluster and install vdsm to ovirt engine. 
But report a 'RTNETLINK answers: File exists' error as bellows.

It seems that vdsm want to  add a default gw through ' ip -4 route add default 
via 192.168.0.1' ; but of course this gateway already exists, why the vdsm will 
still add the default gateway? 


Error log:
-
MainProcess|jsonrpc.Executor/4::DEBUG::2016-08-02 
22:35:03,203::commands::68::root::(execCmd) /usr/bin/taskset --cpu-list 0-3 
/sbin/ip link set dev ovirtmgmt up (cwd None)
MainProcess|jsonrpc.Executor/4::DEBUG::2016-08-02 
22:35:03,205::commands::86::root::(execCmd) SUCCESS:  = '';  = 0
MainProcess|jsonrpc.Executor/4::DEBUG::2016-08-02 
22:35:03,205::commands::68::root::(execCmd) /usr/bin/taskset --cpu-list 0-3 
/sbin/ip link set dev p3p1 up (cwd None)
MainProcess|jsonrpc.Executor/4::DEBUG::2016-08-02 
22:35:03,207::commands::86::root::(execCmd) SUCCESS:  = '';  = 0
MainProcess|jsonrpc.Executor/4::DEBUG::2016-08-02 
22:35:03,207::commands::68::root::(execCmd) /usr/bin/taskset --cpu-list 0-3 
/sbin/ip addr flush dev ovirtmgmt scope global (cwd None)
MainProcess|jsonrpc.Executor/4::DEBUG::2016-08-02 
22:35:03,209::commands::86::root::(execCmd) SUCCESS:  = '';  = 0
MainProcess|jsonrpc.Executor/4::DEBUG::2016-08-02 
22:35:03,209::commands::68::root::(execCmd) /usr/bin/taskset --cpu-list 0-3 
/sbin/ip -4 addr add dev ovirtmgmt 192.168.0.117/255.255.255.0 (cwd None)
MainProcess|jsonrpc.Executor/4::DEBUG::2016-08-02 
22:35:03,211::commands::86::root::(execCmd) SUCCESS:  = '';  = 0
MainProcess|jsonrpc.Executor/4::DEBUG::2016-08-02 
22:35:03,211::commands::68::root::(execCmd) /usr/bin/taskset --cpu-list 0-3 
/sbin/ip -4 route add default via 192.168.0.1 (cwd None)
MainProcess|jsonrpc.Executor/4::DEBUG::2016-08-02 
22:35:03,213::commands::86::root::(execCmd) FAILED:  = 'RTNETLINK answers: 
File exists\n';  = 2
MainProcess|jsonrpc.Executor/4::DEBUG::2016-08-02 
22:35:03,213::api::246::root::(setupNetworks) Setting up network according to 
configuration: networks:{u'ovirtmgmt': {'remove': True}}, bondings:{}, 
options:{'connectivityCheck': 0, 'inRollback': True}
MainProcess|jsonrpc.Executor/4::DEBUG::2016-08-02 
22:35:03,213::api::267::root::(_setup_networks) Validating configuration
MainProcess|jsonrpc.Executor/4::DEBUG::2016-08-02 
22:35:03,216::routes::75::root::(get_gateway) The gateway 192.168.0.1 is 
duplicated for the device p3p1

MainProcess|jsonrpc.Executor/4::ERROR::2016-08-02 
22:35:03,310::supervdsmServer::96::SuperVdsm.ServerCallback::(wrapper) Error in 
setupNetworks
Traceback (most recent call last):
  File "/usr/share/vdsm/supervdsmServer", line 94, in wrapper
res = func(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/vdsm/network/api.py", line 248, in 
setupNetworks
_setup_networks(networks, bondings, options)
  File "/usr/lib/python2.7/site-packages/vdsm/network/api.py", line 275, in 
_setup_networks
netswitch.setup(networks, bondings, options, in_rollback)
  File "/usr/lib64/python2.7/contextlib.py", line 35, in __exit__
self.gen.throw(type, value, traceback)
  File "/usr/lib/python2.7/site-packages/vdsm/network/api.py", line 199, in 
_rollback
six.reraise(excType, value, tb)
  File "/usr/lib/python2.7/site-packages/vdsm/network/api.py", line 182, in 
_rollback
yield
  File "/usr/lib/python2.7/site-packages/vdsm/network/api.py", line 275, in 
_setup_networks
netswitch.setup(networks, bondings, options, in_rollback)
  File "/usr/lib/python2.7/site-packages/vdsm/network/netswitch.py", line 119, 
in setup
_setup_ovs(ovs_nets, ovs_bonds, options, in_rollback)
  File "/usr/lib/python2.7/site-packages/vdsm/network/netswitch.py", line 165, 
in _setup_ovs
connectivity.check(options)
  File "/usr/lib/python2.7/site-packages/vdsm/network/netconfpersistence.py", 
line 243, in __exit__
raise ne.RollbackIncomplete(config_diff, ex_type, ex_value)
IPRoute2Error: ['RTNETLINK answers: File exists']

ip addr show

   [root@server117 ~]# ip addr show
  1: lo:  mtu 65536 qdisc noqueue state UNKNOWN
  link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
  inet 127.0.0.1/8 scope host lo
     valid_lft forever preferred_lft forever
  inet6 ::1/128 scope host
     valid_lft forever preferred_lft forever
  2: p3p1:  mtu 1500 qdisc pfifo_fast master 
ovirtmgmt state UP qlen 1000
  link/ether 64:00:6a:23:b8:c0 brd ff:ff:ff:ff:ff:ff
  3: em1:  mtu 1500 qdisc mq master ovs-system 
state UP qlen 1000
  link/ether 

[ovirt-devel] 答复: [ovirt-users] How to add ovs-based VM in version 4.0.2? Thank you

2016-08-09 Thread lifuqiong
Hi Petr:
I found that when I type virsh commands like 'virsh list' in vdsm, the 
system will force me to input username and password, Could I cancel this 
authentication step when I type 'virsh list',  If so , how can I do this?

Thank you
Mark

-邮件原件-
发件人: Petr Horacek [mailto:phora...@redhat.com] 
发送时间: 2016年8月3日 17:22
收件人: lifuqiong
抄送: Meni Yakove; Dan Kenigsberg; Michael Burman; devel
主题: Re: [ovirt-users] [ovirt-devel] How to add ovs-based VM in version 4.0.2? 
Thank you

Hello,

don't forget you still need latest patches which are not part of
ovirt-release40 nor ovirt-release-master.

Network setup is handled by supervdsmd.service, logs are located in 
/var/log/vdsm/supervdsm.log. Network API entrypoint is in 
/usr/lib/python2.7/site-packages/vdsm/network/api.py.

2016-08-03 9:58 GMT+02:00 lifuqiong :
> Hi petr,
> I followed your instruction last mail, re-install an Centos 7.2 
> 1503(ip:192.168.0.117), and executing 'yum install 
> http://plain.resources.ovirt.org/pub/ovirt-4.0-pre/rpm/el7/noarch/ovirt-release40-pre.rpm'
>  On the new system.
>
> Creating an cluster using ovs-based network, and install 
> vdsm(192.168.0.117); deploy log shows that meeting an error as 
> follows: But I cann't find out the code which implements the function 
> of setupNetworks,
>
> Just find the setupNetwork() function was defined in API.py, what does this 
> function do actually, where is the code ? and how to fix this error?
>
> jsonrpc.Executor/4::ERROR::2016-08-02 
> 22:35:03,321::__init__::549::jsonrpc.JsonRpcServer::(_handle_request) 
> Internal server error Traceback (most recent call last):
>   File "/usr/lib/python2.7/site-packages/yajsonrpc/__init__.py", line 544, in 
> _handle_request
> res = method(**params)
>   File "/usr/lib/python2.7/site-packages/vdsm/rpc/Bridge.py", line 195, in 
> _dynamicMethod
> result = fn(*methodArgs)
>   File "/usr/share/vdsm/API.py", line 1465, in setupNetworks
> supervdsm.getProxy().setupNetworks(networks, bondings, options)
>   File "/usr/lib/python2.7/site-packages/vdsm/supervdsm.py", line 53, in 
> __call__
> return callMethod()
>   File "/usr/lib/python2.7/site-packages/vdsm/supervdsm.py", line 51, in 
> 
> **kwargs)
>   File "", line 2, in setupNetworks
>   File "/usr/lib64/python2.7/multiprocessing/managers.py", line 773, in 
> _callmethod
> raise convert_to_error(kind, result)
> IPRoute2Error: ['RTNETLINK answers: File exists']
>
>
> Hope get your help asp.
> Thank you
> Mark
>
>
> -邮件原件-
> 发件人: Petr Horacek [mailto:phora...@redhat.com]
> 发送时间: 2016年8月3日 1:50
> 收件人: lifuqiong
> 抄送: Meni Yakove; Dan Kenigsberg; Michael Burman; devel
> 主题: Re: 答复: [ovirt-users] [ovirt-devel] How to add ovs-based VM in 
> version 4.0.2? Thank you
>
> If everything goes well, it will be in master this week. I don't know when it 
> will be part of 4.0.
>
> I installed master VDSM patched with
> https://gerrit.ovirt.org/#/q/topic:ovs_acquire on my host (Fedora 23 with 
> disabled NetworkManager) and it worked OK. You can try to build it on your 
> own [1]. If you hit any problem, feel free to ask.
>
> We'd like to go that way, but nothing specific yet.
>
> [1] http://www.ovirt.org/develop/developer-guide/vdsm/developers/
>
> 2016-08-02 14:15 GMT+02:00 lifuqiong :
>> Hi Petr,
>> Thank you
>> When the patch will merge to master? And when will the vdsm will 
>> release a version with this patch?
>> Btw, do you have a plan to support ovs with dpdk or vhost-user port? 
>>  If so, what's the pipeline?
>>
>> Thank you
>>
>> -邮件原件-
>> 发件人: Petr Horacek [mailto:phora...@redhat.com]
>> 发送时间: 2016年8月2日 19:53
>> 收件人: lifuqiong
>> 抄送: Meni Yakove; Dan Kenigsberg; Michael Burman; devel
>> 主题: Re: [ovirt-users] [ovirt-devel] How to add ovs-based VM in 
>> version 4.0.2? Thank you
>>
>> Clean == host that has just NICs, like right after system installation (no 
>> networks created by VDSM, bridges, bonds, vlans). Anyway, VDSM OVS is not 
>> able to acquire external NICs yet (the patch is under review and will be 
>> merged to master soon [1]).
>>
>> I would recommend you to wait for VDSM with mentioned patch merged. If you 
>> cannot wait, you can try to setup ovirtmgmt network manually via console 
>> (turn down NIC, setup OVS network on top of it). Not sure if this would help 
>> you.
>>
>> [1] https://gerrit.ovirt.org/#/c/60404/29
>>
>> 2016-08-02 13:30 GMT+02:00 lifuqiong :
>>> Hi Petr,
>>> Thank you for your advice. But what does "Clean hosts" mean, 
>>> as I know now, When you add a clean Host to ovirt engine, the vdsm or ovirt 
>>> node will create a Network named ovirtmgmt, which is an Linux bridge 
>>> network, How do I clean the network? Just delete the linux bridge and reset 
>>> the linux bridge binding's physical Nic?
>>>
>>> Hope to get your help as sonn as possible.
>>> Thank you.
>>> Mark

Re: [ovirt-devel] oVirt 4.1: plan to update patternfly?

2016-08-09 Thread Sandro Bonazzola
On Tue, Aug 9, 2016 at 5:22 PM, Greg Sheremeta  wrote:

> Yes, I actually have a patch on it right now. It'll be done this week.
>
> In prep, I made https://copr.fedorainfracloud.org/coprs/
> patternfly/patternfly3/
>

Thanks! Looks like copr-be is donw now so I can't access
https://copr-be.cloud.fedoraproject.org/results/patternfly/patternfly3
Please open a bz on ovirt-release component to switch to the new repo.




>
>
> Greg
>
>
> On Tue, Aug 9, 2016 at 11:21 AM, Sandro Bonazzola 
> wrote:
>
>> Hi,
>> we're currently using patternfly 1.3.0, I see 3.8.1 is out here
>> https://github.com/patternfly/patternfly/releases
>>
>> Are there plan to update to it?
>>
>> --
>> Sandro Bonazzola
>> Better technology. Faster innovation. Powered by community collaboration.
>> See how it works at redhat.com
>>
>
>
>
> --
> Greg Sheremeta, MBA
> Red Hat, Inc.
> Sr. Software Engineer
> gsher...@redhat.com
>



-- 
Sandro Bonazzola
Better technology. Faster innovation. Powered by community collaboration.
See how it works at redhat.com
___
Devel mailing list
Devel@ovirt.org
http://lists.ovirt.org/mailman/listinfo/devel

Re: [ovirt-devel] oVirt 4.1: plan to update patternfly?

2016-08-09 Thread Greg Sheremeta
Yes, I actually have a patch on it right now. It'll be done this week.

In prep, I made
https://copr.fedorainfracloud.org/coprs/patternfly/patternfly3/

Greg


On Tue, Aug 9, 2016 at 11:21 AM, Sandro Bonazzola 
wrote:

> Hi,
> we're currently using patternfly 1.3.0, I see 3.8.1 is out here
> https://github.com/patternfly/patternfly/releases
>
> Are there plan to update to it?
>
> --
> Sandro Bonazzola
> Better technology. Faster innovation. Powered by community collaboration.
> See how it works at redhat.com
>



-- 
Greg Sheremeta, MBA
Red Hat, Inc.
Sr. Software Engineer
gsher...@redhat.com
___
Devel mailing list
Devel@ovirt.org
http://lists.ovirt.org/mailman/listinfo/devel

[ovirt-devel] problem setting up bonding via rest in ovirt 3.6.6.2

2016-08-09 Thread Sven Kieske
Hi,

I'd like to setup host network in the following way:

I have 4 interfaces: eth0, eno1, eno2, eno3

ovirtmgmt network resides on eth0 and is working.

Now I want to setup a bonding with the slave interfaces
eno2 and eno3 via the hosts "setupnetworks" function:

URL:

https://engine-fqdn/api/hosts/9cdcc85b-dd87-4dcf-9275-b993ee5b5e9c/nics/setupnetworks

Request:

{
"modified_bonds": {
"host_nic": [{
"name": "bond0",
"bonding": {
"options": {
"option": [{
"name": "mode",
"value": "1"
}, {
"name": "miimon",
"value": "100"
}]
},
"slaves": {
"host_nic": [{
"name": "eno2"
}, {
"name": "eno3"
}]
}
}
}]
}
}

Response from ovirt-engine:



Incomplete parameters
Action [hostNics] required for setupNetworks


When I look at the rsdl docs this seems perfectly fine.


I tried google with this error condition but it didn't return anything
useful unfortunately.

Your help would be greatly appreciated.

The official RH docs also do not mention anything else:

https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Virtualization/3.6/html-single/REST_API_Guide/index.html#Multiple_Network_Setup_Action

https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Virtualization/3.6/html-single/REST_API_Guide/index.html#Bonded_Interfaces

Also this tool doesn't seem to mention anything else:

https://jhernand.fedorapeople.org/ovirt-api-explorer/#/services/host/methods/setup_networks

-- 
Mit freundlichen Grüßen / Regards

Sven Kieske

Systemadministrator
Mittwald CM Service GmbH & Co. KG
Königsberger Straße 6
32339 Espelkamp
T: +495772 293100
F: +495772 29
https://www.mittwald.de
Geschäftsführer: Robert Meyer
St.Nr.: 331/5721/1033, USt-IdNr.: DE814773217, HRA 6640, AG Bad Oeynhausen
Komplementärin: Robert Meyer Verwaltungs GmbH, HRB 13260, AG Bad Oeynhausen



signature.asc
Description: OpenPGP digital signature
___
Devel mailing list
Devel@ovirt.org
http://lists.ovirt.org/mailman/listinfo/devel

Re: [ovirt-devel] Python code style: introducing isort

2016-08-09 Thread Eyal Edri
Adding infra also, as might be relevant for our code.

On Tue, Aug 9, 2016 at 11:06 AM, Sandro Bonazzola 
wrote:

> Hi,
> in project maintained by integration team we tried to adhere to some
> styling rules while writing python code, one of these was related to the
> import lines. After a lot of time doing this manually, we discovered isort
> ( https://pypi.python.org/pypi/isort/4.2.5 )
>
> We're using it before we push our code to gerrit and a few days ago I sent
> a patch for the python code within ovirt-engine: https://gerrit.
> ovirt.org/61964
>
> The configuration we're currently using is:
>
> $ cat ~/.isort.cfg [settings] line_length=79 
> known_standard_library=configparser,Cheetah.Template
> force_single_line=True default_section=FIRSTPARTY known_otopi=otopi
> known_host_deploy=ovirt_host_deploy known_ovirt_engine=ovirt_engine
> known_ovirt_engine_setup=ovirt_engine_setup 
> known_ovirt_setup_lib=ovirt_setup_lib
> known_vdsm=vdsm known_ovirt_hosted_engine_setup=ovirt_hosted_engine_setup
> sections=FUTURE,STDLIB,FIRSTPARTY,OTOPI,VDSM,HOST_
> DEPLOY,OVIRT_ENGINE,OVIRT_ENGINE_SETUP,OVIRT_SETUP_LIB,
> OVIRT_HOSTED_ENGINE_SETUP,THIRDPARTY,LOCALFOLDER lines_between_types=2
>
> It has been proposed to add 'isort --check-only' in check-patch.for python
> projects in addition to pep8 style checking.
>
> It has also been proposed to reach consensus on isort configuration so all
> the python code
> within ovirt project will have same styling.
>
> I'd like to get some feedback about these proposal in order to decide how
> to procede.
>
> Thanks,
>
> --
> Sandro Bonazzola
> Better technology. Faster innovation. Powered by community collaboration.
> See how it works at redhat.com
>
> ___
> Devel mailing list
> Devel@ovirt.org
> http://lists.ovirt.org/mailman/listinfo/devel
>



-- 
Eyal Edri
Associate Manager
RHV DevOps
EMEA ENG Virtualization R
Red Hat Israel

phone: +972-9-7692018
irc: eedri (on #tlv #rhev-dev #rhev-integ)
___
Devel mailing list
Devel@ovirt.org
http://lists.ovirt.org/mailman/listinfo/devel

[ovirt-devel] Python code style: introducing isort

2016-08-09 Thread Sandro Bonazzola
Hi,
in project maintained by integration team we tried to adhere to some
styling rules while writing python code, one of these was related to the
import lines. After a lot of time doing this manually, we discovered isort
( https://pypi.python.org/pypi/isort/4.2.5 )

We're using it before we push our code to gerrit and a few days ago I sent
a patch for the python code within ovirt-engine:
https://gerrit.ovirt.org/61964

The configuration we're currently using is:

$ cat ~/.isort.cfg [settings] line_length=79
known_standard_library=configparser,Cheetah.Template force_single_line=True
default_section=FIRSTPARTY known_otopi=otopi
known_host_deploy=ovirt_host_deploy known_ovirt_engine=ovirt_engine
known_ovirt_engine_setup=ovirt_engine_setup
known_ovirt_setup_lib=ovirt_setup_lib known_vdsm=vdsm
known_ovirt_hosted_engine_setup=ovirt_hosted_engine_setup
sections=FUTURE,STDLIB,FIRSTPARTY,OTOPI,VDSM,HOST_DEPLOY,OVIRT_ENGINE,OVIRT_ENGINE_SETUP,OVIRT_SETUP_LIB,OVIRT_HOSTED_ENGINE_SETUP,THIRDPARTY,LOCALFOLDER
lines_between_types=2

It has been proposed to add 'isort --check-only' in check-patch.for python
projects in addition to pep8 style checking.

It has also been proposed to reach consensus on isort configuration so all
the python code
within ovirt project will have same styling.

I'd like to get some feedback about these proposal in order to decide how
to procede.

Thanks,

-- 
Sandro Bonazzola
Better technology. Faster innovation. Powered by community collaboration.
See how it works at redhat.com
___
Devel mailing list
Devel@ovirt.org
http://lists.ovirt.org/mailman/listinfo/devel

[ovirt-devel] Which GlusterFS for oVirt 4.1?

2016-08-09 Thread Sandro Bonazzola
Hi,
currently we're building and composing master (will become 4.1) assuming
GlusterFS 3.7 will be used.
I see that 3.8 is available in Fedora 24 and on CentOS Storage SIG.
Is it time to move to 3.8 for 4.1?

Thanks,
-- 
Sandro Bonazzola
Better technology. Faster innovation. Powered by community collaboration.
See how it works at redhat.com
___
Devel mailing list
Devel@ovirt.org
http://lists.ovirt.org/mailman/listinfo/devel

[ovirt-devel] [ACTION REQUIRED] oVirt 4.0.2 RC4 build starting in 1 hour

2016-08-09 Thread Sandro Bonazzola
Fyi oVirt products maintainers,
An oVirt build for an official release is going to start in 1 hour.
If you're a maintainer for any of the projects included in oVirt
distribution and you have changes in your package ready to be released
please:
- bump version and release to be GA ready
- tag your release within git (implies a GitHub Release to be automatically
created)
- build your packages within jenkins / koji / copr / whatever
- verify all bugs on MODIFIED have target release and target milestone set.
- add your builds to releng-tools/releases/ovirt-4.0.2_rc4.conf withini
releng-tools project

-- 
Sandro Bonazzola
Better technology. Faster innovation. Powered by community collaboration.
See how it works at redhat.com
___
Devel mailing list
Devel@ovirt.org
http://lists.ovirt.org/mailman/listinfo/devel