Wednesday, October 31, 2012

Issues in BizTalk SSO and ESB management portal for today

Everyday when you working on a project, there are many issues that caused by the environment set up or change to be fixed.

Today I have two issues to record here.

1. The SSO service account password was updated, then when I went to BizTalk administrator, tried to refresh, I am getting the following error,
"
Cannot perform encryption or decryption because the secret is not available from the master secret server
"
Quickly asked Google and found the solution here, And it worked after run the commands,
ssoconfig -restoresecret SSOxxx.bak

2. Need to deploy the ESB management portal to a QA environment. In this environment, it deals with bizTalk server and a seperate SQL server, obviously we are having the double hop issue with delegation, which need to set SPN.

The linked article ESB 2.1 Portal minimal access configuration (Kerberos)
detailed explain the minimum security requirment and set up process for this type of deployment.

Thursday, October 25, 2012

Service Bus UnauthorizedAccessException token provider was unable to provide a security token while accessing custom STS

I installed the service bus for windows server on my windows server 2012. Then I setuped the new service bus farm and followed the tutorial on MSDN to test the brokered message queue client.

However, I am getting the error as below.

This error can not provide a security token for the user I setup run as from sb farm, which username@domain.

After some test, I realized the issue is caused by the run as user has to be given a full userdnsdomain name. So when you set up the service bus farm, make sure it is uisng username@domain.com format.

Then it worked as expected.

Wednesday, October 24, 2012

A good way to gac the assembly since .net 4

Since .net 4.0, an important change is the GAC location is moved to,
C:\Windows\Microsoft.NET\assembly\GAC_MSIL

and the gacutil program is in,
C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\Bin

For .net framework 4.5
C:\Program Files (x86)\Microsoft SDKs\Windows\v8.0A\bin\NETFX 4.0 Tools

So in visual studio.net 2010 or later, in the post build event, you can put in the following codes to add them into the right gac location,

@CALL "%VS100COMNTOOLS%vsvars32.bat"
@gacutil -if   $(TargetFileName)

Sunday, October 21, 2012

When tried to refresh in BizTalk admin console, keeps complaining schema referenced map has been deleted, The local, cached version of the BizTalk Server group configuration is out of date. You must refresh the BizTalk Server group configuration before making further changes

Due to some schema namespace change, and don't want to re-do the maps, so I openned the map in XML edit mode and updated the namespace. Then when I tried to deploy the solution, It failed.
And I am getting the error as the title indicated.

There are some missing or isloated maps data in the database to be cleaned.
In the BizTalkMgmtDb database, look up the bt_mapspec table, delete the map entry for the one the administrator console complained.

And referesh, then it worked.

Wednesday, October 17, 2012

Setup sharepoint 2013 preview in hyper-V encountered an error during setup

I was installing the SharePoint 2013 preview in windows 8 hyper-V environment.
Firstly, it looks good, it is running installing until the last 10% bit,




I am keep getting the unexpected error,



Tried all sorts of ways, such as install all latest update,  run set up as administrator, install office. No matter what, it just can not complete the setup.

The magic to fix it is to modify the virtual machine settings and give 4 virtual CPUs, then it worked !

Many small things that nice to know in SharePoint 2010

Variation Label - used for language locale.
http://office.microsoft.com/en-us/sharepoint-server-help/about-variation-labels-HA010120731.aspx

For List columns performance, need to create indexed list column. This article discusses the database behind the indexed column.
http://blog.dynatrace.com/2009/01/28/sharepoint-list-performance-how-list-column-indices-really-work-under-the-hood/

Feature stapling is a good way to associate the feature to a site definition which is in use, such as Team Site. It has stapler and staplee.
http://blogs.msdn.com/b/kunal_mukherjee/archive/2011/01/11/feature-stapling-in-sharepoint-2010.aspx

Monday, October 15, 2012

Tons of SharePoint 2013 new features links

I haven't really looked at SharePoint 2013 recently, suddenly there are a lot good articles and tutorial blogs to talk about it.

This is a blog site which has a good tutorial to create a sharepoint 2013 site master page and page layout.
http:/microsoftstrategy.com/category/sharepoint-2013

This talks about a new SPSecurityEventReceiver
http://maiomardesouki.com/2012/08/28/whats-new-in-sharepoint-2013-event-receivers/

And Sahil Malik talks about jQuery and cross-domain javascript and using Azure ACS with SharePoint,
http://blah.winsmarts.com/2012-1-jQuery_and_Crossdomain.aspx
http://blah.winsmarts.com/2011-12-Integrate_Azure_ACS_with_SharePoint_in_2_minutes_or_less.aspx

How to use SPXMLContentMapProvider to implement consistent navigation in sp2010,
http://blah.winsmarts.com/2008-1-Implementing_Consistent_Navigation_across_Site_Collections.aspx

SharePoint 2013/2010 claims encoding

Just a wiki document clearly explains the sharepoint user ID meaning, such as
i:0#.w|contoso\chris as my reference.

http://social.technet.microsoft.com/wiki/contents/articles/13921.sharepoint-2013-and-sharepoint-2010-claims-encoding.aspx



Friday, October 5, 2012

Add STS reference is missing in vs.net 2012

VS.net 2012 by default included the Windows Identity Framework and its SDK. However, if you try to right-click the project, you won't be able to find the "Add STS reference" in the context menu.

This has been changed in vs.net 2012 and called "Identity & Access" as below,
 
 
To be able to use this, you need to go to Tools -> Extensions and Updates -> Enter "Identity" in search to install the "Identity and Access Tool" first, then restart vs.net 2012.
 
 
 
 
 
 

Thursday, October 4, 2012

WCF Service configuration tool is the best friend

It is a very productive day today. Have to create a new wcf service and published it as basicHttpBinding, because the service is taking a xml data, so the message size is very possibile to execeed the default 8096 bytes limit.

So the wcf service config needs to be set up with the correct settings such as,

<bindings>
    <basicHttpBinding>
        <binding name="basicHttp" allowCookies="true"
                 maxReceivedMessageSize="20000000" 
                 maxBufferSize="20000000"
                 maxBufferPoolSize="20000000">
            <readerQuotas maxDepth="32" 
                 maxArrayLength="200000000"
                 maxStringContentLength="200000000"/>
        </binding>
    </basicHttpBinding>
</bindings>


Also in service, the bindingConfiguration should be used such as,
<services>
      <service name="Example.Services.TestService">
        <endpoint address="" binding="basicHttpBinding" bindingConfiguration="basicHttp" contract="Example.Services.ITestService"/>
      </service>
  </services>


I have done it a few times, so I just copied & pasted from other service settings and modify it to the one for this service name.

But after a few hours testing, I am still keeping get the "message exceeds the size error". Have to carefully check the web.config and no way find any error for the settings.

In the end, I just removed the old web.config, and bring it up the WCFServiceConfiguration tool to browse to the service assmebly and use the tool to create the correct basicHttpBinding.

Then it worked !!!

The lesson I got from it is, we should use the WCF configuration tool to create the correct config file rather than just copy & paste, which is error-prone and easily can miss something and stucked.