Closed ashish235 closed 7 years ago
Could you provide us the log file of the NFVO and VIM driver?
My guess is that it fails to calculate the left quota of the VIM. This may happen due to problems with requesting the quotas from OpenStack or that a VM doesn't point anymore to a flavour (e.g. when a flavor was changed while the VM was running).
Hi @mpauls ,
I tried with refresh quota and below are logs after doing that.
Openbaton.log - I guess this is the NFVO log.
2017-06-14 16:46:53.455 INFO 62346 --- [http-nio-8080-exec-4] org.openbaton.vim_impl.vim.GenericVIM : Listed Quota successfully for Tenant admin of VimInstance vim-instance-name -> Quota: Quota{id='null', version=0, tenant='admin', cores='20', floatingIps='0', instances='10', keypairs='100', ram='51200'}
2017-06-14 16:46:54.188 INFO 62346 --- [http-nio-8080-exec-4] org.openbaton.vim_impl.vim.GenericVIM : Listed Quota successfully for Tenant admin of VimInstance vim-instance-name -> Quota: Quota{id='null', version=0, tenant='admin', cores='20', floatingIps='0', instances='10', keypairs='100', ram='51200'}
Nova logs in Openstack.
2017-06-14 16:47:01.523 3062 INFO nova.osapi_compute.wsgi.server [req-e331d6ac-50d9-4132-b869-01cbb0f48de5 45857ddba9b843319598e42edae78db7 4222986cef724b489a74344bb454a274 - default default] 172.16.111.94 "GET /v2.1/4222986cef724b489a74344bb454a274/os-quota-sets/admin HTTP/1.1" status: 200 len: 677 time: 0.4498460
2017-06-14 16:47:02.245 3061 INFO nova.osapi_compute.wsgi.server [req-ecfd5f18-e335-4157-a06b-3a2223af687f 45857ddba9b843319598e42edae78db7 4222986cef724b489a74344bb454a274 - default default] 172.16.111.94 "GET /v2.1/4222986cef724b489a74344bb454a274/os-quota-sets/admin HTTP/1.1" status: 200 len: 677 time: 0.4407120
2017-06-14 16:47:03.238 3061 INFO nova.osapi_compute.wsgi.server [req-2bf21d00-ecc4-4e3a-a17d-5b378c34d5e2 45857ddba9b843319598e42edae78db7 4222986cef724b489a74344bb454a274 - default default] 172.16.111.94 "GET /v2.1/4222986cef724b489a74344bb454a274/servers/detail HTTP/1.1" status: 200 len: 5597 time: 0.6866360
Nothing appeared in the VIM driver log. ( I guess it's the generic-vnfm.log file)
I 'm using keystone v2 api, but that shouldn't change anything here, I think.
Please let me know if you need any additional info.
Thanks. Ashish
I know it might be a different perspective but more or less same thing happenned to me , I solved it via deleting cache of browser.
Hey @gc4rella I have tried to reproduce the bug, But I was not able to reproduce it. Even I tried to reproduce on @radoslavvlaskovski computer and on different web browsers. Everything works smooth. I have discussed this with @ogozman because he has write this function previously. So, we concluded that it can be his individual browser, or openstack problem.
Hi @ashish235
are you still facing this issue, internally we tried to reproduced it but everything seemed to work, if you don't have any further comments i will close the issue
@lorenzotomasini Sorry, I was out of country for few days, couldn't check this thread.
I asked my one colleague to do fresh installation of openbaton and even he is facing the same issue. So browser issue can be ruled out here.
I 'm not sure, if any additional logs can help to find out issue?
I am not able to understand the problem exactly...
You have a NSR deployed, you click on top right menu and then refresh quota button, but nothing changes on the overview dashboard, and you do not have any problem in the logs, right?
@lorenzotomasini , yes you're right that's the issue. My concern is from the NFVO dashboard the user should get an idea of available resources on the VIM, which at the moment is not working.
@ashish235 is very hard for us to help without all the info, where the problem could be. In many setup we have this feature works, it may take time (even 10 seconds) but after that it rewrites the charts and show a generic usage of all the vims.
may be of help the plugin logs but still, it is very hard to help you here. Which browser are you using?
@lorenzotomasini , I can understand that, the logs I 've provided doesn't give a clear indication of the problem but I 'm not able to extract anything from which could be of your help. Below are the openbaton logs.
2017-07-24 13:23:56.528 INFO 14661 --- [http-nio-8080-exec-3] org.openbaton.vim_impl.vim.GenericVIM : Listed Quota successfully for Tenant admin of VimInstance vim-instance-name -> Quota: Quota{id='null', version=0, tenant='admin', cores='20', floatingIps='0', instances='10', keypairs='100', ram='51200'}
2017-07-24 13:23:57.344 INFO 14661 --- [http-nio-8080-exec-3] org.openbaton.vim_impl.vim.GenericVIM : Listed Quota successfully for Tenant admin of VimInstance vim-instance-name -> Quota: Quota{id='null', version=0, tenant='admin', cores='20', floatingIps='0', instances='10', keypairs='100', ram='51200'}
But then I took a packet capture my Openstack Controller node and I actually saw wrong values being sent by Openstack in the JSON payload.
And when I look at the capture when I refreshed the quota on Horizon (Openstack dashboard) I see correct values in the pcap. The API(s) being invoked in both the cases are different.
API from Horizon:
Response to Horizon:
API from Openbaton:
Response to Openbaton:
Since it's working in all other setups, so I 'm wondering if Openbaton has something to do with v2/v3 auth of openstack. I mean Horizon is integrated using v3 API whereas Openbaton using V2 API.
PS: I 've tried it on firefox, chrome and MS Edge too (all with latest updates).
Chrome is also the browser we are using so let's stick to that.
can you check if there is an answer from the NFVO in the browser? Assuming you are running the NFVO locally on port 8080
get the token
curl -v -u openbatonOSClient:secret -X POST http://localhost:8080/oauth/token -H "Accept:application/json" -d "username=admin&password=<ADMIN_PASSWORD>&grant_type=password"
execute the request to the quota api
curl -X GET -H "Authorization: Bearer <THE_TOKEN_FROM_PREVIOUS_REQ>" -H "project-id: <THE_RPOJECT_ID>" http://localhost:8080/api/v1/quotas
this should return an array of json objects. if this does not work the problem is in the backend if this works the problem is in the frontend
Here's the o/p which is same as the front-end.
root@Ubuntu14:/var/log/openbaton# curl -X GET -H "Authorization: Bearer bb06aff1-df2d-4e88-9ef1-1058b585c23a" -H "project-id: 14b71f9a-5914-4859-a44d-a2d5a575e578" http://localhost:8080/api/v1/quotas { "total": { "version": 0, "cores": 20, "floatingIps": 0, "instances": 10, "keyPairs": 0, "ram": 51200 }, "left": { "version": 0, "cores": 20, "floatingIps": 0, "instances": 10, "keyPairs": 0, "ram": 51200 }
So does it have something to do with Project id? I 'm using Admin project here. The total json has correct values, it's the left json which has incorrect values.
Are you sure openstack is returning the correct values?
this call you have done is a sum of all the vim onboarded in the chose project (admin in your case)
last check, you can try to use v3, but i believe the other guys at the beginning tried with v2.
@lorenzotomasini , somehow I couldn't make Openbaton work with v3. Got authentication errors tried a lot on that and gave up. With v2 it was instantly connected.
Well I can see in the http trace all the parameters in the "total" json object, didn't see any object for "left" or used details, to calculate the usage on dashboard. Not sure, how's the calculation done.
Here's the http pcap. quota_openbaton.zip
The CPU, memory and other resources doesn't reflect any changes, even when I refresh quota. I always see the total cores, memory,volume etc.
I 've a openstack setup with newton version and Openbaton is the latest 3.2.2.