[ovirt-users] obtain spm id (host id) from engine using api
joost at familiealbers.nl
joost at familiealbers.nl
Fri Dec 16 15:20:00 UTC 2016
in ovirt engine the table.
vds_spm_id_map
holds the ids used in spm election.
engine_20150824095956=# select * from vds_spm_id_map ;
storage_pool_id | vds_spm_id |
vds_id
--------------------------------------+------------+--------------------------------------
144fb47d-b38c-4bb7-867b-373d7ba9f0a9 | 1 |
313ed02c-8029-4fb3-ba1c-5b3c9902ddb1
144fb47d-b38c-4bb7-867b-373d7ba9f0a9 | 2 |
7fdebf8a-1503-4b54-9681-0201ee330381
these particular id's seem to be added when a vds is added to the
engine or when the storage pool is first setup.
I would like to be able to obtain this nr (in my case its generally 1
or 2 as i have two hosts per dc / cluster) through an api or even better
from the hosts itself.
When testing I connect to the storage pools using the api and its
important the hostid used when making this api call is correct or bad
things happen.
I have been searching high and low to no avail. In understand the
engine is in charge here but i really would be helped if this values can
be obtained without going into the db.
As i am continuously rebuilding dc's / storage pools and hosts i cannot
keep track of when which host is installed hence the need to know the
spm_id as listed.
It might be i am all wrong but the when i use the vds_spm_id as listed
i can connect the host to the storage pools using the api.
thanks Joost
More information about the Users
mailing list