PowerShell script to backup unsealed SCOM MPs

Not sure if anyone has written this before. I have written this simple script to backup all unsealed management packs. I have scheduled it to run daily on RMS via Windows Task Scheduler. How does it work: Backup unsealed MPs to a local folder. Delete older backups from local folder robocopy backup from local folder to a remote location using purge option (Anything that not exist from source will be deleted from destination. Therefore old backups are deleted from remote folder as well.) Preparing the script: Modify line 21-23 to suit your environment $backuproot – local folder where MPs are

“Orphaned” Maintenance Windows for SCCM clients

Last week, in my SCCM test environment, I noticed there are several maintenance windows applied to clients that I had no idea where were they come from. Symptoms: When using SCCM Client Center, it shows this particular client (MGMT01) has 3 maintenance windows (service window) assigned to it: PolicySpy from ConfigMgr 2007 Toolkit also shows the same: The problem is, there should ONLY be 1 maintenance window for this client: and actually, there is ONLY 1 maintenance window in total in my entire environment: I ran “SELECT * from v_ServiceWindow” against the site database and there is only 1 row

Powershell Function: Get-AllDomains (in a forest)

I wrote this Powershell function today as part of a script I’m working on. It is to get a list of Active Directory domains within an Active Directory forest using ADSI: I don’t have any child domains in my test environment, but if you run this on a domain member computer, it will list all child domains as well as the parent forest domain (I’ve tested in the production environment).

SCCM Package stuck at “Install Pending” state

Last week, someone power cycled one of our secondary site server (also a DP) via the remote management card without shutting down the OS first. At that time, a software update deployment package (total size of 13MB) was being pushed to this site. As result, this particular update package got stuck at “Install Pending” even few days after the reboot. I noticed below error was logged in distmgr.log every few minutes: Cannot update the package server <site server NAL path> for package <package ID>, error = 8 No other errors were found in despool.log or sender.log. I have tried refreshing

%d bloggers like this: