0

I am using Windows 10 to connect to a Windows Server 2012 R2 (VM) installed on a Hyper-V core host. The VM is set to share a second virtual disk where I allowed previously share and gave full control permission.

When I try to access a shared folder from the Windows 10 client, I receive a login window, enter my credentials, and windows seems to authenticate, but the password box is then cleared and not error is presented.

To try to understand what is happening, I tried to connect from the client machine using Remote Computer management, the connection first failed, then I disabled the firewall on both sides, then this time the connection succeeded but an error message appeared: "You have no permission to show the shares list of the Windows Clients".

On the VM, I went to the Network and sharing center -> Advanced sharing settings, checked "Turn on network discovery" and saved, but this action could not be taken, and the option was reinitialized to Off again.

I guess something in the Hyper-V core server inhibits the communication between the two machines.

For additional information: please note that this is a non domain configuration (only Workgroup), and the same administrator account credentials is set and used on the 3 machines.

Could somebody have an idea ?

Sami-L
  • 253
  • 2
  • 6
  • 17
  • I don't really understand this part: "...windows seemed to authenty, but the login window only emptied the password zone without giving any error." Without a domain you will probably have to enter a username and password to access any shares. The credentials you enter should be from the local accounts list on the computer that is doing the sharing, not from the computer that is the client of the share. – Todd Wilcox Feb 29 '16 at 15:46
  • `I guess something in the Hyper-V core server inhibits the communication between the two machines.` - This doesn't have anything to do with Hyper-V. What would be the point of Hyper-V if it prevented communication with virtual machines running under Hyper-V? – joeqwerty Feb 29 '16 at 16:01
  • @Todd, sorry for the mistake, it was updated, and please note that I can usually access other shares on the network without having to provide each time credentials, the difference here is that I am trying to access a vhdx file on a Hyper-V host. – Sami-L Feb 29 '16 at 16:18
  • @ joeqwerty I suspect the VM related vhdx files access is denied or some permissions are missing on the Hyper-V host. – Sami-L Feb 29 '16 at 16:25
  • If you can access a share without a domain and without providing credentials, then the share and the underlying file system permissions both allow access to the "Everyone" object. That's a very bad idea from a security standpoint, but if you want to avoid having to enter credentials, that's a way to do it. – Todd Wilcox Feb 29 '16 at 16:32
  • @Todd, I meant by "without having to provide each time credentials" just to avoid having to enter each time credentials. – Sami-L Feb 29 '16 at 16:42
  • Can you connect if you try to access the share by server name? Does it connect if you try to access the share by server IP address? – user5870571 Feb 29 '16 at 16:45
  • @user5870571 To avoid having to test dns resolution, in file explorer I directly enter the ip address as follows: \\xxx.xxx.xxx.xxx\$d\SharedFolder – Sami-L Feb 29 '16 at 16:56
  • @Sami-L: But you're not trying to access the VHDX file of the VM. You're trying to access a shared folder in the guest operating system of the VM. That should be no different from accessing a shared folder on a physical machine. This has nothing to do with Hyper-V. – joeqwerty Feb 29 '16 at 16:59
  • @joeqwerty exactly! This has nothing to do with Hyper-V and I'm not sure why the OP keeps referring to the VHDX. Sami-L When you say the VHDX did you attach it to the VM and then boot the VM go into disk management and verify the disk is visible, and formatted? – user5870571 Feb 29 '16 at 17:10
  • @joeqwerty: Previously, the VM was using only one VHDX containing OS and data, share was working perfectly, then for backup convenience I've added a second VHDX and transferred data onto it, this way the data duplication would take less time and ressources. – Sami-L Feb 29 '16 at 17:17
  • OK, but again this problem isn't related to Hyper-V or the VHDX. Did you create a shared folder on the disk? Did you configure the Share and NTFS permissions appropriately? – joeqwerty Feb 29 '16 at 17:20
  • @user5870571 The VHD is already containing data, I can get to the VM using Remote Desktop, and can do everything normally from within the VM. – Sami-L Feb 29 '16 at 17:22
  • Right so in Hyper-V you attached the VHDX to the VM and then boot the VM. In the VM you ensure that you can see the second virtual disk, that it is already formatted, that it is assigned a drive letter, and then configure sharing. – user5870571 Feb 29 '16 at 17:25
  • @joeqwerty: Yes I confirm that I created folders in the "D" drive inside the VM and then set the share authorization and permission for this entire drive and also set NTFS permission for the same account for this drive. – Sami-L Feb 29 '16 at 17:30
  • Sharing the drive and sharing folders on the drive isn't quite the same thing as posed in your question. Can you share an actual folder on the drive and test? – joeqwerty Feb 29 '16 at 17:36
  • @joeqwerty In a first step I shared folder, then when this did not work, and to avoid having to deal with inheritance, in the second step I focused on sharing the root. Now I just created a new folder in the "D" drive in the VM and checked the sharing and permissions, all is correct, but cannot connect from the client to the new folder. – Sami-L Feb 29 '16 at 18:04
  • Do the date and times on the two computers match? – user5870571 Feb 29 '16 at 20:04
  • @user5870571 yes they match, and I have tried to connect from another Windows client, I get the same error. – Sami-L Feb 29 '16 at 20:32
  • Just to clarify when you say "I get the same error" you mean you do not get an error at all and you are prompted to login again? – user5870571 Feb 29 '16 at 20:33
  • @user5870571 When I try to connect through "Computer management" I get the error message as indicated above, when I try to connect using File explorer I do not get an error at all and I am prompted to login again. – Sami-L Feb 29 '16 at 20:44
  • When you connect with remote computer management you should do it from the command line using this code: runas /netonly /user:SERVERNAME\username mmc Then add the computer management snap-in and specify SERVERNAME in the box that says Another computer. – user5870571 Feb 29 '16 at 20:47
  • @user5870571 Also with this method I get the same error message. – Sami-L Feb 29 '16 at 20:56
  • If you check the security log on the Windows 2012 server do you see an error for your recent login using MMC? – user5870571 Feb 29 '16 at 20:57
  • In the Event Viewer->Windows Logs->Security I have "Audit Success" at the time when I logged using MMC – Sami-L Feb 29 '16 at 21:14

1 Answers1

1

You need to check two settings.

In the Windows 2012 R2 VM make sure that the share permissions AND the NTFS permissions allow the user you are logging in with to access the directory.

The second thing is that when you login you MUST include the name of the computer with the username. Here is what I mean by this.

Server ServerName

Client ClientName

So to login to the Server share from the Client the username is ServerName\administrator. If you just put administrator the Server will read the username as ClientName\administrator.

user5870571
  • 3,094
  • 2
  • 12
  • 35
  • thank you for correcting to the question, please note that share permissions and the NTFS permissions was double checked. And also I used the login in the following maner: ServerName\administrator and this does'nt work. – Sami-L Feb 29 '16 at 16:35