Ask Your Question
0

Log Uptime of Active VMs Periodically

asked 2014-04-08 15:28:58 -0500

anonymous user

Anonymous

Hello,

I am trying to write a script to log the uptime of VMs on a periodic basis. I was thinking of using the novaclient python api, but I cannot seem to be able to figure out how to get the information in a machine readable format. Should I just 'cut' through it to pull out the individual characters?

Thanks!

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
1

answered 2014-04-08 17:07:11 -0500

SamYaple gravatar image

You might find it easier to do a query to the database. It will list start times and current state. You can build one fairly quickly to pull out that info and convert it to uptime.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2014-04-08 15:28:58 -0500

Seen: 340 times

Last updated: Apr 08 '14