Windows 10: Scheduled tasks

Discus and support Scheduled tasks in Windows 10 BSOD Crashes and Debugging to solve the problem; I have a .bat file to back up files to a mapped network drive, using robocopy seen below. Works perfectly. It also works using this network address:... Discussion in 'Windows 10 BSOD Crashes and Debugging' started by DennisWage, Nov 29, 2019.

  1. Scheduled tasks


    I have a .bat file to back up files to a mapped network drive, using robocopy seen below. Works perfectly. It also works using this network address: \\PC-BACKUP\PC-Backup instead of mapped drive.


    echo off

    setlocal

    echo %DATE%_%TIME%

    robocopy F:\ Y:\ /NDL /MIR /XD /NP "$RECYCLE.BIN" "System Volume Information" "RECYCLER" /R:0 /W:0 /FFT /A-:SH

    rem rundll32.exe powrprof.dll,SetSuspendState 0,1,0

    endlocal

    <<<The following scheduled task is made with the hope that it will run in sleep mode early AM while I am asleep, and I have tested it completely an thoroughly both with computer awake and in sleep mode.>>>


    I set up a scheduled task to run this .bat file. It always works when run manually. It works sometimes when scheduled, and that's what has me baffled. I have found that it works mostly all the time when scheduled anytime during the day, 7am to midnight. But if I schedule it for early morning 1-6am it fails with the dreaded, "The operator has refused the request" error.


    I have another scheduled task that does this same thing but backs up to a local drive. It ALWAYS works. So this leads me to think it is something on the network drive end.

    The only thing I can come up with is that my windows 10 PC is in some deeper sleep mode at 4am or the linux machine I am backing up to is doing maintenance or in some kind of hyper sleep mode.


    Any help will be appreciated.


    <?xml version="1.0" encoding="UTF-16"?>

    <Task version="1.4" xmlns="http://schemas.microsoft.com/windows/2004/02/mit/task">

    <RegistrationInfo>

    <Date>2019-10-25T10:43:48.9800929</Date>

    <Author>DENNIS-LAPTOP\dwage</Author>

    <URI>\Backup Weekly</URI>

    </RegistrationInfo>

    <Triggers>

    <CalendarTrigger>

    <StartBoundary>2019-11-13T23:59:00</StartBoundary>

    <Enabled>true</Enabled>

    <ScheduleByWeek>

    <DaysOfWeek>

    <Wednesday />

    </DaysOfWeek>

    <WeeksInterval>1</WeeksInterval>

    </ScheduleByWeek>

    </CalendarTrigger>

    </Triggers>

    <Principals>

    <Principal id="Author">

    <UserId>S-1-5-21-770257158-204139670-28269216-1001</UserId>

    <LogonType>Password</LogonType>

    <RunLevel>HighestAvailable</RunLevel>

    </Principal>

    </Principals>

    <Settings>

    <MultipleInstancesPolicy>IgnoreNew</MultipleInstancesPolicy>

    <DisallowStartIfOnBatteries>false</DisallowStartIfOnBatteries>

    <StopIfGoingOnBatteries>true</StopIfGoingOnBatteries>

    <AllowHardTerminate>true</AllowHardTerminate>

    <StartWhenAvailable>false</StartWhenAvailable>

    <RunOnlyIfNetworkAvailable>false</RunOnlyIfNetworkAvailable>

    <IdleSettings>

    <StopOnIdleEnd>true</StopOnIdleEnd>

    <RestartOnIdle>false</RestartOnIdle>

    </IdleSettings>

    <AllowStartOnDemand>true</AllowStartOnDemand>

    <Enabled>true</Enabled>

    <Hidden>false</Hidden>

    <RunOnlyIfIdle>false</RunOnlyIfIdle>

    <DisallowStartOnRemoteAppSession>false</DisallowStartOnRemoteAppSession>

    <UseUnifiedSchedulingEngine>true</UseUnifiedSchedulingEngine>

    <WakeToRun>true</WakeToRun>

    <ExecutionTimeLimit>PT72H</ExecutionTimeLimit>

    <Priority>7</Priority>

    </Settings>

    <Actions Context="Author">

    <Exec>

    <Command>C:\Users\dwage\Desktop\Backup-Weekly.bat</Command>

    <Arguments>&gt; C:\Users\dwage\Desktop\Log-Weekly.txt</Arguments>

    </Exec>

    </Actions>

    </Task>

    :)
     
    DennisWage, Nov 29, 2019
    #1

  2. Task Scheduler with error message The selected task »CreateChoiceProcessTask« no longer exists

    Hi,

    Thank you for posting your query on Microsoft Community. Let me assist you.

    I suggest you to clear the task from Task Scheduler using the below steps and check if the issue still persists.

    Steps:-

    • Type Task Scheduler on Search bar.
    • Click on Task Scheduler Library.
    • Select the particular task and right click on it.
    • Select End.

    Hope this information is helpful. Please do let us know if you need further assistance, we’ll be glad to assist you.
     
    Pawan Dhondiyal, Nov 29, 2019
    #2
  3. Window's Task Scheduler Not Running

    Hi,

    To assist you better, kindly provide us more details by answering the following questions:

    • Have you tried recreating the task? If so, are you getting the same issue?
    • Have you tried creating a new task?
    Meanwhile, we suggest that you ensure that the Task Scheduler is running. You can verify if the service is running by following these steps:

    • Press Windows key + R on your keyboard.
    • Type services.msc and hit Enter.
    • Under Services (Local), make sure that the Task Scheduler service's status is
      Started or Enabled.
    Should you need further assistance, feel free to get back to us.
     
    Monica Cam, Nov 29, 2019
    #3
  4. Scheduled tasks

    Cannot schedule a task with Task Scheduler - error 2147942403

    Hi,

    I suggest you to check the below settings and check fi it helps.

    • In task scheduler, click on the scheduled job properties > then settings.
    • In the last listed option: "If the task is already running, the following rule applies:"
    • Select "Stop the existing instance" from the drop down list.
    • Save and Exit. Then check whether the task is running or not.

    Please get back to us with an update on this issue, we will be happy to assist you further.

    Thank you.
     
    Karthicka_R, Nov 29, 2019
    #4
Thema:

Scheduled tasks

Loading...
  1. Scheduled tasks - Similar Threads - Scheduled tasks

  2. Task Scheduler stops responding when deleting a task and tasks not run!

    in Windows 10 Gaming
    Task Scheduler stops responding when deleting a task and tasks not run!: There is a task I created on Task Scheduler Task Library/ Microsoft and I tried deleting it but for some reason I cannot delete it as Task Scheduler just stops responding. I know there is a way to delete the task from command prompt, but this one I do not know how as it is...
  3. Task Scheduler stops responding when deleting a task and tasks not run!

    in Windows 10 Software and Apps
    Task Scheduler stops responding when deleting a task and tasks not run!: There is a task I created on Task Scheduler Task Library/ Microsoft and I tried deleting it but for some reason I cannot delete it as Task Scheduler just stops responding. I know there is a way to delete the task from command prompt, but this one I do not know how as it is...
  4. Task Scheduler stops responding when deleting a task and tasks not run!

    in Windows 10 BSOD Crashes and Debugging
    Task Scheduler stops responding when deleting a task and tasks not run!: There is a task I created on Task Scheduler Task Library/ Microsoft and I tried deleting it but for some reason I cannot delete it as Task Scheduler just stops responding. I know there is a way to delete the task from command prompt, but this one I do not know how as it is...
  5. Task Scheduler and environment variables

    in Windows 10 Gaming
    Task Scheduler and environment variables: I am using Windows 11 Pro and trying to create/change a task in Task Scheduler to use environment variables in both "Program/script" and "Add arguments". When I do that, I get error "2147942487" no matter what things I try. Google tells me that the issue is about permissions,...
  6. Task Scheduler and environment variables

    in Windows 10 Software and Apps
    Task Scheduler and environment variables: I am using Windows 11 Pro and trying to create/change a task in Task Scheduler to use environment variables in both "Program/script" and "Add arguments". When I do that, I get error "2147942487" no matter what things I try. Google tells me that the issue is about permissions,...
  7. Task Scheduler Is Missing Windows Defender Piece

    in Windows 10 Gaming
    Task Scheduler Is Missing Windows Defender Piece: My Asus VivoBook is having problems. When nothing is running, the device's fan continues to run. I have tried to do some research and have found that my device is missing one of the tasks in task scheduler, the scheduled scan. I have done: SFC /SCANNOW, DISM ScanHealth,...
  8. Task Scheduler Is Missing Windows Defender Piece

    in Windows 10 Software and Apps
    Task Scheduler Is Missing Windows Defender Piece: My Asus VivoBook is having problems. When nothing is running, the device's fan continues to run. I have tried to do some research and have found that my device is missing one of the tasks in task scheduler, the scheduled scan. I have done: SFC /SCANNOW, DISM ScanHealth,...
  9. Subject: Some task schedule not run as scheduled, but the status was "Ready"

    in Windows 10 Gaming
    Subject: Some task schedule not run as scheduled, but the status was "Ready": We have several task schedules. After deploying patch kb5034768, we found that one of the task schedule did not run as scheduled. The status was "Ready" and next run time was already passed. For example; Next Run time is 10:30pm 28 Feb 2024, we checked on 11:00am 29 Feb 2024,...
  10. Subject: Some task schedule not run as scheduled, but the status was "Ready"

    in Windows 10 Customization
    Subject: Some task schedule not run as scheduled, but the status was "Ready": We have several task schedules. After deploying patch kb5034768, we found that one of the task schedule did not run as scheduled. The status was "Ready" and next run time was already passed. For example; Next Run time is 10:30pm 28 Feb 2024, we checked on 11:00am 29 Feb 2024,...