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

Hostname Change & Joining Domain Before Sysprep Runs (XP & Win7!)

Scheduled Pinned Locked Moved
General
5
10
8.2k
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.
  • L
    Lee Rowlett Developer
    last edited by Aug 29, 2012, 6:16 PM

    Hi All,

    As this would be a lengthy tutorial to show you how to add this to FOG i thought i would give a summary first and if anyone is interested pm me and i’ll go through in detail, if enough people interested and find it easy to implement and happy with it, i’ll post the tutorial.

    How it works:
    Additional code added to the fog file within init.gz and a couple of .php files added to the service folder on the fog server. Just after fog has deployed the image, the code queries the fog database and gets fog to change the sysprep.inf/unattend.xml file to the information accordingly. so when the machine boots into sysprep it will have the right hostname and ad details if required.

    Pros:

    1. No more reboots required!
    2. Makes imaging quicker and if snapins aren’t used stops the need for the FOGClient
    3. Robust and hands the responsibility to sysprep and has never failed (been using for 12months)
    4. Works for XP, Win7 x64 & x86.

    Cons (as the code stands):

    1. Conflicts with hostname change early as this would no longer be required.
    2. requires sed package added to init.gz (Although a good guide on how modify the init exists in the wiki)
    3. Alot of information is hardcoded (can be easily changed but would need to be put into variables if considered for fog to be universal - maybe be able to change the variable and info set in fog settings page?):
      Hardcoded example - location of sysprep.inf/unattend.xml.
    4. Would need to get the init.gz to decrypt the ad password like the FOGClient.
    5. unattend.xml must contain certain empty options line to suceed.

    This has really helped and shaved around 10mins off our imaging time (suprising how long two reboots can take and waiting for snapin to checkin) the snapins can now be deployed almost instantly!

    1 Reply Last reply Reply Quote 0
    • L
      Lee Rowlett Developer
      last edited by Aug 29, 2012, 11:32 PM

      This post is deleted!
      1 Reply Last reply Reply Quote 0
      • L
        Lee Rowlett Developer
        last edited by Aug 29, 2012, 11:40 PM

        This post is deleted!
        1 Reply Last reply Reply Quote 0
        • D
          dvlsg
          last edited by Aug 30, 2012, 2:45 PM

          Phew. You’re right, you worked hard on this, haha.

          I’ll see what I can do about finding time to look into it. It may be a while - I’m going to be out of town for a bit after today. But I’ll check back in when I get time.

          1 Reply Last reply Reply Quote 0
          • D
            dvlsg
            last edited by Sep 11, 2012, 4:07 PM

            Got it working. I ended up working with a simplified version. We’re currently only using Windows 7, so I didn’t need any of the XP sections, and I actually have a different solution set up for joining the domain so I didn’t include that either – where I work, each domain user account is setup as a local admin on their own laptop (but not anywhere else), so I wrote some vbscript that handles that, joins the domain, restarts, and automatically logs in as the user.

            But! Your post was very, very helpful in showing me how to get the information from mysql using php (haven’t ever worked with php before), and using sed to replace variables in files. So thanks for taking the time to post this! I really appreciate it.

            1 Reply Last reply Reply Quote 0
            • L
              Lee Rowlett Developer
              last edited by Sep 11, 2012, 5:06 PM

              Glad I could help 🙂

              1 Reply Last reply Reply Quote 0
              • P
                Paul Moisant
                last edited by Mar 1, 2013, 10:46 PM

                I am looking at doing something like this.

                What support will version 0.33 have for this? I’d hate to recreate the wheel if I don’t need to.

                By the way, I am using version 0.32 of FOG.

                1 Reply Last reply Reply Quote 0
                • L
                  Lee Rowlett Developer
                  last edited by May 21, 2013, 1:55 PM

                  0.33 already has some alternative for changing the hostname by making changes using reg files. (HOSTNAME EARLY) this would conflict with this and i don’t it’s being included in 0.33. it would be same process and code for 0.33 though 🙂

                  1 Reply Last reply Reply Quote 0
                  • M
                    Marco Lohnen
                    last edited by Jul 4, 2013, 7:56 PM

                    [quote=“Lee Rowlett, post: 7954, member: 28”]Hi All,

                    As this would be a lengthy tutorial to show you how to add this to FOG i thought i would give a summary first and if anyone is interested pm me and i’ll go through in detail, if enough people interested and find it easy to implement and happy with it, i’ll post the tutorial.
                    [/quote]

                    Hi Lee, I’m really interested in your solution.
                    Could you give me some more details or put up a tutorial?

                    Thanks!

                    Marco

                    1 Reply Last reply Reply Quote 0
                    • B
                      Bill
                      last edited by Feb 20, 2014, 10:01 AM

                      I would really like to implement this solution as well, any chance of getting a complete tut?

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

                      212

                      Online

                      12.1k

                      Users

                      17.3k

                      Topics

                      155.3k

                      Posts
                      Copyright © 2012-2024 FOG Project