Creating a Task Scheduler for one of my batch file to run on a Windows Machine. This happened which is related to specified logon session.
An error has occurred for task <TASKNAME>. Error message: The following error was reported: A specified logon session does not exist. It may already have been terminated.
– Windows Task Scheduler Error
Task Scheduler Error Or is It?
For some Windows machine, this error did not occur and only occurred on a specific machine. Digging through help files and some information on the Internet has brought me some search results on the same issue but most were not helpful.
What Specified Logon Session Does not Exist?
Seeing that I logon with my network ID, I decided to try to create a local Administrator ID to run the application on the task scheduler. The verdict is that it still popped up the same error. Do note that this issue will only happen if one decided to run the application whether user is logged on or not. If the application is set run only when user is logged on, this would not have any issue though.
So the issue is not the ID Then What Else?
Windows Administrator would know this answer but none is telling me. So the next thing would be to look at the security policy and sure enough, the problem lies in here.
To access the Security Policy do type SECPOL.MSC on the Search or your Run menu.
Then followed by Local Policies > Security Options
Network access: Do not allow storage of passwords and credentials for network authentication.
Solution
You will see the Security Setting is Enabled. Change it to Disabled and Voila, this should now work. There is no need to restart the server for this to take into effect. Though that is dependent on your Company’s security policy. If you do not have administrator rights, you may request for the server administrator to perform this change and it should work.


