Skip to content

Powershell in a Month Day 15 – Jobs

February 3, 2014

This is part of my Powershell Challenge, to learn more about PowerShell (PoSh) using the Learn Windows Powershell 3 in a Month of Lunches book by Don Jones.

Jobs are important, mostly because running stuff interactively, and manually, is a pain. The real power of PoSh administration, in my mind, is that not only can I run things across lots of servers, but I can also have some jobs run automatically. The Windows Scheduler isn’t always a part of this, though I’m not sure the PoSh system is better after reading this chapter.

It’s a short one, but one that I did like. I’ve always liked scheduling jobs and having them do work for me. I can see this being handy, but the processing of results is something that will be important. That means saving this stuff off and practicing formatting.

It’s an interesting approach here. The chapter has you create some jobs and then it explains how they work. Getting results, stopping jobs, checking them, etc. all occur as you have jobs running. All good admin things. I have the feeling I’ll refer back here as I build jobs.

The scheduling comes after there’s an explanation of jobs themselves. We learn briefly how to schedule, but not in detail. To be fair, there isn’t a lot to worry about here.

The lab was fairly easy. Most of the items were things I know how to do from the past, or I learned here. The recursing into subdirectories was a little tricky since I’ve used “/s” forever, but I needed to understand in PoSH that -recurse and -filter were needed here.

I’ll be looking to play with some scheduled jobs that might clear out old files on my machine, especially backups. This would be some good practice for a job. I certainly should create a job to trim out IIS log files since that’s something I’ve seen needed on every web server I’ve encountered.

About these ads

From → Blog

Leave a Comment

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.

Join 4,290 other followers

%d bloggers like this: