Tuesday, November 13, 2012

Basic outline for getting an old ASP web page to upload files to a UNC share on Windows Server 2012 instance

I'm trying out a new file server with Server 2012's data deduplication functionality: saving 60GB out of 300GB is very nice. But when I tried moving a website file share to said server, I had many complaints that uploads were "broken".

1. For my situation, I kept the web files on the server, and the bulk file storage on a UNC share. I used mklink to link the share to the name of the original folder on the web server: this means I can continue to host the web server "locally", but take advantage of the de-duplicated storage setup.
2. Create a standard local login between your machines. Seed the accounts with a random password for security.
3. Give permissions to the new local login to the UNC share with your website-accessible files.
4. You might need a hotfix for Server 2008R2 / IIS 7.5 to properly access UNC shares.
5. You might need to disable SMB 3.0 on the 2012 instance.
6. Configure both your Application Pool & your IIS instance to authenticate with the new local login.
7. If your ASP application is out-of-date, make sure the file upload code is something decent. The old code was writing out files 1 byte at a time: this kills SMB performance. I also tried making use of information from this guy, but it didn't fit in as well with the older app.

1 comment:

  1. This comment has been removed by a blog administrator.