Web Reference and DNS Alias

F

Francois Guerin

I have two web services running on a Windows 2003 Server machine. One of the web service needs to reference the second one. Initialy, the reference URL was "localhost", but for logging purposes, we have created an alias on the DNS to point to a virtual web site on the same server. Since then, if I want to add or update a web reference to that service using the alias, no information about the the services implemented are shown. I tried browsing with IE and I get the same probem

Result using localhost or the machine name in IE
<?xml version="1.0" encoding="utf-8" ?>
- <discovery xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.xmlsoap.org/disco/"><contractRef ref="http://servername.dom.com/appcommonwebs/Classes/clsAPP_EmployeesWebS.asmx?wsdl" docRef="http://servername.dom.com/appcommonwebs/Classes/clsAPP_EmployeesWebS.asmx" xmlns="http://schemas.xmlsoap.org/disco/scl/" /><contractRef ref="http://servername.dom.com/appcommonwebs/Classes/clsAPP_MailWebS.asmx?wsdl" docRef="http://servername.dom.com/appcommonwebs/Classes/clsAPP_MailWebS.asmx" xmlns="http://schemas.xmlsoap.org/disco/scl/" /><contractRef ref="http://servername.dom.com/appcommonwebs/Classes/clsAPP_SettingsWebS.asmx?wsdl" docRef="http://servername.dom.com/appcommonwebs/Classes/clsAPP_SettingsWebS.asmx" xmlns="http://schemas.xmlsoap.org/disco/scl/" /></discovery

Result using the alias in IE
<?xml version="1.0" encoding="utf-8" ?><discovery xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.xmlsoap.org/disco/" />

Why is that
 
M

[MSFT]

Hello,

Thank you for using the community. AS I understand, after you created an
alias on the DNS Server to point to a virtual web site , you can't get the
disco information from the web service. I suspect the information in the
web service still point to the localhost path and we need recompile the web
service project. First, you may open follow files in Notepad:

wen.config
.vbproj
.vbproj.webinfo

research for the path information, replace them with new path (new alias)
instead of localhost. Then open the project in VS.NET and recompile it.

Luke
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)
 
F

Francois Guerin

Luke

Same problem! Also, why is there static paths instead of relative paths in settings like this? This means that I cannot access this web service from more than one virtual web site. I would need to have two different virtual web sites on the server that point to the same web service to enable different configurations

Francoi
 
S

Simon Smith

On Sat, 14 Feb 2004 04:26:10 -0800 in article
<[email protected]> in
microsoft.public.dotnet.framework.aspnet.webservices , Francois Guerin
Luke,

Same problem! Also, why is there static paths instead of relative paths in settings like this? This means that I cannot access this web service from more than one virtual web site. I would need to have two different virtual web sites on the server that point to the same web service to enable different configurations!

Francois

Francois -

If you cut out all the text from the original question, it's difficult
to see what you're talking about. Not everyone uses Google to read
newsgroups.
 
S

Steven Cheng[MSFT]

Hi Francois,


Thanks for your followup. As for the problem you mentioned, do you think it
possible that the problem due to the DNS alias ? Have you tried the
following steps:
1. Try ping the certain DNS alias to see whether it is correctly mapped to
the certain server's IP address. Also, you can instead try visiting a
certain aspx web page on the server via the DNS alias to see whether it is
displayed correctly.

2. If the alias has no problem. I think there must be something broken when
the ASP.NET try retrieving the ASP.NET web service's infos through the DNS
alias url. I think you may try using the Web Fetch tool (wfetch.exe) to
have a monitor on the web request and response when try browser the web
service in IE. Here is a KB article on using the
wfetch tool:

#HOW TO: Use Wfetch.exe to Troubleshoot HTTP Connections
http://support.microsoft.com/?id=284285

Hope this help.



Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx
 
F

Francois Guerin

Hi Steven

I used WFetch and it did not detect anything abnormal. Could it be a .NET security issue (like code trust)

François
 
S

Steven Cheng[MSFT]

Hi Francois,

Thanks for your followup. As for the "Security Issue" you mentioned, I do
think it is a potential cause, you may try adding a new codegroup(spedify
the certain url of the webservice) via the .net configuration tool( in
control panel--->administrator tools) and grant it with FullTrust. Then try
adding the web reference again to see whether the problem remains. Also,
you may try adding the url into the trusted sites list and then adjust the
Intranet Zone 's trust level to FullTrust to see whether this works.



Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx
 
F

Francois Guerin

Steven

The intranet security level was already set at full trust. However, there is something stange happening. I've enabled directory browsing on both the local site and the virtual site pointing to the web service. Then, I was able to list all directories and files on the local site, but I was not able to navigate to the "bin" folder on the virtual site

http://localhost/SiteName/bin works
http://MachineName/SiteName/bin works
http://AliasName/bin does not work! The error is "page not found". This means the dll file is never accessed

I get the same results as before when I navigate to the vsdisco file via directory browsing. I think this could be the cause of the problem, but I don't know why I cannot navigate to the bin directory via the alias url

Françoi
 
S

Steven Cheng[MSFT]

Hi Francois,

Thanks for your followup and the further info you've provided. Based on
your description, I quite agree that the symptom that the "bin" directory
is unable to be viewed also proved the cause of the problem on the certain
alias. I doubt whether the alias has something incorrect on it or is the
problem something concerned with the IIS. Can you try using some other
alias or put the webservice under other web folder (even the site's root
folder) to see whether it works?


Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,770
Messages
2,569,584
Members
45,079
Latest member
ElidaWarin

Latest Threads

Top