Help - Search - Members - Calendar
Full Version: Virtual Directories?
The Planet Forums > Operating Systems > Microsoft Windows
BillGulch
..I'll be honest, I'm not exactly sure how to address this question, but I'm going to try. icon_smile.gif

I run the following DOS batchfile on start-up :

subst d: c:Inetpubwwwrootpooledsites

FTP picks up that D: is now a "directory", which is good, however..

When I run an ASP script, I can't open an Access database with ODBC using the virtual directory d: . I still have to use c:Inetpubwwwrootpooledsites...

I'm not super savvy using IIS; just enough so to be dangerous. Is there an easier way to do this and have it work, or do I need to "tell" ASP that a virtual directory exists, or... whatever it takes. icon_smile.gif

The reason I am trying to do this is because I am attempting to move my entire website from one server onto my new, notably cheaper, Rackshack.net server and want the changeover to be as seemless as possible. Yea, I'm lazy like that.

I'm having an issue with some of my old includes as well (I'm moving from ASP to ASP.net), but I haven't figured out exactly what my problem is yet, so I'll wait until I can speak a little more intelligently on that...

Thanks guys!

--Mike
elevator
afaik - but please correct me if your experiences are different.

substituted drivers are 'login' (well. session) specific. To explain it better.

If you login to your server using RDC twice, with both other usernames, you will notice that you can subsitute different letters for each username. So user 1 can subsitute c:test into D:, while user 2 can subsitute C:windows into D:

As the IIS runs under a different username, the substs are not made for the user IIS runs under, and hence the problem.
BillGulch
I can buy that. icon_smile.gif

Any way to work around that issue? IE - have the "internet account" run the startup file or something like that? Or is there just an easier way to do this altogether? Or am I just going to have to quit being lazy and change my scripts?

Thanks again!
LighthousePoint
a semi-lazy way to do it is have an include file, that specifies global variables -- such as path. You'll still have to update the path -- but only in one place.
elevator
Fixing your scripts might be the 'right' way to do it icon_wink.gif
jamesthurley
Microsoft have a handy service to run a batch file before logon:

http://support.microsoft.com/default.aspx?...b;en-us;q243486

I've not tried it in Server 2K3, but I'm currently using it in Windows XP with no problems (when I installed XP it created my primary master hard disk as drive F: for some strange reason, leaving me with no C drive. And windows explorer doesn't show any icons in the tree if there is no C drive. Subst and AutoExNT to the rescue icon_smile.gif ).

The version I'm using, which I got a few years ago but I'm not sure if they've updated it, is hopefully attached to this message.
DBlizzard
Can you clarify a couple of things and I'm sure someone can help. It might just be me so I appologize in advance, I am a little slow icon_smile.gif
What are the exact needs of the substitute drive letter?
Are you referencing D: in your ODBC configuration?
Are you using server.mappath in a number of asp files?
Is this issue only concerning one website or many?
If only one site is it up and running on the new server except for the database driven pages?

Was the reference to FTP can see D: just a test or is there some need for FTP to see D: ?

thx
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2010 Invision Power Services, Inc.