Schedule Powershell Tasks

Steve Jones show us how to schedule Powershell tasks:

One of the things I needed to do with my SQL Saturday download process was run this automatically. I don’t want to remember to do this, so I decided to set this up on a schedule.

I ran a quick search and it seemed to be a simple process. Essentially I run the Task Scheduler application and then call my script as a parameter to the PowerShell exe.

Windows Task Scheduler isn’t fantastic (and they seem to mess with it in every version), but it does let you run Powershell scripts easily.  Bonus points for those of you using at for scheduling.

Related Posts

Checking If Ports Are Open Using Powershell

Anthony Nocentino has a quick Powershell script to see if ports are open on a machine: Ever want to confirm that a port is accessible from one computer to another? There’s a PowerShell cmdlet for that, Test-NetConnection. With the -Port option, this cmdlet will do a quick TCP three-way handshake on the remote system to confirm that the service is […]

Read More

More dbatools Changes

Chrissy LeMaire has a few more breaking changes for us: It’s been a busy couple days! Here’s a list of our breaking changes Invoke-Sqlcmd2 has been removed and replaced with a warning to use Invoke-DbaQuery The NetworkShare parameter has been renamed to SharedPath UseLastBackups has been renamed to UseLastBackup There are also several new commands […]

Read More

Categories

December 2015
MTWTFSS
« Nov Jan »
 123456
78910111213
14151617181920
21222324252627
28293031