How to Export Timer jobs in specific time range ?

Run following command by specifying the start time and end time as per the need 🙂

All Timer Jobs :

Get-SPTimerJob | % { $_.HistoryEntries } | Where-Object {($_.StartTime –gt “MM/DD/YYYY hh:mm:ss”) -and ($_.EndTime -lt “MM/DD/YYYY hh:mm:ss”) } | Export-Csv “C:\TimerJobs.csv” –NoType

Failed Timer Jobs:

Get-SPTimerJob | % { $_.HistoryEntries } | Where-Object {($_.StartTime -gt “MM/DD/YYYY hh:mm:ss”) -and ($_.To -lt “MM/DD/YYYY hh:mm:ss”) -and ($_.Status -ne ‘Succeeded’)} | Export-Csv “C:\FailedTimerJobs.csv” –NoType

 

Happy SharePoint Running 🙂

Dipti Chhatrapati

Dipti Chhatrapati is a SharePoint specialist currently working as a Senior Consultant for CapGemini in Mumbai, India. She has more than 9 years of experience in application development, design, maintenance, administration and is continuously working with improving her skills and keeping them up to date. As a developer, project leader and SharePoint Business Analyst, she has been an extensive user of Visual Studio and Team Foundation Server throughout her career. Dipti is very passionate about music, sports, and arts and loves to spend her free time learning new things, socializing with friends and family, cooking, exercising and singing.

Leave a Reply

Be the First to Comment!

Notify of
avatar
wpDiscuz
Animated Social Media Icons by Acurax Responsive Web Designing Company
Visit Us On TwitterVisit Us On FacebookVisit Us On Linkedin