Вывод информации о настройках клиентских объектов

param(
      $computer = "localhost", 
      [switch]$help
     )

function funHelp()
{
$helpText=@"
DESCRIPTION:
NAME: ReportClientSettings.ps1
Displays client configuration settings on a local or a remote 
terminal server

PARAMETERS: 
-computer the computer to target the script to
-help     prints help file

SYNTAX:
ReportClientSettings.ps1 
Displays client configuration settings on local machine

ReportClientSettings.ps1 -computer ts1

Reports client configuration settings on remote terminal server
named ts1

ReportClientSettings.ps1 -help

Prints the help topic for the script

"@
 $helpText
 exit
}

if($help)       { "Printing help now ..." ; funHelp }

$namespace = "root\cimv2\TerminalServices"
$class = "win32_TSClientSetting"

get-wmiobject -namespace $namespace -computername $computer `
          -class $class  |
  format-list [a-z]*

Также интересно:

0
Голосов пока нет

Оставить комментарий