web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)
Suggested Answer

I have the error "AX Attempted to read or write protected memory. This is often an indication that other memory is corrupt."

(0) ShareShare
ReportReport
Posted on by

Hi.

We have a web service developed in Visual Basic .Net, 2008.

The service is installed in IIS7 (Win 2008). The website is configured to use the business connector in the app pool. Ax 2009 has the  business connector proxy user configured in the system accounts.

The web service invoke a static function of AX. The function has a parameter of type string. This string is in XML format . When the string is short works fine, but when the string is long (more than 50 characters) fails and the result is the following:

AX Attempted to read or write protected memory. This is often an indication that other memory is corrupt

In Event viewer we have two events:

EventID 110

Source: Dynamics .NET Business Connector 5.0

Attempt to clear pointerMap when it still contains objects

And

EventID 110

Source: Dynamics .NET Business Connector 5.0

Attempted to read or write protected memory. This is often an indication that other memory is corrupt.

at BCLogon(LOGON_INFO* , SesPblk_t** , Char** )

at Microsoft.Dynamics.BusinessConnectorNet.Axapta.Logon(BC_PROXY_ACCOUNT_INFO* pBCProxyAccountInfo, String company, String

If the function is executed in AX with the same information the result is OK.

What could it be?

Thank you.

*This post is locked for comments

I have the same question (0)
  • Community Member Profile Picture
    on at

    Hi,

    I have similar symptoms (same error events) with an Enterprise Portal based add-on; a main difference though is that while the trigger of your issue seems to be identified (string length), ours is irregular and time/activity dependant (everything ok after an IIS restart, gets worse with time afterwards).

    FYI I just opened an MS incident about it; our first action was to set the recycling options for the application pool (Regular Time Interval) to a duration smaller than the regular crashes, e.g. a few hours - too early to draw conclusions though.

    May I ask if you found out anything about your own problem?

    Thanks in advance

    Ben

  • Community Member Profile Picture
    on at

    I have had similar problems. They disappeared when I installed the latest kernel.

    UPDATE:

    I did not find a corresponding KB Article, but since I had some problems, I installed the Kernel rollup 6 after reading the following in the Rolllup description:

    Assume that you try to access values in the Web session. However, if the LogonAs call is not logged off immediately, when the build-in webSession function is called from the .Net Business Connector, you receive an error message in the event viewer.

    The different problems that I had disappeared after installing this version.

     

     

  • Larry Reski Profile Picture
    on at

    "AX Attempted to read or write protected memory" is a general error for many possible issues.  

    1. Mixing kernel versions or builds in a single machine or between the AOS and .NET BC

    2. Promoting code to the AOS but not restarting applications using the .Net BC

    3. Problems in coding of the .NET BC

    You need to understand changes to code or environment while the .NET BC has been running, has the AOS been restarted while the .NET BC has been running.  Review the AOS and application event logs from both server and understand the sequence of events in time.

  • MaartenDM Profile Picture
    15 on at

    I had received same error in AX2012 - CU3 environment. But we don't use the business connector.

  • Satyanarayan Sahoo Profile Picture
    230 on at

    Hi Leonardo,

    Exactly the same i am getting the exception in Eventvwr in PRODUCTION.And production is having AX 2009 RU7.

    Is it required to install RU8 to fix this ?

  • PilgrimCZ Profile Picture
    572 on at

    Hi all,

    just fast info. I got same error - "Attempted to read or write protected memory. This is often an indication that other memory is corrupt." - when setup was not launched with Run as Administrator. No depend on that I was logged on machine as local admin.

    Stupid, but may help. ;)

    Marek

  • Murugan.p Profile Picture
    20 on at

    Thanks Marek.. My issue resolved by running the installer as admin..

  • Suggested answer
    sgoldyaev Profile Picture
    5 on at

    Some of our clients also has this error. After some research we rebuild our app with Prefer 32-bit and exception is gone.

    We are using Business Connector 5

    WinForm, .Net 4.7.1 

    x64 platform

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Martin Dráb Profile Picture

Martin Dráb 4 Most Valuable Professional

#1
Priya_K Profile Picture

Priya_K 4

#3
MyDynamicsNAV Profile Picture

MyDynamicsNAV 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans