Problems powering off droplet.

May 19, 2013 12.3k views
I want to create a snapshot of my droplet, but I can't power off the droplet. I have this api command, and I have a client id and api key, but how can I find out the ID of my droplet? My droplet has the name I gave it, but I can't find its ID anywhere. Also, I'm on Windows using putty to ssh to my droplet. After logging in, do I execute the api command there? Or do I execute the command in the browser? I ask this because the api commands start with https. Thanks in advance!
7 Answers
I only have one droplet, so if I assume the ID is 1 then I get this error message in putty:
No such file or directory
Figured out that I first have to execute this to get my droplet ID:

And I can do this in the browser, and see the droplet ID in the response in Firebug.
Glad you figured it out -- is there anything else you need help with in regards to the API?
On Ubuntu Server 12.04, how do we poweroff our droplet from the command line, for purposes of taking a snapshot?
@Pablo: you can run the "poweroff" command, or "shutdown -h now" - both should work.
@Kamal; thanks!
... and to reboot, you should run the "reboot" command.
Have another answer? Share your knowledge.