• Recent
    • Unsolved
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    Sysprep Surface Pro 4 WinPE help needed

    Scheduled Pinned Locked Moved Unsolved
    Windows Problems
    2
    2
    1.0k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • R
      rabwick
      last edited by

      Hi, im currently close to finishing sysprep on the surface pro 4. Im using winpe and StartNet.cmd to run a script, specifically the following script;

      @ECHO OFF
      :: 2016-03-09
      :: Deploy Windows 10

      wpeinit

      echo select disk 0 > diskpart%ID%.txt
      echo clean >> diskpart%ID%.txt
      echo convert gpt >> diskpart%ID%.txt
      echo create partition efi size=200 >> diskpart%ID%.txt
      echo select partition 1 >> diskpart%ID%.txt
      echo assign letter=“s” >> diskpart%ID%.txt
      echo format quick fs=FAT32 >> diskpart%ID%.txt
      echo create partition msr size=128 >> diskpart%ID%.txt
      echo create partition primary >> diskpart%ID%.txt
      echo select partition 3 >> diskpart%ID%.txt
      echo assign letter=“c” >> diskpart%ID%.txt
      echo format quick fs=NTFS >> diskpart%ID%.txt

      echo ** Executing diskpart script…
      diskpart /s diskpart%ID%.txt
      del diskpart%ID%.txt

      echo select disk 1 > diskpart%ID%.txt
      echo select partition 1 >> diskpart%ID%.txt
      echo assign letter=“g” >> diskpart%ID%.txt

      echo ** Executing diskpart script…
      diskpart /s diskpart%ID%.txt
      del diskpart%ID%.txt

      dism /apply-image /imagefile:g:\efisys.wim /index:1 /ApplyDir:s:
      dism /apply-image /imagefile:g:\OSimage.wim /index:1 /ApplyDir:c:\

      bcdedit /set {bootmgr} device partition=s:
      bcdedit /set {memdiag} device partition=s:

      bcdedit /set {default} device partition=c:
      bcdedit /set {default} osdevice partition=c:

      Bcdedit /set {FWbootmgr} displayorder {Bootmgr} /addfirst

      wpeutil shutdown

      from a USB with both my .wim files on the USB.

      Strangely, typing each command from the script in WinPE manually will work every time without fail, however when running the automated script with the same commands once it hits the line to assign letter ‘c’ the error is thrown: virtual service disk error: letter is already assigned.

      Once the script is typed manually at least once the automatic script will work fine after, however if i boot into gparted and remove all partitions or if i do a internal secure wipe with parted magic the script will not run automatically unless i type the commands manually again at least once, in which the automated script will run thereafter.

      I have noticed in gparted if i delete the partitions THEN make the drive ntfs i can then run the script automatically fine without having to type it manually. Im confused as to why typing the commands manually works but the script automatically does not even though they’re the same commands.

      alt text

      1 Reply Last reply Reply Quote 0
      • Wayne WorkmanW
        Wayne Workman
        last edited by

        Bumping this thread.

        Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG!
        Daily Clean Installation Results:
        https://fogtesting.fogproject.us/
        FOG Reporting:
        https://fog-external-reporting-results.fogproject.us/

        1 Reply Last reply Reply Quote 0
        • 1 / 1
        • First post
          Last post

        221

        Online

        12.0k

        Users

        17.3k

        Topics

        155.2k

        Posts
        Copyright © 2012-2024 FOG Project