Last week while making a simple BizTalk Server 2013 multi-computer environment (1 SQL Server and 1 BizTalk Server both running Windows Server 2012) configuration I faced several issues to properly configure BAM Portal, this was the first one.
I was able to properly configure all the features: Enterprise SSO, Group, BizTalk Runtime, Business Rules Engine, BizTalk EDI/AS2 Runtime and even BAM Tools without any kind of problem, however, every time I tried to configure BAM Portal I was getting the following error:
BAM Portal: Attempted to read or write protected memory. This is often an indication that other memory is corrupt. (Configuration)
When checking the BizTalk Server Configuration log file, we were able to see something like the following message:
[datetime … Error Configuration Framework] Feature: [BAM Portal] Failed to configure with error message [<Exception Message=”Unexpected exception occurred while configuring [BAM Portal].” Source=”” HelpID=””><Exception Message=”Attempted to read or write protected memory. This is often an indication that other memory is corrupt.” Source=”Configuration” HelpID=”” /></Exception>]
However, this is the generic message and doesn’t give us the real cause and doesn’t help us track the problem.
Suggestion: When this appends, don’t get stuck in that line, you should continue to read the log file because you will find useful and valid pieces of information!
In this case, the real problem was:
[datetime … Error ConfigHelper] Cannot alter the role ‘NSSubscriberAdmin’, because it does not exist or you do not have permission.
Cause
The BizTalk Server Configuration Tool is trying to add the “BAM Management Web Service user” that was specified in the BAM Portal section into a database role called “NSSubscriberAdmin”, which doesn’t exist in the BAM Alert Application Database (BAMAlertsApplication) and for that reason, it raises this exception.
Solution
There are some known issues in the BizTalk Server 2013 release that was fixed in the Cumulative Update 1, especially this one regarding BAM Tools: KB article 2832137 – FIX: BAM tools cannot be configured in a multi-node BizTalk Server 2013 environment. I know is not exactly the same error, nevertheless, I advise that before you try to configure BizTalk Server 2013 you should apply the CU’s available.
However in my case to solve the problem you must manually add “NSSubscriberAdmin” Database Role to BAM Alert Application Database (BAMAlertsApplication) by:
- Expand a server group, and then expand a server.
- Expand “Databases”, and then expand the BAMAlertsApplication database
- Expand “Roles”. Right-click over “Roles” and select “New Database Role” option.
- In the Name box, enter the following name: “NSSubscriberAdmin”.
- Click “OK”.
Alternative you can use the following SQL Query:
USE BAMAlertsApplication CREATE ROLE NSSubscriberAdmin AUTHORIZATION dbo GO
Fortunately, I was able to find this problem in the BizTalk Server: List of Errors and Warnings, Causes, and Solutions TechNet Wiki article which led me to René Brauwers solution.