I'm trying to develop a way to run chkdsk against only the local drives in labtech. Does anyone have thoughts about how to accomplish this?

Views: 530

Reply to This

Replies to This Discussion

Ok, so I figured part of this out.

If you use an IF Drive Status FreeSpace set at 99 it'll flag all drives all the time.

Then you use the IF SQL Data Check with the following select statement:

SELECT internal FROM drives WHERE computerid = '%computerid%' AND CONCAT(letter,':') = '%driveletter%'


That should give you local drives.

The issue i'm finding now is on machines with multiple drives the %driveletter% variable looks something like C: E: F:

This causes the SQL Select statement to freak out.


Again, any help is appreciated.

Reply to Discussion


© 2017   Created by Ben Johnson.   Powered by

Badges  |  Report an Issue  |  Terms of Service