Questions tagged [scheduled-task]

A scheduled-task means the launch of a program or script at predefined times or after specified time intervals.

662 questions
4
votes
3 answers

SCHTASKS can't administer remote tasks

I am trying to stop and then disable a remote task from a build script. The remote server is Server 2k8. The client running the script is Windows 7. Both machines are joined to the domain. When I run schtasks /Change /S remoteServer /TN "theTask", I…
Ryan Michela
  • 1,147
  • 4
  • 16
  • 23
4
votes
2 answers

Which SCHTASKS parameter(s) control the Setting "Stop the task if it runs for hours"?

I have a problem with writing a script to automate the creation of Scheduled Tasks in Windows. After much Googling, I am unable to deduce which parameters to the command-line utility SCHTASKS.EXE control the setting "Stop the task if it runs for …
mseery
  • 141
  • 1
  • 3
4
votes
1 answer

run schedule task before windows service starts

I want to run a schedule task before a specified windows service (Service A). Service A starts automatically. What is the best approach to take? Do I need to convert the schedule task into a service (Service B) and configure Service A to depend on…
4
votes
2 answers

Scheduled Task has finished but still shows status as running

I have a scheduled task on a Windows Server 2000 box which is scheduled to run daily. On Monday, the task ran perfectly in that the thing it fires off (a console application) completed, but the scheduled task itself is still marked as "Running" on…
Unsliced
  • 141
  • 1
  • 4
4
votes
1 answer

"No mapping between account names and security IDs was done" when importing Scheduled Tasks In Windows 2008?

OK, I have a Windows 2008 Server scheduled task that runs on system startup. This works fine. But I want to move this task to another box (actually, I'm using Amazon and need this to work on other instances launched from this image but that's…
Ernest Mueller
  • 1,199
  • 2
  • 12
  • 25
4
votes
3 answers

How can I run a job when the server load is low?

I have a command that runs a disk snapshot (on EC2, freezing an XFS disk and running an EBS snapshot command), which is set to run on a regular schedule as a cron job. Ideally I would like to be able to have the command delayed for a period of time…
jberryman
  • 914
  • 2
  • 10
  • 25
4
votes
2 answers

How to schedule a task for multiple days of a month using schtasks.exe?

Since task scheduler API has been changed after Vista & Server 2008, scheduling a task with schtasks is (as much as I know) the only way that works on both Windows 2003 Server and Windows 2008 Server. I need to create a task that will run every on…
4
votes
1 answer

Windows 10 run an interactive scheduled task to run for any interactive user

I want to setup a windows 10 task scheduler to run a GUI based tasked interactively for any logged on user. Right now we have to explicitly specify the user name, so the task can only be run for this specific user. This scheduled task will be…
user562888
  • 43
  • 1
  • 1
  • 3
3
votes
1 answer

Task Schedule not executing at "Startup" when created through GPO Preferences

I've noticed if I create the Task for all my PC's on my DC through GPO Preferences with the "At startup" trigger (no matter what I execute, it can be VBS, EXE, PowerShell ...), Task will never execute. So, this would be prerequisites: Task should…
toofat
  • 311
  • 3
  • 11
3
votes
3 answers

Almost All Scheduled Tasks Fail: The system cannot find the file specified. (0x80070002)

In Windows 7 x64 I am attempting to create a scheduled task that runs a PowerShell script, but no matter what I try, it fails with the error: "The system cannot find the file specified." And then I noticed that many other scheduled tasks (Google…
Shoeless
  • 275
  • 2
  • 12
3
votes
1 answer

Data Collector Set was not found (0x80300002) on Scheduled Task

Server: Microsoft Windows 2012 R2 (w/ SharePoint 2013 on the system). Getting the this error: Data Collector Set was not found (0x80300002) I have a scheduled task that runs automatically on system restart. I am not sure if this is built-in,…
3
votes
0 answers

Defining multiple triggers for my Task Scheduler will only work on the first trigger

I have "Windows server 2008 R2 standard" with SP1. and inside my windows Task Scheduler, i define the following 2 triggers:- now as the picture is mentioning, i want to run the task on different times (3:00 am & 4:30 am) based on the Day. but…
3
votes
1 answer

Execute a Windows task triggered by registry changes

I'm looking for a possibility to execute a script in case a particular registry key is going to be created or modified. In the Windows Taks Scheduler there is a way to execute scripts triggered by system/application events. But I could not find one…
3
votes
0 answers

How to fix "ERROR: User credentials are not allowed on the local machine." when creating a scheduled task with Administrator credentials?

Using a non-Administrator (or Administrator) cmd.exe, I enter the following command to create a scheduled task with Administrator credentials admin and P@ssw0rd: schtasks /CREATE /S %computername% /U admin /P P@ssw0rd /RU SYSTEM /SC ONLOGON /TN…
Shuzheng
  • 419
  • 1
  • 8
  • 15
3
votes
0 answers

Windows Task Scheduler job not starting but runs on manual start

Windows Server Version : 2016 Problem Description : This is indeed a weird problem I am facing. I have a .bat file that I have scheduled to run every 15 min but it does not start on its own at the scheduled time if I disable and re-enable it. But…