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

    Windows 7 : universal image with Postdownload script : issues

    Scheduled Pinned Locked Moved Solved
    Windows Problems
    5
    40
    10.1k
    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.
    • Jonathan CoolJ
      Jonathan Cool
      last edited by

      Hi,
      Thank you @george1421 🙂
      After some tests, it seem to work but not at 100 per cent.
      What i did :
      On the Win7x64 Vbox image :

      • add a script SetupComplete.cmd with this line :
        dism /Online /add-driver /driver:C:\Windows\DRV /Recurse

      I reUP the image on FOG server and tried on the 820G3 : it’s seem to work ! … but … the domain jonction seem to be broken.

      I said “What is going on now ???”
      I tried the same image on the same computer (820G3) and … same result.
      I tried the image on the Opti7010 and … same resultat : the domain jonction feature didn’t work anymore.
      I said “I am going crazy ?”
      I Googled this fact … and i find some answers (on this link : https://wiki.fogproject.org/wiki/index.php?title=FOG_Client#FOG_Client_with_Sysprep)

           Disable FOGService: Windows Control Pannel -> View by Small Icons -> Administrative Tools -> Services -> Right click FOGService -> Properties -> Startup Type -> Disabled
      Re-enable FOGService post-imaging:
      
      Create the below file.
      
      C:\Windows\Setup\scripts\SetupComplete.cmd
      
      Place these lines within the file, and then save.
      
      sc config FOGService start= auto
      shutdown -t 0 -r
      

      Well, if i add theses lines on my SetupComplete.cmd, it’s will work this time (Drivers AND domain jonction) ? Or i am in the wrong way ?

      My stuff :
      Server :
      FOG Version : Running Version 1.5.9
      OS : Debian GNU/Linux 10
      FOG Client Version : 0.12
      Specifications :
      > All images are on a Synology NAS storage : mounted with NAS_ip:/images
      > French user :)
      > “If everything would work the first time, what would you have learned?”
      Challenges make knowledge growth … by George1421 ;)

      george1421G 1 Reply Last reply Reply Quote 0
      • george1421G
        george1421 Moderator @Jonathan Cool
        last edited by

        @Jonathan-Cool There is two ways to have the target computers to connect to domain.

        1. Have unattend.xml do this. You must provide the domain connection information in your unattend.xml. I do it this way because we have a complicated OU structure and we I have some scripts in the post install that decide where (physical location) the target computer is being installed and type of computer (desktop, laptop) to calculates the OU where the computer will exist. Once the target OU is calculated the unattend.xml file is updated using a sed expression. Then during OOBE, windows setup connects the computer to the domain.
        2. Have the fog client connect the computer to the domain. To do this, you must install the fog client into your reference image but disable the service. You must disable the service to keep the fog client from starting too early in OOBE in the windows setup process. Then use the setupcomplete.cmd batch file to re-enable the fog client service. This is the script you posted below. You must also have the fog client options enabled in the FOG web gui.

        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!

        1 Reply Last reply Reply Quote 0
        • Jonathan CoolJ
          Jonathan Cool
          last edited by

          Hi,
          I used the 2nd method but, in the fog.log on the client, error 1355 …
          It’s strange because, with an other image without any SetupComand.cmd and a classic install of FOG Client into the image reference, it’s works.

          I used the Global settings to set ID of my domain. It’s not a typo …

          With the image using the SetupComplete.cmd, domain jonction feature fail …

          I think Windows correctly reads the SetupComands.cmd because the first problem seem solved (Drivers Injection). But, after the reboot, in services, i seen “FOGService : Disabled”.

          My SetupComplete.cmd :

          rem Injection des pilotes avant le premier Login Screen
          dism /Online /add-driver /driver:C:\Windows\DRV /Recurse
          
          rem Demarrage du service FOG avant le premier Login Screen
          sc config FOGService start= auto
          shutdown -t 5 -r
          

          My stuff :
          Server :
          FOG Version : Running Version 1.5.9
          OS : Debian GNU/Linux 10
          FOG Client Version : 0.12
          Specifications :
          > All images are on a Synology NAS storage : mounted with NAS_ip:/images
          > French user :)
          > “If everything would work the first time, what would you have learned?”
          Challenges make knowledge growth … by George1421 ;)

          george1421G 1 Reply Last reply Reply Quote 0
          • george1421G
            george1421 Moderator @Jonathan Cool
            last edited by

            @Jonathan-Cool So your current problem is that the fog service is not turning back on in the setupcomplete.cmd?

            What happens if you change the order in the setupcomplete.cmd file. Make the sc command come first maybe dism is doing something right, but causing the sc command to fail. The sc command looks right and should work.

            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!

            1 Reply Last reply Reply Quote 0
            • Jonathan CoolJ
              Jonathan Cool
              last edited by Jonathan Cool

              2 side problems with SetupComplete.cmd :

              • the fog service is not turning back on
              • IF i turn the service at “start” manuelly, the domain jonction feature fail with error 1355

              I have not theses problems without SetupComplete.cmd.

              I tried to put the dism command-line in second and the sc config in first … same result.
              Strange 😞

              Now, i ask my self if the SetupComplete is really executed …

              Edit : i will try this script :

              mkdir C:\TestSetupComplete
              sc config FOGService start= auto
              dism /Online /add-driver /driver:C:\Windows\DRV /Recurse /ForceUnsigned
              shutdown -t 5 -r

              My stuff :
              Server :
              FOG Version : Running Version 1.5.9
              OS : Debian GNU/Linux 10
              FOG Client Version : 0.12
              Specifications :
              > All images are on a Synology NAS storage : mounted with NAS_ip:/images
              > French user :)
              > “If everything would work the first time, what would you have learned?”
              Challenges make knowledge growth … by George1421 ;)

              george1421G Jonathan CoolJ 2 Replies Last reply Reply Quote 0
              • george1421G
                george1421 Moderator @Jonathan Cool
                last edited by

                @Jonathan-Cool I would also test from cmd prompt that sc config FOGService start= auto works as expected with your OS.

                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!

                Jonathan CoolJ 1 Reply Last reply Reply Quote 0
                • Jonathan CoolJ
                  Jonathan Cool @george1421
                  last edited by

                  @george1421 said in Windows 7 : universal image with Postdownload script : issues:

                  @Jonathan-Cool I would also test from cmd prompt that sc config FOGService start= auto works as expected with your OS.

                  @george1421 Yes, it’s works. I already tried 😉

                  My stuff :
                  Server :
                  FOG Version : Running Version 1.5.9
                  OS : Debian GNU/Linux 10
                  FOG Client Version : 0.12
                  Specifications :
                  > All images are on a Synology NAS storage : mounted with NAS_ip:/images
                  > French user :)
                  > “If everything would work the first time, what would you have learned?”
                  Challenges make knowledge growth … by George1421 ;)

                  1 Reply Last reply Reply Quote 0
                  • Jonathan CoolJ
                    Jonathan Cool @Jonathan Cool
                    last edited by

                    @Jonathan-Cool said in Windows 7 : universal image with Postdownload script : issues:

                    2 side problems with SetupComplete.cmd :

                    • the fog service is not turning back on
                    • IF i turn the service at “start” manuelly, the domain jonction feature fail with error 1355

                    I have not theses problems without SetupComplete.cmd.

                    I tried to put the dism command-line in second and the sc config in first … same result.
                    Strange 😞

                    Now, i ask my self if the SetupComplete is really executed …

                    Edit : i will try this script :

                    mkdir C:\TestSetupComplete
                    sc config FOGService start= auto
                    dism /Online /add-driver /driver:C:\Windows\DRV /Recurse /ForceUnsigned
                    shutdown -t 5 -r
                    

                    And now, the feedback … :

                    • “mkdir C:\TestSetupComplete” : no folder was created …
                    • sc config FOGService start= auto : FOG is always disabled
                    • dism : maybe it’s good because i have no drivers problems
                    • shutdown : just after the deploy, i not sure if the computer really reboot …

                    My stuff :
                    Server :
                    FOG Version : Running Version 1.5.9
                    OS : Debian GNU/Linux 10
                    FOG Client Version : 0.12
                    Specifications :
                    > All images are on a Synology NAS storage : mounted with NAS_ip:/images
                    > French user :)
                    > “If everything would work the first time, what would you have learned?”
                    Challenges make knowledge growth … by George1421 ;)

                    george1421G 1 Reply Last reply Reply Quote 0
                    • george1421G
                      george1421 Moderator @Jonathan Cool
                      last edited by george1421

                      @Jonathan-Cool Your source media used to create your reference image, is that oem or vlk?

                      If its OEM I can understand why it not work.

                      First of all from the legal side M$ EULA for OEM media doesn’t allow for system reimaging if you alter the media at all. You can reimage using oem media as long as its from the original OEM dvd unaltered. This is a Microsoft requirement and not anything to do with fog. For imaging you must use the VLK media and VLK license.

                      Since OEM media license does not allow imaging you should stop now and get the properly licensed media.

                      I have heard of people using OEM media (against the MS EULA) for imaging. I think they called the setupcomplete.cmd file from the unattend.xml file using the first run section. But again that is only what I heard and never tried.

                      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!

                      Jonathan CoolJ 1 Reply Last reply Reply Quote 0
                      • Jonathan CoolJ
                        Jonathan Cool @george1421
                        last edited by Jonathan Cool

                        @george1421 I read the OEM / VLK things.

                        After a “slmgr -dli”, i think i have a VLK license :
                        In “Description”, i can see “VOLUME_KMSCLIENT channel”.
                        And, the product number not start by “OEM” …

                        Source : http://mywindowshub.com/determine-windows-license-type-oem-retail-volume/
                        PS : we used a KMS Server to activate all Win7 in our office.

                        My stuff :
                        Server :
                        FOG Version : Running Version 1.5.9
                        OS : Debian GNU/Linux 10
                        FOG Client Version : 0.12
                        Specifications :
                        > All images are on a Synology NAS storage : mounted with NAS_ip:/images
                        > French user :)
                        > “If everything would work the first time, what would you have learned?”
                        Challenges make knowledge growth … by George1421 ;)

                        1 Reply Last reply Reply Quote 0
                        • Jonathan CoolJ
                          Jonathan Cool
                          last edited by Jonathan Cool

                          Hm, maybe i did a misktake.
                          The FOG documentation said : “f you plan to use Sysprep before image capture and are also planning to use the FOG Client” … but, i never use the “Sysprep.exe”.
                          On my Vbox, i just

                          • create the SetupComplete.cmd with the script*lines
                          • disable FOG
                          • upload the image on FOG

                          On client, i just donwload the image …

                          My stuff :
                          Server :
                          FOG Version : Running Version 1.5.9
                          OS : Debian GNU/Linux 10
                          FOG Client Version : 0.12
                          Specifications :
                          > All images are on a Synology NAS storage : mounted with NAS_ip:/images
                          > French user :)
                          > “If everything would work the first time, what would you have learned?”
                          Challenges make knowledge growth … by George1421 ;)

                          george1421G 1 Reply Last reply Reply Quote 0
                          • george1421G
                            george1421 Moderator @Jonathan Cool
                            last edited by

                            @Jonathan-Cool said in Windows 7 : universal image with Postdownload script : issues:

                            Hm, maybe i did a misktake.
                            The FOG documentation said : “f you plan to use Sysprep before image capture and are also planning to use the FOG Client” … but, i never use the “Sysprep.exe”.

                            Well I guess that explains it right there. Without sysprep your drivers will not import and setupcomplete.cmd will not run. Shame on you for not following the rules…

                            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!

                            1 Reply Last reply Reply Quote 0
                            • Jonathan CoolJ
                              Jonathan Cool
                              last edited by

                              Oh … i’m really sorry for this mistake.
                              In fact, i realized some tests with Sysprep before to know the SetupComplete.cmd.
                              On Win10, I created an unattend file for the registry hack but … after deploy, i alway seen the OOBE screen. At this time, i said “What the hell with this screen ?” and … went back to Windows 7 for tests. Before THIS mistake, i didn’t understand the link with Sysprep and the SetupComplete.cmd but now … i think I understand 🙂
                              Today, i will try some tests with Sysprep.
                              But, just to understand, why the domain jonction feature is broken if i have a SetupComplete.cmd in the Windows\Scripts\ folder ?
                              You say “SetupComplete will not run” … Maybe it’s totally another problem … ?

                              My stuff :
                              Server :
                              FOG Version : Running Version 1.5.9
                              OS : Debian GNU/Linux 10
                              FOG Client Version : 0.12
                              Specifications :
                              > All images are on a Synology NAS storage : mounted with NAS_ip:/images
                              > French user :)
                              > “If everything would work the first time, what would you have learned?”
                              Challenges make knowledge growth … by George1421 ;)

                              1 Reply Last reply Reply Quote 0
                              • Jonathan CoolJ
                                Jonathan Cool
                                last edited by

                                Hello.
                                After some new researches, i found informations about sysprep.
                                And I discovered new issues : the unsigned drivers.
                                In my first attempt, I had many error during Sysprep causing by unsigned drivers. Same error on 820G3, Optiplex7010 & HP8000.
                                Well. I found the solution : in my reference image and before the Sysprep op, i installed two importants updates : KB2685811 & KB2685813.
                                After a reboot, i sysprep /generalize /oobe /shutdown the image (I took a snapshot before).
                                And i retry with theses computers : no error during the sysprep 🙂
                                And i can confirm, the SetupComplete ran : after the deploy, i can confirm :

                                • the FOGService is started
                                • drivers are OK (excepted ACPI for DELL but i will fix that later)
                                  BUT the domain jonction fail … for all computers … error 1355.

                                I didn’t use any unattend file … after the deploy, I answer at the questions.
                                There is a link about the unattend file and the FOG Domain jonction feature ?

                                My stuff :
                                Server :
                                FOG Version : Running Version 1.5.9
                                OS : Debian GNU/Linux 10
                                FOG Client Version : 0.12
                                Specifications :
                                > All images are on a Synology NAS storage : mounted with NAS_ip:/images
                                > French user :)
                                > “If everything would work the first time, what would you have learned?”
                                Challenges make knowledge growth … by George1421 ;)

                                george1421G 1 Reply Last reply Reply Quote 0
                                • george1421G
                                  george1421 Moderator @Jonathan Cool
                                  last edited by

                                  @Jonathan-Cool Use this: http://windowsafg.no-ip.org/

                                  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!

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

                                  151

                                  Online

                                  12.0k

                                  Users

                                  17.3k

                                  Topics

                                  155.2k

                                  Posts
                                  Copyright © 2012-2024 FOG Project