Announcement

Collapse
No announcement yet.

deleting a whole directory structure after the sysprep statement

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • deleting a whole directory structure after the sysprep statement

    HI

    I should delete a whole directory structure after the statement:

    Code:
    sysprep /generalize /oobe /reboot
    In other words, during the shutdown phase, I should remove this directory structure?

    So, how do I fix this?

    THANKS

    BYE
    balubeto

  • #2
    Re: deleting a whole directory structure after the sysprep statement

    What directory structure are you asking about? The 'sysprep' folder will automatically be deleted as part of the windows oobe startup, so there's nothing else to remove.

    If you want to remove something so it's not in the image when you capture it, remove that folder BEFORE you run sysprep.
    *RicklesP*
    MSCA (2003/XP), Security+, CCNA

    ** Remember: credit where credit is due, and reputation points as appropriate **

    Comment


    • #3
      Re: deleting a whole directory structure after the sysprep statement

      Originally posted by RicklesP View Post
      What directory structure are you asking about? The 'sysprep' folder will automatically be deleted as part of the windows oobe startup, so there's nothing else to remove.

      If you want to remove something so it's not in the image when you capture it, remove that folder BEFORE you run sysprep.
      How do I delete the public directory structure?

      THANKS

      BYE
      balubeto

      Comment


      • #4
        Re: deleting a whole directory structure after the sysprep statement

        Sorry, but I have no idea what you mean by your reply. What is the 'public directory structure' you are referring to?
        *RicklesP*
        MSCA (2003/XP), Security+, CCNA

        ** Remember: credit where credit is due, and reputation points as appropriate **

        Comment


        • #5
          Re: deleting a whole directory structure after the sysprep statement

          Originally posted by RicklesP View Post
          Sorry, but I have no idea what you mean by your reply. What is the 'public directory structure' you are referring to?
          is C:\Users\Public

          THANKS

          BYE
          balubeto

          Comment


          • #6
            Re: deleting a whole directory structure after the sysprep statement

            this is the public profile and should not be deleted

            Why can't you configure it as you want before sysprep?
            Tom Jones
            MCT, MCSE (2000:Security & 2003), MCSA:Security & Messaging, MCDBA, MCDST, MCITP(EA, EMA, SA, EDA, ES, CS), MCTS, MCP, Sec+
            PhD, MSc, FIAP, MIITT
            IT Trainer / Consultant
            Ossian Ltd
            Scotland

            ** Remember to give credit where credit is due and leave reputation points where appropriate **

            Comment


            • #7
              Re: deleting a whole directory structure after the sysprep statement

              Clearly, before deleting the C:\Users\Publicdirectory, I have copied it to a new location and I appropriately modified the Windows registry to ensure that, at the next reboot, the operating system find this directory in the new location.

              So, I would like to know how do I delete this directory before or during the reboot of Windows performed from the sysprep /generalize /oobe /reboot command.

              THANKS

              BYE
              Last edited by balubeto; 18th April 2012, 17:42.
              balubeto

              Comment


              • #8
                Re: deleting a whole directory structure after the sysprep statement

                Manually delete the folder before running your sysprep cmd line, or create a small batch file to delete the folder and then call the sysprep cmd.
                *RicklesP*
                MSCA (2003/XP), Security+, CCNA

                ** Remember: credit where credit is due, and reputation points as appropriate **

                Comment


                • #9
                  Re: deleting a whole directory structure after the sysprep statement

                  Why'd you move the public directory in the first place? What purpose does this serve?
                  ** Remember to give credit where credit is due and leave reputation points where appropriate **

                  Comment


                  • #10
                    Re: deleting a whole directory structure after the sysprep statement

                    Originally posted by RicklesP View Post
                    Manually delete the folder before running your sysprep cmd line, or create a small batch file to delete the folder and then call the sysprep cmd.
                    Using the Command prompt, how do I remove this directory structure without angering the system?

                    THANKS

                    BYE
                    balubeto

                    Comment


                    • #11
                      Re: deleting a whole directory structure after the sysprep statement

                      Is there a specific reason for doing it via the command prompt??

                      http://ss64.com/nt/del.html

                      Comment


                      • #12
                        Re: deleting a whole directory structure after the sysprep statement

                        Try:

                        @echo off
                        rmdir C:\Users\Public /S /Q
                        sysprep /generalize /oobe /reboot
                        exit

                        But as 'wired' asked, what's with moving/copying it to a different location on the same machine anyway? in XP speak, 'Public' equals 'All Users' and that's a system profile folder.
                        Last edited by RicklesP; 19th April 2012, 20:38. Reason: mis-spelled word and unneeded accents
                        *RicklesP*
                        MSCA (2003/XP), Security+, CCNA

                        ** Remember: credit where credit is due, and reputation points as appropriate **

                        Comment


                        • #13
                          Re: deleting a whole directory structure after the sysprep statement

                          When looking for a solution to your problem of removing access to the public folder I came across this thread on the TechNet forums. Unfortunately, without clarification on what exactly you want to remove, everyone on this current thread is making an assumption as to what it is that you are trying to accomplish.

                          As Stephan advised you on this TechNet forum thread, it is strongly recommend to NOT remove the C:\Users\Public folder as it may be used by various applications that share data for multiple users on the system in question. An example of an application that requires the use of this folder would be Intuit’s QuickBooks.

                          With that said, you may be able to use the cmdlines.txt file in your sysprep\..\$OEM$ folder as outlined in this Microsoft Knowledge Base article and as is suggested by lee-bowman in this TechNet thread. However, as the aforementioned Microsoft KB article is related to Microsoft operating systems that preceded both Windows Vista and Windows 7 you might find the TechNet library resource Comparing Windows XP and Windows Vista Deployment Technologies beneficial as it explains the changes that were made from Windows XP to Windows Vista and Windows 7 regarding the cmdlines.txt file and the RunSychronous setting in the Microsoft-Windows-Deployment component.

                          Jessica
                          Windows Outreach Team – IT Pro

                          Comment

                          Working...
                          X