<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 async def get_vm_metadata(self, preset, vm_id):
 """ Get vm metadata :arg string preset: preset name :arg int vm_id: Virtual Machine id :return: Metadata for Virtual Machine :rtype: dict Sample response: ``{ 'time_shutdown' : "12312312321' }`` """

        vmshepherd = self.request.app.vmshepherd
        preset = vmshepherd.preset_manager.get_preset(preset)
        vm_info = await preset.iaas.get_vm(vm_id)
        ret_info = copy.deepcopy(vm_info.metadata) if vm_info.metadata else {}
        ret_info['tags'] = vm_info.tags
        ret_info['iaas_shutdown'] = vm_info.timed_shutdown_at
        return ret_info