VMware Cloud Community
Andrew46
Contributor
Contributor
Jump to solution

VM Creator Information in vCloud

I have been asked by a customer of our clients but I have no programming knowledge nor have I been able to find the answer online. Does anyone know if you  can extract information on who the creator is of a VM via the API, and if so how?


Sorry to be vague but it is a subject I dont know a lot about at all, let me know if I can add any details.


Cheers,

Tags (3)
0 Kudos
1 Solution

Accepted Solutions
IamTHEvilONE
Immortal
Immortal
Jump to solution

creator is not recorded.  Owner is.

On inception, Owner = Creator.

However, you can update Owner.

You might be able to check the audit events to see who initially created it, which is in the vCloud Database in Audit_Event.  you would look for the vapp create event, then see which user created it.

The problem is, a System Administrator (ALL system admins) will show as 'System'.

View solution in original post

0 Kudos
6 Replies
barnette08
Expert
Expert
Jump to solution

When you create a vApp in vCloud Director the owner is set.  I'm not sure how you would do it from the API but you might be able to post the question in the API forum below. 

https://communities.vmware.com/community/vmtn/developer/forums/vcloudapi/content?filterID=contentsta...

IamTHEvilONE
Immortal
Immortal
Jump to solution

You can view change the owner using the following the rest API:

http://pubs.vmware.com/vcd-51/index.jsp?topic=%2Fcom.vmware.vcloud.api.doc_51%2FGUID-512A9FC7-46A4-4...

Remember that Ownership is at the vApp level, not the VM level.

It's a get command similar to:

GET https://vcloud.example.com/api/vApp/vapp-7/owner

Just update the vapp-7 and server FQDN to the appropriate one for your environment.

Andrew46
Contributor
Contributor
Jump to solution

Hi There,

Thank you for the reply, what I was looking for was the actual creator of a vm or vApp (I know that the customer concerned creates a new vApp for ever VM so vApp level would work). I know that the owner can be changed but they are looking for a way of saying Joe Bloggs created this vApp regardless of who the current owner is. I hope my effort to clarify has shed some light on the situation.

Thanks again for the reply

0 Kudos
Andrew46
Contributor
Contributor
Jump to solution

Thanks very much for the reply, I will try posting in the forum you mentioned!

0 Kudos
IamTHEvilONE
Immortal
Immortal
Jump to solution

creator is not recorded.  Owner is.

On inception, Owner = Creator.

However, you can update Owner.

You might be able to check the audit events to see who initially created it, which is in the vCloud Database in Audit_Event.  you would look for the vapp create event, then see which user created it.

The problem is, a System Administrator (ALL system admins) will show as 'System'.

0 Kudos
Andrew46
Contributor
Contributor
Jump to solution

I see, OK that makes sense to me thanks for the suggested work around pulling it out of the DB. I will see what we can come up with to accommodate their request.

Many thanks,

0 Kudos