SQL Management Studio 2016 account disabled





.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ margin-bottom:0;
}







0















I have 2 instances, sqlexpress and mssqlserver. I made fool mistake, I disabled the login account that I used it all of the time to login in mssqlserver using windows authentication. And I don't remember the 'sa' password because never use it to log in.



I have read and practice some tips about this problem, and Connect to SQL Server When System Administrators Are Locked Out but my problem still isn't solved.



So, my questions. Does uninstall then reinstall can give me access again? If yes, which should I uninstall-reinstall? My sql server or ssms?
I'm not worried about databases, I just want the access to this instance again for learning.



enter image description here










share|improve this question
















bumped to the homepage by Community 14 mins ago


This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.











  • 1





    Did you try through that msdn.microsoft.com/en-us/library/ms188236.aspx

    – Md Haidar Ali Khan
    Jan 24 '17 at 13:53











  • Just now, but the message is same. After i type SQLCMD -E -S <servername> , this gives me message : Sqlcmd: Error: Microsoft ODBC Driver 11 for SQL Server : Login failed for user '<myusername>'. Reason: The account is disabled..

    – Anti Mafia
    Jan 24 '17 at 14:09






  • 1





    Start the SQL Server in single user mode and re-enable the account: dba.stackexchange.com/questions/101378/…

    – Spörri
    Jan 24 '17 at 14:19











  • @Spörri it doesn't work, gives me message: is not a valid login or you do not have permission. I have spared so many times for it, this one day, how about my question uninstall?

    – Anti Mafia
    Jan 24 '17 at 15:32











  • Are you sure that connecting as single-user (as you showed in the link) didn't work? You have to use a LOCAL Admin account.

    – Renato Afonso
    Jan 24 '17 at 18:20


















0















I have 2 instances, sqlexpress and mssqlserver. I made fool mistake, I disabled the login account that I used it all of the time to login in mssqlserver using windows authentication. And I don't remember the 'sa' password because never use it to log in.



I have read and practice some tips about this problem, and Connect to SQL Server When System Administrators Are Locked Out but my problem still isn't solved.



So, my questions. Does uninstall then reinstall can give me access again? If yes, which should I uninstall-reinstall? My sql server or ssms?
I'm not worried about databases, I just want the access to this instance again for learning.



enter image description here










share|improve this question
















bumped to the homepage by Community 14 mins ago


This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.











  • 1





    Did you try through that msdn.microsoft.com/en-us/library/ms188236.aspx

    – Md Haidar Ali Khan
    Jan 24 '17 at 13:53











  • Just now, but the message is same. After i type SQLCMD -E -S <servername> , this gives me message : Sqlcmd: Error: Microsoft ODBC Driver 11 for SQL Server : Login failed for user '<myusername>'. Reason: The account is disabled..

    – Anti Mafia
    Jan 24 '17 at 14:09






  • 1





    Start the SQL Server in single user mode and re-enable the account: dba.stackexchange.com/questions/101378/…

    – Spörri
    Jan 24 '17 at 14:19











  • @Spörri it doesn't work, gives me message: is not a valid login or you do not have permission. I have spared so many times for it, this one day, how about my question uninstall?

    – Anti Mafia
    Jan 24 '17 at 15:32











  • Are you sure that connecting as single-user (as you showed in the link) didn't work? You have to use a LOCAL Admin account.

    – Renato Afonso
    Jan 24 '17 at 18:20














0












0








0








I have 2 instances, sqlexpress and mssqlserver. I made fool mistake, I disabled the login account that I used it all of the time to login in mssqlserver using windows authentication. And I don't remember the 'sa' password because never use it to log in.



I have read and practice some tips about this problem, and Connect to SQL Server When System Administrators Are Locked Out but my problem still isn't solved.



So, my questions. Does uninstall then reinstall can give me access again? If yes, which should I uninstall-reinstall? My sql server or ssms?
I'm not worried about databases, I just want the access to this instance again for learning.



enter image description here










share|improve this question
















I have 2 instances, sqlexpress and mssqlserver. I made fool mistake, I disabled the login account that I used it all of the time to login in mssqlserver using windows authentication. And I don't remember the 'sa' password because never use it to log in.



I have read and practice some tips about this problem, and Connect to SQL Server When System Administrators Are Locked Out but my problem still isn't solved.



So, my questions. Does uninstall then reinstall can give me access again? If yes, which should I uninstall-reinstall? My sql server or ssms?
I'm not worried about databases, I just want the access to this instance again for learning.



enter image description here







sql-server ssms sql-server-2016






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Jan 24 '17 at 14:44









Ian_H

1,425515




1,425515










asked Jan 24 '17 at 13:42









Anti MafiaAnti Mafia

12




12





bumped to the homepage by Community 14 mins ago


This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.







bumped to the homepage by Community 14 mins ago


This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.










  • 1





    Did you try through that msdn.microsoft.com/en-us/library/ms188236.aspx

    – Md Haidar Ali Khan
    Jan 24 '17 at 13:53











  • Just now, but the message is same. After i type SQLCMD -E -S <servername> , this gives me message : Sqlcmd: Error: Microsoft ODBC Driver 11 for SQL Server : Login failed for user '<myusername>'. Reason: The account is disabled..

    – Anti Mafia
    Jan 24 '17 at 14:09






  • 1





    Start the SQL Server in single user mode and re-enable the account: dba.stackexchange.com/questions/101378/…

    – Spörri
    Jan 24 '17 at 14:19











  • @Spörri it doesn't work, gives me message: is not a valid login or you do not have permission. I have spared so many times for it, this one day, how about my question uninstall?

    – Anti Mafia
    Jan 24 '17 at 15:32











  • Are you sure that connecting as single-user (as you showed in the link) didn't work? You have to use a LOCAL Admin account.

    – Renato Afonso
    Jan 24 '17 at 18:20














  • 1





    Did you try through that msdn.microsoft.com/en-us/library/ms188236.aspx

    – Md Haidar Ali Khan
    Jan 24 '17 at 13:53











  • Just now, but the message is same. After i type SQLCMD -E -S <servername> , this gives me message : Sqlcmd: Error: Microsoft ODBC Driver 11 for SQL Server : Login failed for user '<myusername>'. Reason: The account is disabled..

    – Anti Mafia
    Jan 24 '17 at 14:09






  • 1





    Start the SQL Server in single user mode and re-enable the account: dba.stackexchange.com/questions/101378/…

    – Spörri
    Jan 24 '17 at 14:19











  • @Spörri it doesn't work, gives me message: is not a valid login or you do not have permission. I have spared so many times for it, this one day, how about my question uninstall?

    – Anti Mafia
    Jan 24 '17 at 15:32











  • Are you sure that connecting as single-user (as you showed in the link) didn't work? You have to use a LOCAL Admin account.

    – Renato Afonso
    Jan 24 '17 at 18:20








1




1





Did you try through that msdn.microsoft.com/en-us/library/ms188236.aspx

– Md Haidar Ali Khan
Jan 24 '17 at 13:53





Did you try through that msdn.microsoft.com/en-us/library/ms188236.aspx

– Md Haidar Ali Khan
Jan 24 '17 at 13:53













Just now, but the message is same. After i type SQLCMD -E -S <servername> , this gives me message : Sqlcmd: Error: Microsoft ODBC Driver 11 for SQL Server : Login failed for user '<myusername>'. Reason: The account is disabled..

– Anti Mafia
Jan 24 '17 at 14:09





Just now, but the message is same. After i type SQLCMD -E -S <servername> , this gives me message : Sqlcmd: Error: Microsoft ODBC Driver 11 for SQL Server : Login failed for user '<myusername>'. Reason: The account is disabled..

– Anti Mafia
Jan 24 '17 at 14:09




1




1





Start the SQL Server in single user mode and re-enable the account: dba.stackexchange.com/questions/101378/…

– Spörri
Jan 24 '17 at 14:19





Start the SQL Server in single user mode and re-enable the account: dba.stackexchange.com/questions/101378/…

– Spörri
Jan 24 '17 at 14:19













@Spörri it doesn't work, gives me message: is not a valid login or you do not have permission. I have spared so many times for it, this one day, how about my question uninstall?

– Anti Mafia
Jan 24 '17 at 15:32





@Spörri it doesn't work, gives me message: is not a valid login or you do not have permission. I have spared so many times for it, this one day, how about my question uninstall?

– Anti Mafia
Jan 24 '17 at 15:32













Are you sure that connecting as single-user (as you showed in the link) didn't work? You have to use a LOCAL Admin account.

– Renato Afonso
Jan 24 '17 at 18:20





Are you sure that connecting as single-user (as you showed in the link) didn't work? You have to use a LOCAL Admin account.

– Renato Afonso
Jan 24 '17 at 18:20










2 Answers
2






active

oldest

votes


















0














Since you're using this instance for learning and don't care about the databases, you might also want to learn troubleshooting. The link from your post is one of the "break glass in case of emergencies" panels. If it didn't work, you really want to figure out why. Else, if this happens to an instance where you care about both the instance and the user databases, you'll be in a pretty rough spot. Is there anything useful in the error log that might hint to what happened?



If you really don't care to investigate, you can uninstall the existing instance and install a new one. That lets you specify the SA password or identify the user account that will be admin (or both). However, this wipes all previous user logins - there is no "re-install" per se with that preserves security principals or other objects that reside in a system database.






share|improve this answer































    0














    If both of the instances use the same service account, and can login to eachother, and you can connect to one of the instances as sysadmin then you could use xp_cmdshell to create a login on the other instance.



    E.G.



    EXEC sp_configure 'show advanced options', 1;  
    RECONFIGURE WITH OVERRIDE;
    EXEC sp_configure 'xp_cmdshell', 1;
    RECONFIGURE WITH OVERRIDE;

    exec master..xp_cmdshell 'SQLCMD -S SERVERNAME -Q "CREATE LOGIN [Temp] WITH PASSWORD = ''P@SsWord12345'' exec sp_addsrvrolemember ''Temp'', ''sysadmin'' " ';


    It isn't a very clean solution, but I used it once to grant myself access to other instances on the same machine.






    share|improve this answer
























      Your Answer








      StackExchange.ready(function() {
      var channelOptions = {
      tags: "".split(" "),
      id: "182"
      };
      initTagRenderer("".split(" "), "".split(" "), channelOptions);

      StackExchange.using("externalEditor", function() {
      // Have to fire editor after snippets, if snippets enabled
      if (StackExchange.settings.snippets.snippetsEnabled) {
      StackExchange.using("snippets", function() {
      createEditor();
      });
      }
      else {
      createEditor();
      }
      });

      function createEditor() {
      StackExchange.prepareEditor({
      heartbeatType: 'answer',
      autoActivateHeartbeat: false,
      convertImagesToLinks: false,
      noModals: true,
      showLowRepImageUploadWarning: true,
      reputationToPostImages: null,
      bindNavPrevention: true,
      postfix: "",
      imageUploader: {
      brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
      contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
      allowUrls: true
      },
      onDemand: true,
      discardSelector: ".discard-answer"
      ,immediatelyShowMarkdownHelp:true
      });


      }
      });














      draft saved

      draft discarded


















      StackExchange.ready(
      function () {
      StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fdba.stackexchange.com%2fquestions%2f162067%2fsql-management-studio-2016-account-disabled%23new-answer', 'question_page');
      }
      );

      Post as a guest















      Required, but never shown

























      2 Answers
      2






      active

      oldest

      votes








      2 Answers
      2






      active

      oldest

      votes









      active

      oldest

      votes






      active

      oldest

      votes









      0














      Since you're using this instance for learning and don't care about the databases, you might also want to learn troubleshooting. The link from your post is one of the "break glass in case of emergencies" panels. If it didn't work, you really want to figure out why. Else, if this happens to an instance where you care about both the instance and the user databases, you'll be in a pretty rough spot. Is there anything useful in the error log that might hint to what happened?



      If you really don't care to investigate, you can uninstall the existing instance and install a new one. That lets you specify the SA password or identify the user account that will be admin (or both). However, this wipes all previous user logins - there is no "re-install" per se with that preserves security principals or other objects that reside in a system database.






      share|improve this answer




























        0














        Since you're using this instance for learning and don't care about the databases, you might also want to learn troubleshooting. The link from your post is one of the "break glass in case of emergencies" panels. If it didn't work, you really want to figure out why. Else, if this happens to an instance where you care about both the instance and the user databases, you'll be in a pretty rough spot. Is there anything useful in the error log that might hint to what happened?



        If you really don't care to investigate, you can uninstall the existing instance and install a new one. That lets you specify the SA password or identify the user account that will be admin (or both). However, this wipes all previous user logins - there is no "re-install" per se with that preserves security principals or other objects that reside in a system database.






        share|improve this answer


























          0












          0








          0







          Since you're using this instance for learning and don't care about the databases, you might also want to learn troubleshooting. The link from your post is one of the "break glass in case of emergencies" panels. If it didn't work, you really want to figure out why. Else, if this happens to an instance where you care about both the instance and the user databases, you'll be in a pretty rough spot. Is there anything useful in the error log that might hint to what happened?



          If you really don't care to investigate, you can uninstall the existing instance and install a new one. That lets you specify the SA password or identify the user account that will be admin (or both). However, this wipes all previous user logins - there is no "re-install" per se with that preserves security principals or other objects that reside in a system database.






          share|improve this answer













          Since you're using this instance for learning and don't care about the databases, you might also want to learn troubleshooting. The link from your post is one of the "break glass in case of emergencies" panels. If it didn't work, you really want to figure out why. Else, if this happens to an instance where you care about both the instance and the user databases, you'll be in a pretty rough spot. Is there anything useful in the error log that might hint to what happened?



          If you really don't care to investigate, you can uninstall the existing instance and install a new one. That lets you specify the SA password or identify the user account that will be admin (or both). However, this wipes all previous user logins - there is no "re-install" per se with that preserves security principals or other objects that reside in a system database.







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Jan 25 '17 at 1:20









          SQLmojoeSQLmojoe

          1,32037




          1,32037

























              0














              If both of the instances use the same service account, and can login to eachother, and you can connect to one of the instances as sysadmin then you could use xp_cmdshell to create a login on the other instance.



              E.G.



              EXEC sp_configure 'show advanced options', 1;  
              RECONFIGURE WITH OVERRIDE;
              EXEC sp_configure 'xp_cmdshell', 1;
              RECONFIGURE WITH OVERRIDE;

              exec master..xp_cmdshell 'SQLCMD -S SERVERNAME -Q "CREATE LOGIN [Temp] WITH PASSWORD = ''P@SsWord12345'' exec sp_addsrvrolemember ''Temp'', ''sysadmin'' " ';


              It isn't a very clean solution, but I used it once to grant myself access to other instances on the same machine.






              share|improve this answer




























                0














                If both of the instances use the same service account, and can login to eachother, and you can connect to one of the instances as sysadmin then you could use xp_cmdshell to create a login on the other instance.



                E.G.



                EXEC sp_configure 'show advanced options', 1;  
                RECONFIGURE WITH OVERRIDE;
                EXEC sp_configure 'xp_cmdshell', 1;
                RECONFIGURE WITH OVERRIDE;

                exec master..xp_cmdshell 'SQLCMD -S SERVERNAME -Q "CREATE LOGIN [Temp] WITH PASSWORD = ''P@SsWord12345'' exec sp_addsrvrolemember ''Temp'', ''sysadmin'' " ';


                It isn't a very clean solution, but I used it once to grant myself access to other instances on the same machine.






                share|improve this answer


























                  0












                  0








                  0







                  If both of the instances use the same service account, and can login to eachother, and you can connect to one of the instances as sysadmin then you could use xp_cmdshell to create a login on the other instance.



                  E.G.



                  EXEC sp_configure 'show advanced options', 1;  
                  RECONFIGURE WITH OVERRIDE;
                  EXEC sp_configure 'xp_cmdshell', 1;
                  RECONFIGURE WITH OVERRIDE;

                  exec master..xp_cmdshell 'SQLCMD -S SERVERNAME -Q "CREATE LOGIN [Temp] WITH PASSWORD = ''P@SsWord12345'' exec sp_addsrvrolemember ''Temp'', ''sysadmin'' " ';


                  It isn't a very clean solution, but I used it once to grant myself access to other instances on the same machine.






                  share|improve this answer













                  If both of the instances use the same service account, and can login to eachother, and you can connect to one of the instances as sysadmin then you could use xp_cmdshell to create a login on the other instance.



                  E.G.



                  EXEC sp_configure 'show advanced options', 1;  
                  RECONFIGURE WITH OVERRIDE;
                  EXEC sp_configure 'xp_cmdshell', 1;
                  RECONFIGURE WITH OVERRIDE;

                  exec master..xp_cmdshell 'SQLCMD -S SERVERNAME -Q "CREATE LOGIN [Temp] WITH PASSWORD = ''P@SsWord12345'' exec sp_addsrvrolemember ''Temp'', ''sysadmin'' " ';


                  It isn't a very clean solution, but I used it once to grant myself access to other instances on the same machine.







                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered Sep 25 '18 at 12:17









                  Randi VertongenRandi Vertongen

                  4,4661924




                  4,4661924






























                      draft saved

                      draft discarded




















































                      Thanks for contributing an answer to Database Administrators Stack Exchange!


                      • Please be sure to answer the question. Provide details and share your research!

                      But avoid



                      • Asking for help, clarification, or responding to other answers.

                      • Making statements based on opinion; back them up with references or personal experience.


                      To learn more, see our tips on writing great answers.




                      draft saved


                      draft discarded














                      StackExchange.ready(
                      function () {
                      StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fdba.stackexchange.com%2fquestions%2f162067%2fsql-management-studio-2016-account-disabled%23new-answer', 'question_page');
                      }
                      );

                      Post as a guest















                      Required, but never shown





















































                      Required, but never shown














                      Required, but never shown












                      Required, but never shown







                      Required, but never shown

































                      Required, but never shown














                      Required, but never shown












                      Required, but never shown







                      Required, but never shown







                      Popular posts from this blog

                      Ronny Ackermann

                      Köttigit

                      MySQL 8.0.15 starts normally but any connection hangs