xpsql.c: Error 1314 from LogonUser on line 476
xpsql.c: Error 1314 from CreateProcessAsUser on line 492
Make sure that the account that the MSSQLServer service is running on, as well as SQLServerAgent, have the following user rights permissions:
- Act as part of the operating system.
- Increase quotas.
- replace process level token.
- Log on as a batch job.
NOTE: You must restart the entire server, not just the SQL Services, in order for any changes made to user rights permissions to take effect.
Error 1314 is ERROR_PRIVILEGE_NOT_HELD. This indicates that the account invoking these functions does not have sufficient user rights to complete the login. This leads many customers to reset the account privileges on the SQLAgentCmdExec account or recreate it through User Manager, or SQL Enterprise Manager.
However, what is raising these errors is the process which is invoking the API calls (Sqlservr.exe). Therefore, it is the account that the MSSQLServer service is running on that holds the incorrect and insufficient privileges. In order to successfully execute LogonUser(), the MSSQLServer account needs to have the SE_TCB_NAME (Act as part of the operating system) right enabled. In order to successfully execute CreateProcessAsUser(), the MSSQLServer account needs to have the SE_INCREASE_QUOTA_NAME (Increase quotas) rights enabled.
NOTE: For certain types of processes, CreateProcessAsUser() may also require SE_ASSIGNPRIMARYTOKEN_NAME (Replace a process level token) to be turned on.
Article ID: 248391 - Last Review: Jun 16, 2008 - Revision: 1