Answer the question
In order to leave comments, you need to log in
How to correctly check for matching strings?
Good afternoon. A very gentle help to match the condition.
Essence in sleduyushchsays: Is the Machine with Acronis, it is necessary to monitor Backup.
The idea is as follows. By running "acrocmd list plans" we get the table.
The question itself: How to correctly use the data to compose the condition
if Name & State & Status & Enabled = DC idle ok true : Action ....
Since I myself used PowerShell at a primitive level, I would like to see a live example
for further completion
Thank you in advance
Answer the question
In order to leave comments, you need to log in
Made a crutch
acrocmd list plans >> C:\Temp\plans.txt
if (Select-String -path C:\Temp\plans.txt -pattern "DC idle error")
{
write-host "nok dc"
}
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question