delete_vm should delete db entry first

Change-Id: I567238bbbb7f920fc1eec71f83a3ba48b6bae97d
Use copy_out's owner option

Change-Id: I8e5841382bcf8c088fcbfc225425ce053be271cc
get/set agent setting without chmod /var/vcap/bosh

We don't do chmod 777 /var/vcap/bosh anymore. For set agent setting, we
copy setting files to temp file, then mv it to /var/vcap/bosh using
root. For get agent setting, we cat out using root.

Change-Id: Ibb424a30770f5e333c619635be3f71814852e49a