Error in User State Capture: CNAME loop detected


  • Hey guys,

    I just got this weird issue -- seems a bunch of others got it too (look here: - and here:

    I'm using USMT 5 with MDT 2012.  In the UserCapture.log, it seems that the issue is that it's looking for a version of Windows, but doesn't find it.  Makes sense, since I'm running in Windows PE.  But this error doesn't occur with USMT 4.  Digging in the ZTIUserState.wsf file, I found an if cmd that does this:

    If sUSMTVersion = "USMT5" then
    If Left(oEnvironment.Item("ImageBuild"),3) = "6.1" then
    oLogging.CreateEntry "Special Case for USMT 5.0 scanstate for Windows 7 Target. /targetWindows7", LogTypeInfo
    sBaseArgs = sBaseArgs & " /targetWindows7"
    End if
    End if

    By editing out the sBaseArgs = sBaseArgs & " /targetWindows7" section, the deployment works no problem.  This section doesn't get called for USMT 3 or 4.  So I was wondering, what does this part do??  Is it some type of necessary command, and if so, how does one get it to work in Windows PE, since it errors out because it's not running in the full-blown OS??  

    Wednesday, December 26, 2012 5:45 PM

All replies

  • @ Q-techCan you tell me exactly what you did here, when you say you edited it out? Did you just comment a line out or the whole section? I've run into this problem and as I'm not scripter keen to know what you did here.



    Saturday, February 16, 2013 1:03 PM
  • @Dancing Ferret,

    Sorry about the late reply - with VBscript, you just add an apostrophe to the beginning of a line, and it comments it out.  So by changing the line sBaseArgs = sBaseArgs & " /targetWindows7" to ' sBaseArgs = sBaseArgs & " /targetWindows7" -- the entire line gets commented out.  

    This fixed the issue for me -- still haven't seen any issues with it, but I wish I knew why it's in there, and what it does....

    UPDATE - whoops, your question asked what I did.  I just edited out just the line, not the entire section, as I thought the section did some other things that I didn't want to mess up
    • Edited by Q-Tech Thursday, February 21, 2013 3:41 PM Added more info
    Wednesday, February 20, 2013 6:37 PM
  • So, I'm seeing the same thing.  I'm running the latest version of ADK 8.1, attempting to upgrade an XP machine to Windows 7.  (later from XP to Windows 8)

    Is there a good explanation as to why this needs to be done in order to get things to work properly?

    Tuesday, December 03, 2013 7:10 PM
  • I've seen this line commented out to fix issues in the past.

    /targetwindows7 is a USMT5 switch. It's used to optimise the manifests so that only Windows 7 compatible components are captured. It's meant to filter out incompatibility.

    Sadly it's not documented on Technet but its the equivalent of /TargetVista in USMT4 and /TargetXP in USMT3.


    Tuesday, December 03, 2013 10:53 PM
  • I'm having this issue too and I can fix it with these steps mentioned here too. 

    I have MDT 2012 U1 and Windows ADK 8.0. Trying to reinstall Windows 7 client and capture user data.

    What is causing this?

    Tuesday, February 11, 2014 5:29 PM
  • I found this:

    [August 2012] Incorrect manifest used in Windows 7 to Windows 7 offline migrations 

    During an offline Windows 7 to Windows 7 migration using the /TargetWindows7 switch, USMT uses the Windows 8 manifests rather than the Windows 7 manifests. This might result in migrating incorrect operating system settings. 

    Use one of the following options to mitigate this issue:

    • Use the previous version of USMT for the migration. You can download the previous version, USMT 4.0, as part of the Windows Automated Installation Kit available here.
    • Use the Windows 7 version of Windows PE in conjunction with USMT 5.0 rather than the Windows 8 version of Windows PE.
    • Move the DLManifests and ReplacementManifests folders outside of the User State Migration Tool\<arch> directory and rename the DLManifests7 and ReplacementManifests7 folders toDLManifests and ReplacementManifests, respectively.

    Tuesday, February 11, 2014 7:06 PM