2010-12-01 16 views

回答

3

好的 - 這裏有一些令人討厭的WCF問題的總結,我在遷移期間遇到了希望它可以幫助某人。

問題1 - 「這個集合已經包含一個地址和方案http,在這個集合中每個方案最多隻能有一個地址。」

這是由我的網絡服務器有多個網站與多個主機標題引起的。解決方案在這裏找到:WCF service startup error "This collection already contains an address with scheme http"

我只是增加了一個baseAddressPrefixFilter:

<serviceHostingEnvironment> 
    <baseAddressPrefixFilters> 
     <add prefix="http://yoururl.blahblah.com/" /> 
    </baseAddressPrefixFilters> 
</serviceHostingEnvironment> 

問題2:我The authentication scheme ' NTLM' is not supported.錯誤。我與掙扎了一會兒,最後重新啓動作出一個走(雖然我也這樣做(http://bytes.com/topic/net/answers/705912-authentication-scheme-ntml-not-supported):

# change directory to c:\inetpub\admin scripts first 
cscript adsutil.vbs set w3svc/NTAuthenticationProviders "Negotiate,NTLM" 

了。在我的配置中第一個逗號後面輸入一個空格,不知道如果這是造成問題

問題3:重新啓動後,我得到了快樂.404錯誤

我在這第一次的猜測是,WCF並沒有設置我的服務器上託管,所以我跑了。 ( http://msdn.microsoft.com/en-us/library/ms732012.aspx

serviceModelReg.exe -i 

但是,404的真正來源是由於我試圖去http://yoururl/somewhere.svc而不是http://yoururl.blahblah.com/somewhere.svc(即,我的baseAddressPrefixFilter導致我的404)。

希望這會有所幫助!