Need to fool DNS for legit purposes...


We have a business continuity site.  
The dev team coded to host name prior to being told to code to DFS name...
Now their code will not work because their code points to a non-existent box.
We tried changing the host file on the Bus Continuity server to try and fool his programs into thinking that the old host name pointed to the ip address of the new server.
When we ping the old server name it points to the new ip address.  Good
However - he needs to map a drive that references the old servers unc path but have it point to the new ip address...

When we map a drive using the old server name it still references the old offline server even though the host file is changed...


Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

TimBusiness Systems AnalystCommented:
map the drive using the new UNC path, the code should not be looking at the UNC path of a mapped drive, just at the shortcut drive letter you've created.
javajoAuthor Commented:
Thanks bouscal -

yup....i wish that was the case..

Code is referencing host name...
Rick JohnsonSystems AdministratorCommented:
make sure you aren't using WINS...

For example, you should have your HOST file look something like this:



In the former, you are using "DNS", in the latter, you are using WINS and the NETBIOS name.

When referencing the server to map the drive, make sure you also use the FQDN, i.e. and not the NETBIOS name of someserver

Hope this helps
INTRODUCING: WatchGuard's New MFA Solution

WatchGuard is proud to announce the launch of AuthPoint, a powerful, yet simple, Cloud-based MFA service designed to eliminate the vulnerabilities that put your data, systems, and users at risk.

javajoAuthor Commented:
thanks n1wqk
easily changes the host file..

However...cannot map a drive letter share using FQDN...
receiving no network error
Rick JohnsonSystems AdministratorCommented:
actually, ordinarily you can. The question is this: can the 2 networks talk to each other? (IP addresses, that is)
As a stupid workaround try this:
point the hosts file to the local server.
Map the network drives with the auto reconnect switch under the same context as the account which runs your application.
Share those drives out to match the old server to trick the application into thinking its actually going there.
javajoAuthor Commented:
N1wqk -

Yep - two networks can talk to each other by ip - no issue there.

abelenkiy -

here's the test im doing.

changing the host file to point new old server name to new server ip address - - can ping old server name and it does indeed resolve to new ip address.

When i try and map the drive however i cannot get it to resolve to the new server..

Let me ask this...what if the paths are different but the share names are the same?  For instance:

Old server UNC:

New server UNC:

Now if i change the host file as stated above so the new ip address of server_b points to the old host name of server_a - i can do that and ping works...

but if i try and map a drive using the old server name and share it doesn't point to the new server.  
Am i getting a no network error because the underlying paths are different??  I wouldn't think so...

Yes, you need to make sure they both look the same.
Or make an alias on the folder2 dfs share to look like folder1

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Can you try to browse to the old server name? What if any shares show up? can you map them by hand from there?
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.