none
Import-CMDeviceInformation: failed to import a computer into a collection RRS feed

  • Question

  • Hello All,

    I'm trying to import a computer into the database by using the powershell cmdlets which have been delivered through SP1.

    The syntax I'm using is as follows:

    Import-CMComputerInformation -CollectionName "Win8 Staging" -ComputerName "SVLABW802" -MacAddress "5F:DA:FA:FA:FA:FA"

    The error which is then displayed is:"WARNING: The collection Win8 Staging does not exist or is not suitable for adding the new device."


    The collection definetly does exist: http://dl.dropbox.com/u/44493467/collection.png

    What could be causing this?

    Thanks in advance!

    Filip

    Friday, December 28, 2012 10:05 AM

Answers

  • The PowerShell cmdlets that come with SP1 are not the final versions. With that said, I will verify if this issue reproduces in our more recent internal builds of the PowerShell cmdlets and will get a bug filed if it does. Thanks for reporting this!

    Friday, December 28, 2012 6:12 PM

All replies

  • Hi,

    I see the same thing and I think that there is one problem with that command-let. If you check the SMSPROV.Log file then you see that it will do this query:

    Execute WQL  =SELECT * FROM SMS_Collection WHERE CollectionType=2~~                                           And CollectionID like 'CM%' And Name='Win8 Staging' ORDER by Name

    but this does not return anything and the collection exists. I think that there is a mistake. There should be no CollectionID Like 'CM%' in this query syntax.

    Best,

    Kaido

    Friday, December 28, 2012 10:56 AM
    Moderator
  • The PowerShell cmdlets that come with SP1 are not the final versions. With that said, I will verify if this issue reproduces in our more recent internal builds of the PowerShell cmdlets and will get a bug filed if it does. Thanks for reporting this!

    Friday, December 28, 2012 6:12 PM
  • Hello Adam,

    Thanks for confirming this bug!

    Can you please report back when you've got confirmation that the more recent internal builds are no longer showing this?

    Thanks!

    Filip

    Thursday, January 3, 2013 6:31 AM
  • Hi Filip,

    It is a known bug and it will be fixed.

    Best,

    Kaido

    Thursday, January 3, 2013 7:09 AM
    Moderator
  • Any news on a fix for this?

    Mario

    Thursday, February 28, 2013 1:07 PM
  • Hi,

    Not yet. Maybe Microsoft can say when it will be fixed.

    Best,

    Kaido

    Thursday, February 28, 2013 1:46 PM
    Moderator
  • I definitely need an update on this issue.  Please confirm that this is a documented bug.  If it is then please provide some information as to when it will be resolved.  Not having access to this method makes automating deployments very difficult and it appears that my previous PS methods do not work against CM12.

    Thanks!

    Tuesday, March 12, 2013 3:44 PM
  • Then you should call CSS. Adam, who posted above, is from the product group so you can take what he said above as official. As for when it will be addressed, nothing has been announced to my knowledge.

    Jason | http://blog.configmgrftw.com

    Tuesday, March 12, 2013 4:51 PM
    Moderator
  • This issue will be fixed in SP1 CU1.
    Tuesday, March 12, 2013 6:36 PM
  • Hi Filip,

    why don't you use other methods that DO work?

    I know that using the native SP1 cmdlets is easy, but there are other ways to Import Computers.

    Try this script: http://www.david-obrien.net/2012/07/25/import-computer-to-configuration-manager-2007-2012/
    There are also vbs scripts on the Internet.

    That might be quicker than waiting for the SP1 CU1, although I don't know when this will be released.


    David O'Brien | MCITP/MCSE/MCSA, CCEE/CCIA | My blog: www.david-obrien.net | me on Twitter: @david_obrien | sepago GmbH

    Tuesday, March 12, 2013 7:02 PM
  • Thanks for the tip!  I ended up ditching the built in cmdlets, I was trying to use those so that I would be able to support others that are using my infrastructure in the future.  I went with the SDK methods which end up being just fine.
    Wednesday, March 13, 2013 1:19 PM
  • Hello everybody,

    Any news on that problem?? We have installed SP1 CU1 and the problem still exists. (Also checked the query and it is still CollectionID like 'CM%' And Name=XXXX)

    Thank you very much in advance!

    Tuesday, April 23, 2013 12:48 PM
  • Hi,

    You need to update AdminConsole also. You can find the adminconsole.msp under the hotfix folder (c:\program files\Microsoft Configuration Manager\hotfix\kb2817245\adminconsole).

    BEst,

    Kaido

    Tuesday, April 23, 2013 12:58 PM
    Moderator
  • Hi,
    that worked! Thank you very much! Did not know even that this is connected with each other in that way...
    BR,
    RundG
    Tuesday, April 23, 2013 1:43 PM