locked
Powershell script to extract servers from an AD group RRS feed

  • Question

  • Hello Geeks,

    I need to write a PowerShell script which will determine all the servers which are part of an AD group. That group only has servers in it.

    I tried using Get-ADcomputer but I am not sure what and all filter shall I apply. Any suggestion would be really helpful.

    Regards,

    HR




    • Edited by Hush_IT Tuesday, September 10, 2019 10:20 AM
    Thursday, May 9, 2019 3:32 PM

Answers

  • Get-ADGroupMember

    Please read the help completely including the examples to learn how to use it.

    Regardless of that - could you please choose a little more meaningfull subject next time you ask a question in a technical forum. 95 % of the questions in this forum are about "Powershell script". ;-)


    Live long and prosper!

    (79,108,97,102|%{[char]$_})-join''

    • Edited by BOfH-666 Thursday, May 9, 2019 3:42 PM
    • Proposed as answer by Richard MuellerMVP Thursday, May 9, 2019 4:03 PM
    • Marked as answer by Hush_IT Friday, May 10, 2019 9:55 AM
    Thursday, May 9, 2019 3:39 PM

All replies

  • Get-ADGroupMember

    Please read the help completely including the examples to learn how to use it.

    Regardless of that - could you please choose a little more meaningfull subject next time you ask a question in a technical forum. 95 % of the questions in this forum are about "Powershell script". ;-)


    Live long and prosper!

    (79,108,97,102|%{[char]$_})-join''

    • Edited by BOfH-666 Thursday, May 9, 2019 3:42 PM
    • Proposed as answer by Richard MuellerMVP Thursday, May 9, 2019 4:03 PM
    • Marked as answer by Hush_IT Friday, May 10, 2019 9:55 AM
    Thursday, May 9, 2019 3:39 PM
  • Roger that!!

    Thanks BOfH_666 for your response. I will try it with Get-ADGroupMember.

    I am completely new to the forum and with time I am sure I will be more specific.:)

    Cheers :)

    Thursday, May 9, 2019 4:48 PM
  • You might read the following help as well:

    How to Ask Questions in a Technical Forum


    Live long and prosper!

    (79,108,97,102|%{[char]$_})-join''

    Thursday, May 9, 2019 4:58 PM
  • Thanks!!
    Friday, May 10, 2019 9:56 AM