Notification

Icon
Error

Solid State Disk Detector - Script that reads MSFT_PhysicalDisk class MediaType

Posted: Tuesday, May 3, 2016 1:16:44 PM(UTC)
ict-user

ict-user

Member Original PosterPosts: 38
0
Like
1. Deployment checks for the needed powershell script.

2.The deployment tries to remove old ssd.txt file that are writen before.

3.The PowerShell Scripts tries to read the WMI class MediaType
See MSFT_PhysicalDisk class:
https://msdn.microsoft.com/en-us/library/windows/desktop/hh830532(v=vs.85).aspx
The scripts writes a file ssd.txt to the c:\ drive if it finds a mediatype=4 (SSD)

After the deployment the assets are rescanned.
After the rescan you can create a report with the file scanning option in the scanning menu.

Handles attachments
SSDScan.zip (1kb) downloaded 345 time(s).
Script - Detect SSDDownload Package
DescriptionDetects SSD with Mediatype=4

See MSFT_PhysicalDisk class:

https://msdn.microsoft.com/en-us/library/windows/desktop/hh830532(v=vs.85).aspx
Final ActionNothing
Max. Duration30 min(s), 0 hour(s)
RescanYes
Steps
1. Check for script
TypeCondition
SuccessGo To Step 2
FailureStop (Failure)
Conditions
File {PackageShare}\Scripts SSDScan.ps1 Exists
2. Remove SSD.txt
TypeCommand
Return Codes 0,1641,3010
SuccessGo To Step 3
FailureGo To Step 3
Command del c:\ssd.txt
3. Call script
TypeCommand
Return Codes 0,1641,3010
SuccessStop (Success)
FailureStop (Failure)
Command powershell -executionpolicy bypass -File "{PackageShare}\Scripts\SSDScan.ps1"
lmf
#1lmf Member Posts: 7  
posted: 9/29/2016 3:10:45 AM(UTC)
Please note that this (specifically the provider) is not available before Windows 8 or Windows Server 2012. May want to update the OP.

See: https://msdn.microsoft.com/en-us/library/windows/desktop/hh830613(v=vs.85).aspx

Active Discussions

Report Center Show newly discovered software
by  CyberCitizen   Go to last post Go to first unread
Last post: Yesterday at 12:06:21 AM(UTC)
Lansweeper Multiple Devices Owned by Users (asset relations)
by  Charles S.  
Go to last post Go to first unread
Last post: 6/15/2021 9:38:26 PM(UTC)
Lansweeper Show Date Without Time
by  RC62N   Go to last post Go to first unread
Last post: 6/15/2021 9:04:47 PM(UTC)
Lansweeper Windows 10 Version Chart
by  RC62N  
Go to last post Go to first unread
Last post: 6/14/2021 6:16:52 PM(UTC)
Lansweeper LSAgent Report
by  brodiemac-too   Go to last post Go to first unread
Last post: 6/14/2021 5:27:29 PM(UTC)