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 GP (Archived)

Upgrade GP2013R2 to GP2015R2 Error StoreDatabaseRecoveryMode

(0) ShareShare
ReportReport
Posted on by 1,552

I am testing our upgrade and on the Dynamics and the first company update I get the following error:

"The stored procedure StoreDatabaseRecoveryMode() of form duSQL Pass Through SQL returned the following results: DBMS: 5069, Microsoft Dynamics GP: 0."

Differences in this upgrade from others include:

- moved to SQL Server 2016 (Microsoft assured us this is supported for 2015R2)

- selected "web client runtime" in the features as we want to test this

- our SQL Server is set up with a high availability cluster

Does anyone have any insight as to what is causing this error?

I have the dexsql.log going (man, it is slow with that turned on!)

My next attempt after this first company finishes (yes, it lets me continue on to finish) is to un-install the Web Client Runtime and try again.  But if that doesn't work I will be back to square one.

Thank you.

*This post is locked for comments

I have the same question (0)
  • Mick Egan Profile Picture
    3,561 on at

    Barb,

    Haven't seen this error previously.

    Maybe a few checks:

    Is Database Compatibility set to SQL2016 (130).

    Database Owner DYNSA.

    SQL Server Collation set correctly.

    Dex Stored Procedures ran against the Master Database.

    Mick

  • Accounting Department Profile Picture
    1,552 on at

    Yes to all except changing db compatibility (doing that now).

    I will try again and see if I still get the error.

    Also it is super slow. One company took 3 hours and should only take 20-30 min.  Do we need to turn off the sync on the cluster thing?

  • Accounting Department Profile Picture
    1,552 on at

    Turned off SQL logging in the dex.ini file, so it is much faster but I still get the error.

  • Verified answer
    Accounting Department Profile Picture
    1,552 on at

    ME again! I found the error in the SQL Log file and there is a point where it tries to change the recovery model to "simple" but it won't allow it because of the SQL Server High Availability Group.

    Here is the exact error, which is similar to the error I get when I try to manually change the Recovery Model from Full to Simple in SQL Management Studio.

    Microsoft told us that GP2015R2 is ocmpatible with SQL Server 2016 when we called, so I don't think that is causing it. I have asked our Server Admin to find a way to shut that thing off so I can upgrade.

    /*  Date: 04/17/2017  Time: 8:36:38

    stmt(56682984):*/

    if (select DATABASEPROPERTYEX( 'myGPcompanyDB' , 'Recovery' )) <> 'SIMPLE' BEGIN if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[duRecoveryModel]') and OBJECTPROPERTY(id, N'IsUserTable') = 1) BEGIN drop table [dbo].[duRecoveryModel] END select (select convert(varchar(12),(select DATABASEPROPERTYEX( 'myGPcompanyDB' , 'Recovery' )) ) ) as 'DatabaseRecoveryModel' into [duRecoveryModel] ALTER DATABASE myGPcompanyDB SET RECOVERY SIMPLE END

    /*

    /*  Date: 04/17/2017  Time: 8:36:39

    SQLSTATE:(37000) Native Err:(1468) stmt(56682984):*/

    [Microsoft][SQL Server Native Client 11.0][SQL Server]The operation cannot be performed on database "myGPcompanyDB" because it is involved in a database mirroring session or an availability group. Some operations are not allowed on a database that is participati*/

    /*

    /*  Date: 04/17/2017  Time: 8:36:39

    SQLSTATE:(37000) Native Err:(5069) stmt(56682984):*/

    [Microsoft][SQL Server Native Client 11.0][SQL Server]ALTER DATABASE statement failed.*/

    /*

    /*  Date: 04/17/2017  Time: 8:36:39

    SQLSTATE:(00000) Native Err:(5069) stmt(56682984):*/

    */

    /*

    /*  Date: 04/17/2017  Time: 8:36:39

    SQLSTATE:(00000) Native Err:(5069) status(58):*/

    SWSTATUS DUMP*/

  • Suggested answer
    Mick Egan Profile Picture
    3,561 on at

    Barb,

    Great news, I have also found replication on Tables can also cause issues with upgrades as well, you should be good to upgrade once the mirroring is turned off, this will allow the database to be put into Simple Mode during the upgrade.

    Mick

  • Suggested answer
    Beat Bucher  GP Geek  GPUG All Star Profile Picture
    28,058 Moderator on at

    Hi Barb,

    Great finding.. I was going to reply that I didn't think that SQL replication was supported as an operational model with GP, but then reading further down, saw that you find yourself the culprit.. :-)

    You definitely want to disable replication by the time the upgrade is processed and then turn it back on when all is done.

    Here is a KB support article from Microsoft that states the necessity to disable mirroring in SQL before proceeding with the upgrade :

    support.microsoft.com/.../description-of-the-requirements-to-run-replication,-clustering,-log-shipping,-and-database-mirroring-together-with-microsoft-dynamics-gp

    PS: in case you're interested, here is an older thread regarding log shipping vs. replication with Dynamics CRM, but the same logic would apply to GP. https://community.dynamics.com/gp/f/32/t/105406

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 GP (Archived)

#1
mtabor Profile Picture

mtabor 1

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans