Posted by: rusteddev | June 30, 2010

Map drive to Sharepoint library on Windows Server 2008 R2

Today I needed a solution to interact with sharepoint acting as a repository of files. I’m not talking of source repository (for which TFS repository is more appropriate). My purpose is to use my sharepoint  team portal as a document management tool (Edit, Store, Publish, Manage rights and versions, ….) and download configuration files from a central repository in my build process. I was planning to use WSS 3.0 webservices. Asking for advice from one of my collegues on on how to programmatically downlad files from Sharepoint he said “Why don’t you just map your Sharepoint library to network drive ?”….. Brilliant …

It is obviously a great idea, because I’m not required to do WS plumbing to ask / get documents from WSS. A simple “copy” dos command will do the trick !

Yes but, with Windows Server 2008 R2 even simple thinks like mapping a network drive aren’t as straighforward as for Windows XP.

Mapping network drive without WebDAV

Mapping network drive requires WebDAV Client to be running on. By default this service is not running. To activate it, add “Desktop Experience” Feature (…..strange…… isn’t it ?) in Server Manager as shown below :

Add "Desktop Experience" feature

A reboot is needed for change to take effect. After the reboot, go to Services console and Start “WebDav Client” Service.

Start WebClient service

You can then map your drive to the library adress like http://mytfsserver/sites/MySite/MyLibrary  and start using this drive like a disk drive (except maybe the speed which in was slow…)

Notes : As my WS 2008 R2 is not acting as a Sharepoint server (only connecting to it while building), this is the only opereation needed. But, if you have Sharepoint installed on your client machine that needs to connect to Sharepoint, you have to unistall WebDav Module from ISS site. See detailed procedure here

Advertisements

Responses

  1. I tried to map sharepoint document library and followed these instructions… I checked WebClient it’s there and it automatic start…

    I keep getting “http:xxxxxx could not be found” error when I tried to map the document library.

    Any comment or suggestion would be appreicated.

    • There is also a patch for Windows 2008 R2 (kb2468498). Patch can only be installed AFTER you activate “Desktop Experience” and start the service.

  2. Thank you! I couldn’t figure out why I couldn’t mount the network drive like the desktop versions of Windows do. I would have never guessed that it was “Desktop Experience” missing.

  3. Wow, this fixed our issue as well, thank you!


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Categories

%d bloggers like this: