Task Scheduler GUI versus Powershell - PS does less
in general, not happy seems task scheduler in windows 2012 less fine tune-able previous versions. @ least in 1 case described here.
i have task on 2008 runs hourly starting @ 5 duration of 16 hours. set run m-f (5 days week).
moving task 2012 find can pick 1, 12 or 24 hours duration. ok, thin, can use powershell--i assume might have more control there in fact have less.
you think translate (12 hours not 16 of course) command below. can see, fails. if missing let me know. short-=term, have created 1 task lasting 12 hour , 4 more of 1 hour. pretty lame imho said, maybe off base in thinking ps should @ least as gui. ideally, want able pick values duration , interval btw.
#$interval = 1 hour $duration=12 hours $days=m-f
#this fails cannot mix -weekly repetition properties - can in gui
new-jobtrigger -at $start -repetitioninterval $interval -repetitionduration $duration -weekly -daysofweek $days
not sure powershell side of things, task scheduler in 2012 allow more fine grained.
in edit trigger window drop down options give selection of defaults can edit them. timing you're after, set duration 1 hour, edit text become "16 hour", eg add 6 after 1. once it's saved if re-open duration correctly display "16 hours".
Windows Server > Windows PowerShell
Comments
Post a Comment