Ask Your Question
0

Is it possible to execute commands through metadata in an already running VM?

asked 2015-02-27 12:17:48 -0500

jpmethot gravatar image

Our current issue is that we would like to be able to mount a drive automatically from outside a virtual machine. I do believe it is possible to do that on the first boot of a VM through cloud-init. What I'm asking is how to do it either while the VM is running, or through subsequent boot.

Is it possible to make modifications on a server through metadata after the first boot? If so, how?

edit retag flag offensive close merge delete

2 answers

Sort by ยป oldest newest most voted
1

answered 2015-02-27 17:59:43 -0500

smaffulli gravatar image

I would use puppet or ansible or saltstack or simply batch commands via ssh: login into the VM and make things happen.

edit flag offensive delete link more

Comments

Right, that's probably the only way we could do this. It would require a backdoor in the vm (through a default ssh key may be the best way to do this) which I would prefer not to need, since those VMs will belong to customers. I guess simple is best here though. Thank you.

jpmethot gravatar imagejpmethot ( 2015-03-02 08:16:39 -0500 )edit
1

answered 2015-02-27 23:16:45 -0500

edit flag offensive delete link more

Comments

Thank you for the link, but that's not exactly what I'm looking for. This applies for the first boot of a vm, but can't be applied while it's already running or on subsequent boots.

jpmethot gravatar imagejpmethot ( 2015-03-02 08:12:05 -0500 )edit

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

2 followers

Stats

Asked: 2015-02-27 12:17:48 -0500

Seen: 189 times

Last updated: Feb 27 '15