Microsoft has introduced the ability to create your own packaged Win32 applications to deploy in Intune. What this makes possible, is to package your MST based MSI installations – or even scripted deployments as a single package.
I was configuring Software Metering at a costumer when reports seemed wrong. The costumer had already configured metering on Visio,exe which had been running for years, but only 60 installations was reporting usage in the past 120 days out of 540 total installations. I checked maintenance task on the site server and client settings to ensure that the server and clients was configured correct.
I looked into some of the log files on the clients and found this error:
StartPrepDriver – OpenService Failed with error 80070424
After a SCCM client agent implementation, it could be useful to see if there is any user, without any Primary User device.
This information could indicate if there is any computers in your domain, where the installation has been unsuccessful.
Automation is the keyword to get rid of repetitive tasks – then you can focus on the real work right?
So here we go again, this time to create a User Collection with the SMS_Collection WMI class.
I only used this function to create user collections, but can easily be modified to create device collections. Link to the WMI class in the bottom.
Also this function uses the log function which you can find here: here
Being a IT professional leads to many functions :). Here is one for creating a container node aka. SCCM folder.
The function uses the write-log function which you can find here
When it comes to powershell logging in simple scripts i always use this. Each time you use the function it writes the time and append the text to a .log file.
The two variables $LogFolder and $LogFile can be changed as desired.
to create an SCCM application deployment with powershell you have to be patient, because the error output from the server is always “generic failiure”..
and there is not much help to get from Microsofts SMS_CIAssignmentBaseClass specification.
This code i made to be able to make a cleanup task for PC’s no longer in use. This script remove computers from domain when running WinPE.
This was one of the steps that was done. Another step deleted objects in McAfee EPO and SCCM.
To be able to delete a PC within a domain from a non-domain PC you need to install ADSI on the WinPE image.
When you need to change the UEFI settings like SecureBoot – or other settings – with PowerShell, this script here can be handy. You define the settings for your needs in the $ DesiredSettings variable
I was in a situation where i wanted to know which SCCM device collections a specific users devices where a member of. Therefore I created script which was executed as a scheduled task on a server. Here is an example on how to do that.
First create the scheduled task and run it with highest privileges and as another user if wanted. Could be an SCCM service account that only have access to certain WMI classes.