SCCM SQL script to find users associated with computers

SELECT  GS.Name0,
GS.UserName0,
WS.LastHWScan,
GS.Domain0,
OS.Caption0,
SYS.SystemRole0
FROM
v_GS_COMPUTER_SYSTEM GS,
v_GS_OPERATING_SYSTEM OS,
v_GS_SYSTEM SYS,
v_GS_WORKSTATION_STATUS WS
WHERE
GS.ResourceID = SYS.ResourceID
AND WS.ResourceID = GS.ResourceID
AND OS.ResourceID = GS.ResourceID
AND SYS.SystemRole0<>’Server’
AND Datediff(dd,WS.LastHWScan,getdate()) > -1 and
GS.username0 in (‘DOMAIN\user1′,’DOMAIN\user2′,’DOMAIN\user3’)

http://eskonr.com/2012/08/sccm-configmgr-report-find-computers-for-the-list-of-selected-users/

Advertisements

How to deploy a Windows Image on UEFI-based Computers

Various errors including:

Unable to find a raw disk that could be partitioned as a system disk
failed to validate for boot image staging
stagebootimagefailed 8007000f

The efi partition on a efi system must be fat32

Failed to prepare the system partition for staging
the request is not supported
80070032

Trick is you must disable Secureboot and create UEFI partitions yourself. Just turn Secureboot off in properties and when ConfigMgr boot media is started press F8 and create partitions yourself.
•Diskpart
•Select disk 0 (0 being the disk to setup)
•Clean (wipe the disk)
•Convert gpt (convert disk to GPT)
•Create partition efi size=200 (EFI system partition)
•Assign letter=s (Any allowable letter)
•Format quick fs=FAT32 (Format the ESP)
•Create partition msr size=128 (Create the MSR partition)
•Create partition primary (Create Windows partition)
•Assign letter=c
•Format quick fs=NTFS (Format primary partition)
•Exit

http://henkhoogendoorn.blogspot.co.uk/2014/11/how-to-deploy-windows-image-on-uefi.html

 

MBAM 2.5 SP1 does include Win 10 computers in “MBAM Supported Computers Group”

For some reason Win 10 computers would not appear in the “MBAM Supported Computers Group” so I have created an additional membership rule for WQL using the format below.  This is SCCM 2016 Mbam 2.5 SP1 with latest KB patch.

select SMS_R_System.ResourceId, SMS_R_System.ResourceType, SMS_R_System.Name, SMS_R_System.SMSUniqueIdentifier, SMS_R_System.ResourceDomainORWorkgroup, SMS_R_System.Client from SMS_R_System inner join SMS_G_System_OPERATING_SYSTEM on SMS_G_System_OPERATING_SYSTEM.ResourceID = SMS_R_System.ResourceId inner join SMS_G_System_COMPUTER_SYSTEM on SMS_G_System_COMPUTER_SYSTEM.ResourceID = SMS_R_System.ResourceId inner join SMS_G_System_TPM on SMS_G_System_TPM.ResourceId = SMS_R_System.ResourceId where SMS_G_System_OPERATING_SYSTEM.Version like “10.%” and SMS_G_System_TPM.SpecVersion > “1.2” and SMS_G_System_COMPUTER_SYSTEM.DomainRole = 1