none
SA Password

    Question

  • I have sql server 2012.  The SA account with password was not documented.  I can get on the server with windows authentication using my admin account.  I do not have sysadmin role so I am limited. I was task with  auditing this server to get the logins. It was pointed out to me that I did not get all the logins because of my role (a user that saw my report stated this) I tried to put sql in single mode to change the sa password or give my admin account the sysadmin role. Errors out when I try to put in single mode at command line. Tried to use sql configuration manager, states I do not have permissions. How can I get the SA password or change my role? Are there any 3rd party tools I can use to get the password? I have several servers that were not documented. Thank you.

    Friday, February 17, 2017 1:43 PM

All replies

  • Did you say your windows account is member of Local administrators on the SQL Server box?

    If not, you might have the system administrator of the Windows server make your windows account member of Local Administrators group in the hopes that account has been left as member of Sysadmin fixed server role in the SQL instance. Then, you should be able to see all logins and reset password for sa account.

    However, if that doesn't work, you may be stuck until you can somehow find the password for sa account.

    HTH,


    Phil Streiff, MCDBA, MCITP, MCSA

    Friday, February 17, 2017 1:53 PM
  • My account is a member of the local administrators group.
    Friday, February 17, 2017 6:26 PM
  • Hi bfeltus,

    >>My account is a member of the local administrators group.

    Since you are a member of local administrator, you should be able to add yourself into sysadmin server role via DAC and fix/reset sa password later. That way you don’t need to set SQL Server instance in single user mode:
    ----open cmd windows on the server 
    Sqlcmd -A 
    EXEC sp_addsrvrolemember 'Domain\YourAccount', 'sysadmin';  
    GO  

     If you have any other questions, please let me know.

    Regards,
    Lin

    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.


    Monday, February 20, 2017 7:51 AM
    Moderator
  • Please have a look on here it might be helpful for you: https://technet.microsoft.com/en-us/library/jj853293.aspx?f=255&MSPPError=-2147217396
    Monday, February 20, 2017 9:19 AM
  • I have sql server 2012.  The SA account with password was not documented.  I can get on the server with windows authentication using my admin account.  I do not have sysadmin role so I am limited. I was task with  auditing this server to get the logins. It was pointed out to me that I did not get all the logins because of my role (a user that saw my report stated this) I tried to put sql in single mode to change the sa password or give my admin account the sysadmin role. Errors out when I try to put in single mode at command line. Tried to use sql configuration manager, states I do not have permissions. How can I get the SA password or change my role? Are there any 3rd party tools I can use to get the password? I have several servers that were not documented. Thank you.

    Please note, there is no way you can get/reset sa password until you are entitle to do so. This can be done only in two condition as per your current details.

    a. A Local admin on Server connect to SQL Server via windows authentication and reset sa password or add your Windows login ID as sysadmin on SQL server.

    b. You recover sa password from someone who remember it.

    Thanks,


    Kindly mark the reply as answer if they help

    Monday, February 20, 2017 9:29 AM