Passing shared drive to VM vs. mapped drive (W10)?


Thrak

Recommended Posts

While I don't see an option for this I was hoping there was a way to pass a share (i.e. w10_data) to a VM to remove the need to map the drive?  I think I have all my issues resolved except my tower/shares not showing up in network neighborhood and my mapped drives being disconnected on boot.  Not seen any other fixes so was hoping there was a way to pass the share from the hypervisor?

 

Yes the mapped drives will work when I view the drive, but because they are not usable at boot I do have issues with things that depend on them at startup.

 

Also if it is not possible is it maybe on the roadmap? 

Thanks in advance.

 

 

Link to comment

While I don't see an option for this I was hoping there was a way to pass a share (i.e. w10_data) to a VM to remove the need to map the drive?  I think I have all my issues resolved except my tower/shares not showing up in network neighborhood and my mapped drives being disconnected on boot.  Not seen any other fixes so was hoping there was a way to pass the share from the hypervisor?

 

Yes the mapped drives will work when I view the drive, but because they are not usable at boot I do have issues with things that depend on them at startup.

 

Also if it is not possible is it maybe on the roadmap? 

Thanks in advance.

 

There is a workaround for the mapped drive issue... create a batch script that maps the drive at logon.  This at least means you don't need to double click on it for it to be "seen" by windows.

 

However I still find that it causes some programs to fail that require the drive to be present.  I assume because they load before they script mapping the drive runs.  Haven't figured a way around that one yet.

Link to comment

 

There is a workaround for the mapped drive issue... create a batch script that maps the drive at logon.  This at least means you don't need to double click on it for it to be "seen" by windows.

 

However I still find that it causes some programs to fail that require the drive to be present.  I assume because they load before they script mapping the drive runs.  Haven't figured a way around that one yet.

 

Thanks, I will try that.  It is pretty obvious to me because of my desktop background.  I created a folder on my shared data drive with background images for the desktop - I tend to set by background to a slideshow.  Shutdown then boot - it often fails to load the backgrounds because of this disconnected-drive issue.  Simple but seeing it fail on almost every boot.

 

I will add the script and consider it "As good as it gets" for now.

 

Link to comment

Several suggestions in this thread.

http://stackoverflow.com/questions/182750/map-a-network-drive-to-be-used-by-a-service

None reference W10, so some of the methods probably won't work anymore, but there are several different things to try. If you do find a method that works will with W10, please post back.

This https://en.wikipedia.org/wiki/NTFS_symbolic_link in particular looked interesting, since it says SMB paths are supported.

Link to comment

So there is an issue with Windows VMs not retaining their mapped network drives?

 

It is more an issue of them not working at boot, once it is connected I have not seen issues, but on boot they tend to be disconnected and often require you to browse the folder.  Sometimes even on a browse they give errors.

Link to comment

Interestingly enough I've seen this same issue happen on virtual network adapters.

I've noticed that virtual adapters have a delayed start (sometimes up to 5 seconds) after Windows inits; maybe something about virtio drivers?

 

One (kind-of) workaround is to have a software that manages your network mapped drives as soon as LAN is reachable, which could be done with a simple Ping batch that loops till it gets some response, and then executes the drive mapping.

 

Note that passing thru a NIC to a Windows 10 VM works flawlessly, so this points even harder to being a virtio driver issue.

Link to comment

I ran into this same 'problem' with a Windows 10 VM. I mapped my Steam library folder, which is on my array, to the VM, but on boot, it seemed Windows tried to map the share before it established a network connection, thus causing the mapping to fail.

 

An easy workaround that I'm currently using, via a script in the autostart folder,  delays the mapping of the share (I have it set to 10 seconds) until the OS establishes a network connection. Then I have the script launch Steam, which now has access to the mapped library on my array. If anyone needs the script, I can dig it up, but I'm sure it's all easily Googleable.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.