This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

List filtered for REAL computers only

Hello,

I know ServicePrincipalName is a property of object class Computer

but i need to get all names in Active Directory which are real servers/desktops

Get-QADComputer -IncludeAllProperties | export-csv "mycomputer.txt"

but the shares, the cluster names, etc... are listed ... I don't want them on the list...

in another meaning how to differentiate:

- Server Names (Desktop Names)

- Share Names

- Cluster Names

- SQL Instance Names

Any idea?
Thanks,
Dom

Parents
  • Good Morning,

    I tried this but I got an error:
    [PS] H:\>Get-QADComputer -includeallproperties | where {$_.operatingsystem -like "windows*"} | export-csv "mycomputers.t
    xt" -notypeinformation
    Get-QADComputer : An operation error occurred.
    At line:1 char:16
    + Get-QADComputer <<<< -includeallproperties | where {$_.operatingsystem -like "windows*"} | export-csv "mycomputers.t
    xt" -notypeinformation
    + CategoryInfo : NotSpecified: (:) [Get-QADComputer], DirectoryAccessException
    + FullyQualifiedErrorId : Quest.ActiveRoles.ArsPowerShellSnapIn.DirectoryAccess.DirectoryAccessException,Quest.ActiveRoles.ArsPowerShellSnapIn.Powershell.Cmdlets.GetComputerCmdlet

    Any idea?
    Thanks,
    Dom
Reply
  • Good Morning,

    I tried this but I got an error:
    [PS] H:\>Get-QADComputer -includeallproperties | where {$_.operatingsystem -like "windows*"} | export-csv "mycomputers.t
    xt" -notypeinformation
    Get-QADComputer : An operation error occurred.
    At line:1 char:16
    + Get-QADComputer <<<< -includeallproperties | where {$_.operatingsystem -like "windows*"} | export-csv "mycomputers.t
    xt" -notypeinformation
    + CategoryInfo : NotSpecified: (:) [Get-QADComputer], DirectoryAccessException
    + FullyQualifiedErrorId : Quest.ActiveRoles.ArsPowerShellSnapIn.DirectoryAccess.DirectoryAccessException,Quest.ActiveRoles.ArsPowerShellSnapIn.Powershell.Cmdlets.GetComputerCmdlet

    Any idea?
    Thanks,
    Dom
Children
No Data