Solved

Can't Configure IIS6 for Web Services - It Does Work on Development Workstation

Posted on 2006-07-21
6
311 Views
Last Modified: 2008-02-07
I built a very simple web service for testing purposes.  It runs fine on my Windows XP Professional workstation which is the same machine that the project was developed on.  However, when I put it on my Windows 2003 Server using IIS 6, I get the following error when trying to browse to it.

Server Error in '/AcousticallyChallenged' Application.
--------------------------------------------------------------------------------

Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level. This error can be caused by a virtual directory not being configured as an application in IIS.

Source Error:


Line 37:            by Microsoft that offers a single logon and core profile services for member sites.
Line 38:     -->
Line 39:     <authentication mode="Windows" />
Line 40:
Line 41:
 

Source File: C:\Web Sites\AcousticallyChallenged\webservices\web.config    Line: 39


--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:1.1.4322.2300; ASP.NET Version:1.1.4322.2300

What am I missing / not doing / doing wrong?  How do I deploy my web service to my web server so that it can be consumed by other applications?
0
Comment
Question by:Edward Stevens
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
6 Comments
 
LVL 2

Accepted Solution

by:
masoncooper earned 500 total points
ID: 17156434
If the error message states:
This error can be caused by a virtual directory not being configured as an application in IIS
That would be the first place to look.  Did you place your ASP.Net application in a subdirectory of the root of the site? If so, you need to create a virtual directory and point it to that directory.  This causes IIS to treat your web app as an application instead of a subdirectory of a much larger application.
0
 
LVL 2

Expert Comment

by:kcchenkd
ID: 17157011

try this

in web.config file Change authentication mode form windows to Forms

<authentication mode="Forms" />
0
 
LVL 1

Author Comment

by:Edward Stevens
ID: 17157324
Thanks to both of you.  I will try both tonight.  Below is some additional info that I did not supply initially.

I created a Web Services project using Visual Studio .Net 2003 on my local machine (Windows XP Professional SP2).  After the project was created on my local copy of IIS, I moved the directory to my IIS server on Windows 2003 Server Standard.  I modified the directory reference on my local copy of IIS to point to the other directory such that I wouldn't have to keep copying the files everytime I made a change to the project.  From the workstation, all is still good.  Going to http://localhost/... still allows the web service to function as expected even though the virtual directory is now on the server.

From the server's perspective, the directpry with the web service is located under the virtual directory for the UI portion of the application.  From I've read above, it sounds like I need to create a virtual directory for the web service itself.

I will give that a try tonight.
0
Online Training Solution

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action. Forget about retraining and skyrocket knowledge retention rates.

 
LVL 1

Author Comment

by:Edward Stevens
ID: 17158446
I made the web service have its own virtual directory.  Now, when I go to the URL and click on the function that I have in the DLL, I get the following message in place of what would normally be the parameter dialogue.

The test form is only available for requests from the local machine.

If I go to the URL from my development PC, clicking on the function gives me the parameter dialogue where I am able to test the function and get a return value.

Looks like we're getting closer.  Any ideas?
0
 
LVL 2

Assisted Solution

by:masoncooper
masoncooper earned 500 total points
ID: 17158481
It looks like you may need to modify your web.config a bit more: http://support.microsoft.com/default.aspx?scid=kb;en-us;819267
Try adding this into your system.web
<webServices>
        <protocols>
            <add name="HttpGet"/>
            <add name="HttpPost"/>
        </protocols>
    </webServices>
0
 
LVL 1

Author Comment

by:Edward Stevens
ID: 17158587
kcchenkd - Sorry I didn't award any points to you.  I tried your suggestion but it had no effect on this particular issue.  Thanks anyway.

masoncooper - I split the points on your two suggestions as a way to help others know that I needed to use both suggestions to handle this issue.  As they are both yours, you should still receive the full 500 points.  Thanks much!
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Domain Service Not Responding 14 36
PHP Curl to output a url 7 88
Link failure 16 70
auto play video on web page 4 40
Get to know the ins and outs of building a web-based ERP system for your enterprise. Development timeline, technology, and costs outlined.
Developer portfolios can be a bit of an enigma—how do you present yourself to employers without burying them in lines of code?  A modern portfolio is more than just work samples, it’s also a statement of how you work.
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…
Any person in technology especially those working for big companies should at least know about the basics of web accessibility. Believe it or not there are even laws in place that require businesses to provide such means for the disabled and aging p…

733 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question