Jimmy Wang
asked on
set-log Microsoft-Windows-PrintService/Operational /e:true
i'm trying to enable this "set-log Microsoft-Windows-PrintSer vice/Opera tional /e:true" logging for each server and looking for how can I run for multiple server.
is it possible to do something like this to import. I know my line is not correct but looking for help here what I should correct to run multiple remote computer to enable this logging ?
-------------------------- ---------- ---------- ---------- ---------- ----
$servers = Import-csv "c:\Servers.txt"
foreeach($server in $servers){
$cn=$server.Computername
wevtutil set-log Microsoft-Windows-PrintSer vice/Opera tional /e:true /r:"$cn"
}
-------------------------- ---------- ---------- ---------- ---------- ----
is it possible to do something like this to import. I know my line is not correct but looking for help here what I should correct to run multiple remote computer to enable this logging ?
--------------------------
$servers = Import-csv "c:\Servers.txt"
foreeach($server in $servers){
$cn=$server.Computername
wevtutil set-log Microsoft-Windows-PrintSer
}
--------------------------
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
I have recommended this question be closed as follows:
Split:
-- Jimmy Wang (https:#a42345284)
-- Jose [MCSE] Ortega C (https:#a42339746)
If you feel this question should be closed differently, post an objection and the moderators will review all objections and close it as they feel fit. If no one objects, this question will be closed automatically the way described above.
Pber
Experts-Exchange Cleanup Volunteer