From 86dadaaec40ee70408e02599e51d75216f4601cd Mon Sep 17 00:00:00 2001 From: Devdeep Singh Date: Fri, 13 Dec 2013 17:28:30 +0530 Subject: [PATCH] CLOUDSTACK-5489: Cloud user doesn't have permissions to copy systemvm.iso to secondary. Make sure when a cifs (secondary) is mounted, uid is set for the user who owns the files and directories on the filesystem. --- .../com/cloud/hypervisor/hyperv/manager/HypervManagerImpl.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/plugins/hypervisors/hyperv/src/com/cloud/hypervisor/hyperv/manager/HypervManagerImpl.java b/plugins/hypervisors/hyperv/src/com/cloud/hypervisor/hyperv/manager/HypervManagerImpl.java index 27745c02a59..e6d8e1ad4fe 100644 --- a/plugins/hypervisors/hyperv/src/com/cloud/hypervisor/hyperv/manager/HypervManagerImpl.java +++ b/plugins/hypervisors/hyperv/src/com/cloud/hypervisor/hyperv/manager/HypervManagerImpl.java @@ -234,11 +234,13 @@ public class HypervManagerImpl implements HypervManager { command.add("-t", "cifs"); command.add(path); command.add(mountPoint); + command.add("-o", "uid=`whoami`,gid=`whoami`"); if (query != null) { query = query.replace('&', ','); command.add("-o", query); } + result = command.execute(); }