Inedo Community Forums Forums
    • Recent
    • Tags
    • Popular
    • Login

    Welcome to the Inedo Forums! Check out the Forums Guide for help getting started.

    If you are experiencing any issues with the forum software, please visit the Contact Form on our website and let us know!

    ProGet v24 fails to initialize/upgrade the SQL Server database

    Scheduled Pinned Locked Moved Support
    4 Posts 2 Posters 23 Views 1 Watching
    Loading More Posts
    • 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.
    • H Offline
      husterk_2844
      last edited by

      I am attempting to test ProGet v24 on a local docker stack currently hosting ProGet v23. However, ProGet fails to start due to a failure to initialize/upgrade the database. Note that I am using the mcr.microsoft.com/mssql/server:2022-latest SQL Server and proget.inedo.com/productimages/inedo/proget:24 ProGet images in my Docker Compose file.

      I also tested a similar scenario using a fresh database instance rather than upgrading an instance with existing ProGet v23 data. Unfortunately, I am seeing the same errors.

      The specific failure logs that I am seeing when testing with a fresh (empty) database are shown below. The final error message repeats indefinitely as ProGet attempts to start but fails.

      ProGet version is 24.0.11.10.
      Current DB schema version is unknown.
      Database is not initialized; initializing...
      Database initialized.
      Executing untracked script DDL-DML/0000. Untracked/00. EnsureDbo.sql...
      Executing untracked script DDL-DML/0000. Untracked/10. Block 5.3 Upgrades.sql...
      Executing untracked script DDL-DML/0000. Untracked/10. Block SQL Server 2005.sql...
      Executing tracked script DDL-DML/v1-6/v1/0002. 0.1.0/10 SET DATABASE PROPERTIES.sql...
      Error number: 226
      Line number: 1
      ALTER DATABASE statement not allowed within multi-statement transaction.
      Error number: 226
      Line number: 1
      ALTER DATABASE statement not allowed within multi-statement transaction.
      DDL-DML/v1-6/v1/0002. 0.1.0/10 SET DATABASE PROPERTIES.sql executed successfully.
      Executing tracked script DDL-DML/v1-6/v1/0002. 0.1.0/20 CREATE TYPES.sql...
      Incorrect syntax near 'GO'.
      'CREATE RULE' must be the first statement in a query batch.
      Incorrect syntax near 'GO'.
      Incorrect syntax near 'GO'.
      ProGet version is 24.0.11.10.
      Current DB schema version is unknown.
      Scripts not executed; at least one script has unresolved errors.
      Use the "errors" command to view unresolved errors, or use the --force argument to run anyway.
      

      Any help with this would be greatly appreciated.

      stevedennisS 1 Reply Last reply Reply Quote 0
      • stevedennisS Offline
        stevedennis inedo-engineer @husterk_2844
        last edited by

        Hi @husterk_2844 ,

        Those are some strange errors and I haven't seen them before. It seems that something is wrong with SQL Server.

        What's interesting/notable here is that SQL Server is saying Incorrect syntax near 'GO' on a the 20 CREATE TYPES.sql script. That hasn't changed in 10+ years... and it's also unlikely that the latest SQL Server 2022 is failing to parse/execute that script, but I can't think of anything else.

        The error occurring on 10 SET DATABASE PROPERTIES.sql is also peculiar; that script has a TRY/CATCH, so it's not considered failure -- but the expected error is definitely not "ALTER DATABASE statement not allowed within multi-statement transaction."

        From here, I would "play around" with different versions of SQL Server and ProGet. We've never seen anything like this, so don't really know where to start.

        As for ProGet failing to start... a database failure would definitely yield that behavior, so that's not really an issue. The question really is why these database errors are occurring.

        Thanks,
        Steve

        1 Reply Last reply Reply Quote 0
        • H Offline
          husterk_2844
          last edited by

          @stevedennis Thanks for the reply. I have tested my local Docker configuration with multiple MSSQL Server versions. The results of these tests show the same errors that I reported whenever I attempted to use the inedo/proget:24 image.

          • mssql/server:2019-latest + inedo/proget:23 = SUCCESS
          • mssql/server:2022-latest + inedo/proget:23 = SUCCESS
          • mssql/server:2019-latest + inedo/proget:24 = FAILURE
          • mssql/server:2022-latest + inedo/proget:24 = FAILURE

          I'm not sure where else to go from here.

          stevedennisS 1 Reply Last reply Reply Quote 0
          • stevedennisS Offline
            stevedennis inedo-engineer @husterk_2844
            last edited by

            Hi @husterk_2844 ,

            I'm afraid we're at a loss here; no one else has reported any kind of errors like this, and I can't imagine what would even cause such a problem.

            I suspect there is something off about your Docker Compose file? That seems to be the only thing different than the basic setup.

            I would just try to re-follow the basic instructions we posted:
            https://docs.inedo.com/docs/installation/linux/docker-guide

            That's what we use to test, and lots of users install and upgrade without a problem.

            Thanks,
            Steve

            1 Reply Last reply Reply Quote 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
            • 1 / 1
            • First post
              Last post
            Inedo Website Home • Support Home • Code of Conduct • Forums Guide • Documentation