Welcome to TechNet Blogs Sign in | Join | Help

Cravings of OSD

Cravings of OSD
Snazzy OSD status with BGInfo

 

Controlling the look and feel throughout OSD a very important part of creating a good user experience. Not only is the out-of-box experience a bit bland, it’s unfamiliar and confusing to someone who’s never experienced OSD before. Our goal in this article is to outline how to spice up the end-to-end deployment experience.

At a glance, a user should be able to tell:

  • What’s going on?
  • Where am I in the overall scheme of things?

Should the deployment go awry, these questions become even more important. In one glance, without looking at logs, anyone viewing the screen can answer questions such as:

  • Where did the machine fail?
  • What is the machine name?
  • Does it have an IP address?
  • Etc…

With BGInfo, the available information to display is nearly limitless; you have complete control over what details are visible and important to your organization.

A mockup of what might be used to accomplished this goal is shown below:

image

 

Showing Status

All this is possible through the use of BGInfo. With this utility, the background screen can be changed at any point in your Task Sequence.

In the mockup provided, the following practices were taken:

  1. Branding was provided to create familiarity and provide context for what is taking place
  2. Progress was grouped into 5 phases: System Backup, Install Image, Windows Setup, Install Applications, and Restore Backup
  3. One background bitmap was created for each phase; each time a phase completes, the background is changed

So, in the example given, 5 bitmaps were created. Thus, BGInfo will be called 5 times within our Task Sequence. Each bitmap represents the active “Phase” in an “On” position, and all other “Phases” in an “Off” position.

 

Creating Status Backgrounds

Since our deployment consists of 5 phases, we’ll need 5 different bitmaps. In addition to 5 different bitmaps, we actually need 5 BGInfo configuration files. BGInfo configuration files store rendering information used to display the background; these files are passed to BGInfo as parameters. 

To create a screen, open BGInfo and:

  1. Choose a background image to use
  2. Choose what computer information to display
  3. Format/Justify/Center as preferred

Defining the background image to use, color, and positioning:

image 

Defining what computer information is displayed, and where to position it:

image

Create all 5 pages in this manner, and save each BGInfo session. After completing these steps, the final list of files will look something like this:

image

 

Setting up the Task Sequence

Assuming all the required files exist in one directory, a method for calling the appropriate “Step” is necessary. This can be accomplished through a batch file containing the following:

  • "%~dp0bginfo.exe" "%~dp0step_0%1.bgi" /nolicprompt /silent /timer:0

In this manner, your Task Sequence would simply reference the package and call the batch file with a Step number:

image 

 

Maintaining Look & Feel

To maintain the look and feel across the entire deployment, there are three areas where adjusting the background image is important for consistency:

  • Task Sequence Wallpaper set through BGInfo (already covered)
  • Windows PE Wallpaper contained in the Boot Image
  • Windows Setup Phase Wallpaper

 

Boot Image

When initially starting up in Windows PE, a default built-in background image is displayed. Until your Task Sequence begins and the background batch file runs, a user will see whatever background ships in Windows PE.

Apply your own background by opening up the SCCM console, locating your boot image, and modifying its properties. Look for the “Windows PE Background” field:

image

 

Windows Setup

After applying and booting into it the new OS (after the “Setup Windows and ConfigMgr” step), an animated black background will appear for the duration of your Task Sequence. Windows Setup overlays a full-screen window named “FirstUXWnd”, displaying the text “Setup is preparing your computer for first use”. Until the Task Sequence has completed in its entirety, this window will be seen and the custom background will not.

Task Sequence background after booting into the new OS:

image

Assuming you’ve customized the first half of your Task Sequence to show a snazzy look/feel, you’ll probably want to persist this. Especially if your Task Sequence contains a large number of post-OS-install tasks, such as application installs.

One simple and safe workaround is to hide this window. Since we know the window title, we can simply search for it and send it a “hide window” message. However, this requires creating a small application to perform the hide.

Creating this application isn’t too difficult. An example of the API calls necessary to perform this is given below. Using either .NET or native C++, this is relatively simple to create.

  1. Enumerate all windows (EnumWindows)
  2. Search for the window titled “FirstUXWnd” (GetWindowText)
  3. Set the window state to “Hidden” (ShowWindow SW_HIDE | SW_SHOWNORMAL)

Once completed, run this binary from your Task Sequence immediately after the “Windows Setup and ConfigMgr” step.

Update! A complete source-code sample is available here.

You now completely control the deployment look and feel, end-to-end.

Posted: Wednesday, April 29, 2009 11:49 PM by cmse

Comments

martian said:

I saw you-guys at MMS. Great presentation. I have implemented this "snazzy" tip as much as I can. My manager likes your graphics better than the one that I am using. Can you post the STEP_##.bmp files? Also, is there any reason why you can't make the utility to hide FirstUXWnd available for download? It would be a big help.

I'm looking forward to more of your great posts. Keep up the good work.

Thanks

# May 10, 2009 4:55 PM

cmse said:

Martian:

We appreciate the compliment and glad you could make it!  We will absolutely help you out and will do a quick post today that shows our source for doing the hide and will share the bitmaps with you in bland format.  We have to be certain to strip out any references to Microsoft so you will only get the progress bar piece and we hope that is cool!  We have it on the radar for today...

Thanks

-Chris

# May 11, 2009 5:43 PM

cmse said:

Martian:

Here is a full-source example for hiding FirstUXWnd. I hope this helps:

http://blogs.technet.com/osd/archive/2009/05/12/c-sample-hide-window.aspx

-Mike

# May 12, 2009 3:44 AM

jeremy_decker@valleymed.org said:

I think im missing something with my setup of this, i created my .bmp, I setup BGinfo and seperate config files for each back ground. I then updated my boot image to contain the first back ground, and added my package to the DP. In the task sequence i used run command line and used step.bat X for each time i add it to the sequence. My problem im having is that when it refreshes for a second time i am only getting the background color and not the BMP loading. Is there a cache i need to clear in between refreshes? also after the reboot it doesnt pull the new BGinfo package for awhile so it is sitting at my default screen and not at the installing windows screen.

# May 20, 2009 1:37 PM

cmse said:

Can you be more specific about "refreshes for a second time"? Is it (initially) setting the background properly, but losing it later?

As for the second part of your problem, a reboot will reset wallpaper back to the WinPE default. Make sure to place a BG step after any reboots.

Now, if this is during the "Setup Windows & Config Manager" step, read on… You "lose" control of the Task Sequence (and background) from the time the new OS boots (post-WIM install), until after Setup Windows & Config completes. During this time the new OS is booting for the first time with its out-of-box background, running OSD hooks, and installing Configuration Manager on the new OS. Once this is complete, task sequence control resumes. I place a BG step immediately after this step, and hide the FirstUXWnd screen.

I hope this helps -

Mike

# May 26, 2009 5:22 PM

hamil998 said:

Hi Mike,

What do you for the image load phase (unattend) when the background changes and the TS is not able to run a bginfo? Is there a way to change the setup background somehow?

# May 30, 2009 5:01 PM

cmse said:

I leave first boot (unattend) alone. Thankfully the time spent here is short; TS hooks resume control soon afterwards.

Changing the initial boot background image is probably possible, but I imagine it’s more trouble than it’s worth. When weighing the risk vs. benefit, it doesn’t seem very appealing.

Just thinking out loud, but perhaps it would entail something like:

1. Install the WIM; while in PE, somehow install an OS hook on first boot and reboot

2. On first-boot, hook will trigger; set BG and hide FirstUXWnd

It's the "hooking" part that introduces a risky unknown at this point.

# June 3, 2009 5:21 PM

Thomas said:

Have anybody made this work with MDT 2010 Beta 2?

# July 8, 2009 9:20 AM

Mike N. said:

I don't see where the BMP files were ever posted online.  Am I just missing them somewhere?  Or, if I do have to make my own, what resolution should they be?

# July 15, 2009 8:13 AM

cmse said:

Hi Mike N.,

If you are a member of our Connect program (connect.microsoft.com) then you have access to the ModenaOSDTools.exe that has several Zip files that are extracted.

In the Scripts.zip, there is a folder called Scripts\BG that actually has BGINFO.exe and our sample BMP files along with WindowsHide.exe.

You can alter these as you see fit!

Thanks,

-Chris

# July 23, 2009 4:45 PM

cmse said:

Hey Thomas,

I don't believe that anyone on our end (Microsoft) has tested with the MDT toolkit.  We don't use the toolkit as we have to stay closer to release time where MDT is usually 90+ days after the releases.  Thus, we don't have it in our scope.

You could ask the deployment guys via there blog http://blogs.technet.com/deploymentguys/ as they are the ones that would probably have tested the use of our wizard with their tools.

Sorry we haven't had time to test this but hopefully this helps just a bit...

Thanks,

-Chris

# July 23, 2009 4:48 PM

Vitalie Ciobanu said:

Hi guys!

Thanks for this, works great! Except one thing :)

It seems I can't make the bmp image dissapear after TS has finished. While the user is displayed with ctrl+alt+del dialog box, it has the last bmp background.

How can I stop it from displaying after TS has finished successfuly?

Thanks,

Vit

# August 14, 2009 6:57 AM
Leave a Comment

(required) 

(required) 

(optional)

(required) 

  
Enter Code Here: Required

Comment Notification

If you would like to receive an email when updates are made to this post, please register here

Subscribe to this post's comments using RSS

Page view tracker