jump to navigation

Troubleshooting Database Issues with MDT 2010 November 4, 2009

Posted by tmintner in MDT 2010, Troubleshooting, Uncategorized, VBscript.
Tags: , , ,
add a comment

There have been a few really great posts on how to troubleshoot database connection issues with BDD and MDT over the past couple of years.  Ben Hunter wrote a great post on this here: http://blogs.technet.com/benhunter/archive/2007/07/10/bdd-2007-troubleshooting-database-issues.aspx.  However, if you try to do this with MDT 2010 you will get a few errors in the output.  In MDT 2010 the structure of the scripts have changed somewhat and the functionality of ztigather has been extended to also gather additional information that now requires some compiled code.  So with MDT 2010, you can perform the same steps with the following modifications:

1. Create a folder on the client device and copy the following files from the deployment point to this folder:

  • ZTIGather.wsf
  • ZTIGather.xml
  • ZTIUtility.vbs
  • CustomSettings.ini
  • ZTIDataAccess.vbs (new script file in MDT 2010 for accessing data sources)
  • Create a Tools folder and create an X86 and X64 folders underneath the Tools folder.  Copy the Microsoft.BDD.Utility.dll file from the Tools\X64 and Tools\X86 folders in your deployment share to your newly created Tools\X86 and Tools\X64 folder

  2. Delete C:\MININT directory if it already exists. This folder can also be located at X:\MININT if the C drive is not available.

NOTE: MDT stores configuration and progress information in the MININT folder, if this folder is not removed between tests then the results will be invalid.

  3. From the command prompt navigate to the newly created folder and execute the rule processing script using the following command:

“cscript.exe ZTIGather.wsf /debug:true”

      The script will then be processed and the results outputted to the command prompt and a log file ( .\MININT\SMSOSD\OSDLOGS\ZTIGather.log)

NOTE: The script can be run within Windows PE or the host operating system.

  4. Review the results of the script.

Enjoy!

Tim Mintner is a Principal Consultant with Xtreme Consulting Group

Prevent machine from falling asleep. November 4, 2009

Posted by keithga in Uncategorized.
comments closed

Erik, asked about a post from last week regarding “Falling asleep on the job (task)”:

Would you mind sharing that tool you wrote :) ?

Also, is ES_CONTINUOUS and ES_SYSTEM_REQUIRED flags cleared when the system is rebooted?

What I am thinking of is if you run a util that set the above at the beginning of the Lite Touch process. Would you need to run another util that that clears the EXECUTION_STATE flag at the end of the Lite Touch sequence? Or will it be cleared automatically when you reboot the computer using a Restart Computer entry in the Task Sequence?

More background

When you set the Execution state, although you are setting the state of the entire system, the Operating System will only keep track of the requested state during the lifespan of the Thread that made the call. Once the thread (or process) exits, the request is no longer valid, and the system goes back to whatever the last state was.

In MDT 2010, this was easily solved by making the call to SetThreadExecutionState() from within the litetouch.wsf script. Since the Litetouch.wsf script thread stayed alive during the Task Execution phase (in the background), that worked out fine.

Also, the Thread Execution State does not persist across reboots, so cleanup was not necessary, just exit out of litetouch.wsf, and the machine can go into hibernation.

Side Effects

This *may* have a side effect. If you choose to display the final Summary Dialog Box at the end of the Litetouch process, the machine will stay alive during that time, until the user comes back to the machine.

New Tool

Just in case you have “Other” tasks that require you to keep a machine alive, here is a tool I wrote back in 2005 (cleaned up here). This *.exe tool will keep a Windows Machine alive while it is running. Meaning the machine won’t be able to fall asleep either by hibernate or by suspend.

The tool has to remain running while you want the machine to stay awake. So you can run it with the command line:

start KeepAlive.exe

This program is a Windows Program and will run with no user interface. You can see if it’s running by checking the task manager.

When you are done, just run the command again (Either with or without the –close flag:

KeepAlive.exe

If KeepAlive.exe detects that another instance of itself is running in the background holding up Thread Execution State, the new instance of KeepAlive.exe will signal to the previous instance to stop and release the Execution State.

The source code is included

Link

http://cid-5407b03614346a99.office.live.com/self.aspx/Blog/KeepAlive.zip

Keith

Keith Garner is a Deployment Specialist with Xtreme Consulting Group
Follow

Get every new post delivered to your Inbox.

Join 84 other followers