none
SCCM 2012 R2 SP1 RRS feed

  • Question

  • Dear Fellows,

    I have SCCM 2012 R2 SP1 installed on environment and trying to automate procedures using powershell, on try to execute get-cmcollectionmember command getting below error

    get-cmcollectionmember : The term 'get-cmcollectionmember' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the

    name, or if a path was included, verify that the path is correct and try again.

    kindly help why I am getting this error whe nother cmds like get-cmcollection are avalaibel and working

    regards

    Tuesday, February 13, 2018 9:52 AM

All replies

  • Hi M Asghar,

    Before executing get-cmcollectionmember you have to connect to SCCM with powershell. Check this guide: https://cloudblogs.microsoft.com/enterprisemobility/2013/03/27/powershell-connecting-to-configuration-manager/

    Regards

    Simon


    If you find that my post has answered your question, please mark it as the answer. If you find my post to be helpful in anyway, please click vote as helpful. Regards Simon Disclaimer: This posting is provided AS IS with no warranties or guarantees, and confers no rights.

    Tuesday, February 13, 2018 9:54 AM
  • Hi Simon Rech,

    I am connected to SCCM and commands like get-CMDevice, Get-CMCollection are working absolutely fine but seems like command Get-CMCollectionMember doesn't exist.

    Regards

    M. Asghar

    Tuesday, February 13, 2018 10:19 AM
  • Hi M Asghar

    Get-cmcollectionmember is a new cmdlet included with 1604 http://blog.ctglobalservices.com/powershell/kaj/configmgr-1605-new-cmdlets-2/

    Check your version.

    Regards

    Simon


    If you find that my post has answered your question, please mark it as the answer. If you find my post to be helpful in anyway, please click vote as helpful. Regards Simon Disclaimer: This posting is provided AS IS with no warranties or guarantees, and confers no rights.

    Tuesday, February 13, 2018 10:41 AM