SCCM 2012 – Display special lock Screen when OSD was unsuccessful

Hi, here’s Martin again with a blog about how to Display a Special Lock Screen, when the Operating System Deployment Task Sequence Fails. When you are using System Center 2012 Configuration Manager, you might want to have an easy solution to see, if a OSD was successful or not. Normally you see this Picture after a Windows 8.1 OSD:
Windows 8.1 Normal Lock Screen

So even if there are better and more robust Solutions through Status Message rules, sometimes you would like just to get a visible check. In this blog, I’ll Show you an easy way to achieve this.

The following steps has to be taken:
1. Create a failure Picture
2. Copy the Scripts to the Package Location
3. Create the Package
4. Add the Steps to the Task Sequence

1. Create a failure Picture
This is easily done through paint:
Paint Picture
Safe the Picture as jpg with the Name “OSD_Failed.jpg” in the designated Package Directory.

2. Copy the Scripts to the Package Location
Know create at the Package Location two files, the first one is named SetFailed_Background.bat which will set the failed LockScreen. The Content of this Batch is:
takeown /f C:\Windows\Web\Screen
takeown /f C:\Windows\Web\Screenimg100.jpg
icacls C:\Windows\Web\Screen /grant:r *S-1-5-32-544:F
icacls C:\Windows\Web\Screen\img100.jpg /grant:r *S-1-5-32-544:F
copy C:\Windows\Web\Screen\img100.jpg C:\Windows\Web\Screen\img100.old /Y
copy "%~dp0OSD_Failed.jpg" C:\Windows\Web\Screen\img100.jpg /Y

My script is derived from (https://yorkitacademy.wordpress.com/2012/11/20/customising-the-default-lock-screen-image-in-windows-8/). I just added the “%~dp0” variable to work in every Situation in SCCM, and also Changed the ACE to a SID, because on other languages, you can’t use “Administrator”.

And here is the second file, to set back the Standard LockScreen, Name the file SetStandard_Background.bat:
takeown /f C:\Windows\Web\Screen
takeown /f C:\Windows\Web\Screen\img100.jpg
icacls C:\Windows\Web\Screen /grant:r *S-1-5-32-544:F
icacls C:\Windows\Web\Screen\img100.jpg /grant:r *S-1-5-32-544:F
copy C:\Windows\Web\Screen\img100.old C:\Windows\Web\Screen\img100.jpg /Y

Your Package Directory should now Looks like this:
Package Directory

3. Create the Package
Now just create a Package with source Content of the Folder you created. Then add two programs to the packages, one for each Batch file. Your Package should then Looks like this:
SCCM Package

4. Add the Steps to the Task Sequence
Now add the steps to the Task sequence, and in the correct order. This means, we will set after the Windows Installation the failure Background as Standard LockScreen. And only if the Task Sequence reaches the end of the TS, the original LockScreen will be restored.
Add the Steps as marked out in this example TS:
TS Step1 TS Step 2

If now the Client has a error with installing an application or something else, when the OS was installed, your Windows 8.1 Machine will present you your LockScreen Picture:
OSD Failed

Hope this helps.

One thought on “SCCM 2012 – Display special lock Screen when OSD was unsuccessful

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.