Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (Flatly)
  • No Skin
Collapse
Brand Logo

NetXMS Forum

  1. Home
  2. Support
  3. Update from 2.2.11 to 2.2.12 - "nxdbmgr upgrade" fails

Update from 2.2.11 to 2.2.12 - "nxdbmgr upgrade" fails

Scheduled Pinned Locked Moved Support
6 Posts 3 Posters 48.6k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S
    S
    StanHubble
    wrote on last edited by
    #1

    NetXMS Database Manager Version 2.2.12 Build 9516 (2.2.12) (UNICODE)

    Upgrading database...
    Upgrading from version 22.41 to 22.42
    SQL query failed ([Microsoft][SQL Server Native Client 10.0][SQL Server]Cannot define PRIMARY KEY constraint on nullable
     column in table 'address_lists'.):
    ALTER TABLE address_lists ADD CONSTRAINT pk_address_lists PRIMARY KEY (list_type,community_id,zone_uin,addr_type,addr1,addr2)
    Rolling back last stage due to upgrade errors...
    Database upgrade failed

    I started from 2.2.10 and got this error on a direct upgrade to 2.2.12 so i reverted back to 2.2.10,
    did a ".\nxdbmgr check" --> clean.
    upgraded to 2.2.11
    then another ".\nxdbmgr check" --> clean.
    and tried another upgrade to 2.2.12 with the same error.

    The first run through i let the windows installer update the schema but things ended up in the same conditions. subsequent tries I deselected the update schema option, but nxdbmgr upgrade fails with the same condition.

    at this point i have reverted back to 2.2.10 , any ideas?

    server -> win2012r2
    dbserver -> win2012r2 with
    Microsoft SQL Server Management Studio 12.0.5207.0
    Microsoft Analysis Services Client Tools 12.0.5207.0
    Microsoft Data Access Components (MDAC) 6.3.9600.17415
    Microsoft MSXML 3.0 6.0
    Microsoft Internet Explorer 9.11.9600.19236
    Microsoft .NET Framework 4.0.30319.42000
    Operating System 6.3.9600

    1 Reply Last reply
    0
    • V
      V
      Victor Kirhenshtein
      wrote on last edited by
      #2

      Please try to replace nxdbmgr.exe with attached one and run database upgrade again.

      Best regards,
      Victor


      nxdbmgr.exe

      1 Reply Last reply
      0
      • S
        S
        StanHubble
        wrote on last edited by
        #3

        Thanks alot Victor!!
        it worked without a hitch.

        PS C:\ProgramData\NetXMS\bin> .\nxdbmgr.exe upgrade
        NetXMS Database Manager Version 2.2.12 Build 9516 (2.2.12-2-gf93e98c349) (UNICODE)

        Upgrading database...
        Upgrading from version 22.40 to 22.41
        Upgrading from version 22.41 to 22.42
        Database upgrade succeeded
        PS C:\ProgramData\NetXMS\bin> .\nxdbmgr.exe check
        NetXMS Database Manager Version 2.2.12 Build 9516 (2.2.12-2-gf93e98c349) (UNICODE)

        Checking database (excluding collected data):
        * Zone object properties                                              [PASSED]
        * Node object properties                                              [PASSED]
        * Node to subnet bindings                                              [PASSED]
        * Interface object properties                                          [PASSED]
        * Interface bindings                                                  [PASSED]
        * Network service object properties                                    [PASSED]
        * Network service bindings                                            [PASSED]
        * Cluster object properties                                            [PASSED]
        * Cluster member nodes                                                [PASSED]
        * Template to node mapping                                            [PASSED]
        * Object properties                                                    [PASSED]
        * Container membership                                                [PASSED]
        * Event processing policy                                              [PASSED]
        * Network map links                                                    [PASSED]
        * Data tables                                                          [PASSED]
        * Raw DCI values table                                                [PASSED]
        * DCI thresholds                                                      [PASSED]
        * Table DCI thresholds                                                [PASSED]
        Database doesn't contain any errors
        Database check completed

        1 Reply Last reply
        0
        • J
          J
          Junoonguy
          wrote on last edited by
          #4

          Hello Alex / Victor,

          Whenever i use upgrade command on, "Database is locked"

          C:\NetXMS\bin>.\nxdbmgr.exe upgrade

          Upgrading database...
          Database is locked

          Please help,
          Thanks in advance

          1 Reply Last reply
          0
          • V
            V
            Victor Kirhenshtein
            wrote on last edited by
            #5

            Hi,

            make sure that netxmsd is not running, then run

            nxdbmgr unlock
            

            to remove database lock.

            Best regards,
            Victor

            1 Reply Last reply
            0
            • J
              J
              Junoonguy
              wrote on last edited by
              #6

              Thanks Victor, its unlock now

              Regards,
              Junoonguy

              1 Reply Last reply
              0

              Hello! It looks like you're interested in this conversation, but you don't have an account yet.

              Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

              With your input, this post could be even better 💗

              Register Login
              Reply
              • Reply as topic
              Log in to reply
              • Oldest to Newest
              • Newest to Oldest
              • Most Votes


              • Login

              • Don't have an account? Register

              • Login or register to search.
              Powered by NodeBB Contributors
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • Users
              • Groups