Rebooting the host fixed the issue.
But that's not the way to go.
I cannot reboot hosts to be sure that, when chaning a MTU in the xencenter,  by 
disabling HA and reenabling it , that the APi will work as expected.
Where to file a  bug report ?
XEN 6.5SP1 all updated applied.

Rgds.
Franz
________________________________
Von: Xen-api [xen-api-boun...@lists.xen.org]" im Auftrag von "Skale Franz 
[franz.sk...@citycom-austria.com]
Gesendet: Mittwoch, 21. September 2016 08:06
An: xen-api@lists.xen.org
Betreff: [Xen-API] Wrong MTU via API Method get_MTU !


Hi,
i hope that's the right place for my particular problem i have with the XEN APi.
I use two different approaches to get the MTU of a VLAN and get two different , 
but wrong values.
The XenCenter show the right values.

Approach 1:

1.) Xen::API::VM::get_all_records
2.) Xen::API::VM::get_VIFs
3.) Loop through all the vifs and use:
4.) Xen::API::VIF::get_MTU

I get Networks with MTU "0"

E.g.:

Network: VLAN-7a0aeadb-0cae-ae3c-9a4e-5e20acb2cd69-72
VLAN: 72
MTU: 0
MAC: xx:xx:xx:xx:xx:xx
PIF UUID: 06dcf73f-6ba7-3810-c7a7-da6bcd003c69

Approach 2:
1.) Xen::API::network::get_all
2.) Xen::API::network::get_VIFs
3.) Xen::API::VIF::get_MTU

"OpaqueRef:a4fb228d-cb00-8782-c770-18569f8c9761"
VLAN: 72
MTU: 9000

But checking another VLAN which xencenter claims to be MTU 9000, i get MTU 1500 
! (using method 2).
VLAN: 1455
MTU: 1500
Using method 1 shows me:

Network: VLAN-7a0aeadb-0cae-ae3c-9a4e-5e20acb2cd69-1455
VLAN: 1455
MTU: 9000

What is the right method to get the REAL MTU value using the Xen API ?

it would be great if anyone can tell if i hit a bug or it's supposed to be so ?

Thanks in advance

Franz


_______________________________________________
Xen-api mailing list
Xen-api@lists.xen.org
https://lists.xen.org/cgi-bin/mailman/listinfo/xen-api

Reply via email to