#Powershell
-
May 12, 2017
Another way to check Update Installed via Powershell
I have to check if machine has MS March update installed, and SCCM cannot make my job simpler :( So I created a new compliance rule to check the result, here is the code: $error.clear() try {...
-
Feb 17, 2017
Find A File with Random Characters and Send Email by SCCM Compliance Rule
Here is my Powershell script for Finding a file with random characters in the end, if the system find the file, it will email to our alert mailbox as well. This is done by SCCM Compliance Rule: File...
-
Feb 17, 2017
SCCM Compliance Rule for Finding Process Running
Here is my powershell script for finding if a process is running with SCCM compliance rule. $process = Get Process Process name xxx ErrorAction SilentlyContinue if ($process) { Write Host "Running" }...
-
Nov 18, 2016
Find Current User via Powershell
sometimes if you run as local admin, but your current user is not a local admin, then you need some special way of finding the current username: $user = (gwmi Query "Select \ from Win32\ Process...
-
Oct 24, 2016
Add a SCCM deployment with Powershell
Here is a powershell command for creating a SCCM deployment Start CMApplicationDeployment CollectionName "Collection Name" Name "Softwarename" DeployAction Install DeployPurpose Available...
-
Aug 12, 2016
Remote Control SCCM Package
With SCCM 2012, I love the Remote Control function, so much better than RDP! and it comes with SCCM console. For those don't have SCCM console, I have wrote a Powershell script to just to run Remote...
-
Jun 10, 2016
Package Powershell 5.0 in SCCM
A Surprisingly very easy SCCM Package, the command line is just wusa.exe Win7AndW2K8R2 KB3134760 x64.msu /quiet /norestart You can download Powershell 5.0 from here: <https://www.microsoft.com/en...
-
Jun 3, 2016
Better Way to Find Drivers for SCCM OSD Image
There are lots of ways to find drivers, such as from the manufacturer website(Lenovo, HP, Dell), vendor website(Intel, Nvidia), or from Microsoft Update Catalog. At first I was downloading the SCCM...
-
Jul 5, 2015
Get IP Addresses from a List of Machines
I need to get IP addresses from a list of machines, so I googled it...needs to use test connection command, and here is the full script: Get IP Addresses from a List of Machine Name 07052015 $pcs =...