Wednesday, May 10, 2017

Error authenticating proxy username or password is incorrect

We know that PackageExecuter is associated with a SQL Credential that was a former domain admin account. SQL Server saves that Account and Password and then applies it where appropriate. The domain account password used to create the package is different from the service account password used to run the package in QA. 
This is very common error in SQL Server and mostly occurs whenever you want to run your SQL job by domain user instead of SQL Server Agent.
If you want to run the SQL jobs with domain user account then you should be ensured the following points-
  1. Configure a User to Create and Manage SQL Server Agent Jobs
  2. Reset the SQL Server Agent Services
How to configure a user account in SQL Server?
Before creating or configure domain user account, you should have access rights to a proxy account. All members of the sysadmin fixed server role have permission to create, modify, and delete proxy accounts. You should have fixed database roles in the msdb database: SQLAgentUserRole, SQLAgentReaderRole, or SQLAgentOperatorRole.
If non-administrative users want to run jobs that execute other job step types (for example, SSIS packages), they will need to have access to a proxy account. All members of the sysadmin fixed server role have permission to create, modify, and delete proxy accounts.
To configure a user to create and manage SQL Server Agent jobs, we should follow the following steps in SQL Server Management Studio-
Just go to security folder and check login you wish to add to a SQL Server Agent fixed database role, and select Properties.
In login properties window, go to User Mapping page and select the row containing msdb. After that check the appropriate SQL Server Agent fixed database role under Database role membership for: msdb

Just click OK Button to close login properties window.
How to configure a user Credentials in SQL Server?
After setting the membership, to run the SQL Server Agent jobs for a domain user we have to create the credentials as given below-
In Credential Window, we have to set the credential name and provide the identity of the login user with password as given below-
Click on OK button to close credential window.
How to configure a Proxy in SQL Server?
Now, we have to go SQL Server Agent to create a proxy under SSIS Package Execution as given below-
In Proxy Account window, we have to fill Proxy name and assign credential name which we have created in credential under security folder of SQL Server. After assigning credentials, we have to active all subsystems as given below-
Reset the SQL Server Agent Services
After creating the proxy account, click OK button to close proxy account window. Now, it is time to reset the SQL Server Agent Services. Just go to the window services, right click on SQL Server Agent Services and click on properties as given below-

In SQL Server Agent properties window, just go to Log On tab and set the domain user to run the SQL Server Agent services as given below-
After clicking on Apply button, click on OK button to close SQL Server Agent properties window. Now, we have to restart SQL Server Agent window services for again as given below-

Now we have done everything around this issue and we are able to run our all packages in SQL Server with the domain user account. We should take care that if domain user password will change then we need to change the new password in SQL Server Agent also.

16 comments:

  1. Great post! Thank you for sharing valuable information. Keep up the good work.

    ReplyDelete
  2. According to my point of view, It is a very effective, helpful and informative article about the online course. I enjoyed the comparison you mentioned in the post. Appreciate te your great effort. Keep it up.lisa

    ReplyDelete
  3. Cool stuff you have got and you keep update all of us. 1337x

    ReplyDelete
  4. I am jovial you take pride in what you write. It makes you stand way out from many other writers that can not push high-quality content like you. 1337x

    ReplyDelete
  5. A Proxy is a central machine on the network that allows other machines in that network to use a shared Internet connection. torrentz2

    ReplyDelete
  6. For instance, say you are visiting a site that tracks its guests with treats, introduces spyware on your PC, or more awful is an asylum for programmers.
    piratebay

    ReplyDelete
  7. Why start a home internet business? People start businesses for various reasons. Many times when people think of starting a business, their mind easily focuses on ideas of doing conventional businesses. Not many people have known how profitable online businesses are. Through this, I would like to point out some of the reasons as to why you should start a home internet business. KickassTorrents proxy

    ReplyDelete
  8. i never know the use of adobe shadow until i saw this post. thank you for this! this is very helpful. pandavpnpro

    ReplyDelete
  9. Such a very useful article. Very interesting to read this article.I would like to thank you for the efforts you had made for writing this awesome article. 科学

    ReplyDelete
  10. I like viewing web sites which comprehend the price of delivering the excellent useful resource free of charge. I truly adored reading your posting. Thank you! 翻墙

    ReplyDelete
  11. Your blogs further more each else volume is so entertaining further serviceable It appoints me befall retreat encore. I will instantly grab your rss feed to stay informed of any updates. https://dynamichealthstaff.com/jobs-in-dubai-for-nurses

    ReplyDelete
  12. The post is written in very a good manner and it contains many useful information for me. dark web

    ReplyDelete
  13. I’m going to read this. I’ll be sure to come back. thanks for sharing. and also This article gives the light in which we can observe the reality. this is very nice one and gives indepth information. thanks for this nice article... textbook answers

    ReplyDelete
  14. However selecting the right company to buy a proxy is much as important as your safety does. check

    ReplyDelete
  15. I really loved reading your blog. It was very well authored and easy to understand. Unlike other blogs I have read which are really not that good.Thanks alot! proxies cheap

    ReplyDelete
  16. I was getting exactly the same error, because the way the service account of 'SQL Server Agent' service was specified. For example let's say my domain short name is 'DOMAIN' and the AD service account name is 'ServiceAccount'. Then the account was specified into the 'SQL Server Agent' service configuration like "DOMAIN.local\ServiceAccount". "DOMAIN.local" is an alias of "DOMAIN" and 'SQL Server Agent' service was working perfectly starting and executing jobs, but the Proxy was failing with the "username or password is incorrect" error. Changing 'SQL Server Agent' service account to "DOMAIN\ServiceAccount" fixed everything.

    ReplyDelete