You get the following error when trying to deploy Windows 7 installation with SCCM OSD:
"Task Sequence: WHATEVER has failed with the error code (0x80091007). For more information, please contact your system administrator or helpdesk operator."

download.php?kb=49&file=1.jpg

When checking the Advertisement Status of the task sequence you see the following error messages:
1. The task sequence execution engine failed executing the action (Apply Operating System) in the group (Build the Reference Machine) with the error code 2148077575
Action output: zSource, sSourceDirectory, dwFlags, hUserToken, pszUserName, pszUserPassword), HRESULT=80091007 (e:\nts_sms_fre\sms\framework\tscore\resolvesource.cpp,3130)
ResolveSource(pszSource, sSourceDirectory, dwFlags, 0, 0, 0), HRESULT=80091007 (e:\nts_sms_fre\sms\framework\tscore\resolvesource.cpp,3031)
TS::Utility::ResolveSource( this->packageID, this->packagePath, TS::Utility::ResolveSourceFlags::PersistContents ), HRESULT=80091007 (e:\nts_sms_fre\sms\client\osdeployment\applyos\installscripted.cpp,160)
installer.install(), HRESULT=80091007 (e:\nts_sms_fre\sms\client\osdeployment\applyos\installscripted.cpp,632)
Entering ReleaseSource() for C:\_SMSTaskSequence\Packages\WHATEVER
The user tries to release a source directory C:\_SMSTaskSequence\Packages\WHATEVER that is either already released or we have not connected to it
InstallScripted( g_InstallPackageID, g_ImageIndex, targetVolume, g_ConfigPackageID, g_ConfigFileName ), HRESULT=80091007 (e:\nts_sms_fre\sms\client\osdeployment\applyos\applyos.cpp,397). The operating system reported error 2148077575: The hash value is not correct. 

2. The task sequence execution engine failed execution of a task sequence. The operating system reported error 2148077575: The hash value is not correct. 

3. The task sequence manager could not successfully complete execution of the task sequence. A failure exit code of 16389 was returned.


Furthermore, if you check C:\SMSTSLog\smsts.log on the deployed computer, you see the following errors:
1. Hash could not be matched for the downloded content. Original ContentHash = WHATEVER, Downloaded ContentHash = WHATEVER2

2. The user tries to release a source directory C:\_SMSTaskSequence\Packages\WHATEVER that is either already released or we have not connected to it

3. Failed to run the action: Apply Operating System. 
The hash value is not correct. (Error: 80091007; Source: Windows)

4. The execution of the group (Build the Reference Machine) has failed and the execution has been aborted. An action failed.
Operation aborted (Error: 80004004; Source: Windows)

5. Failed to run the last action: Apply Operating System. Execution of task sequence failed.
The hash value is not correct. (Error: 80091007; Source: Windows)

Solution

1. Make sure you're running SCCM with SP2 installed. If not, check out: http://support.microsoft.com/kb/957065 and http://support.microsoft.com/kb/971413

2. Try to refresh the package's distribution point (refresh, not update): Site Management --> Computer Management --> Operating System Deployment --> Operating System Install Packages --> PACKAGE_NAME --> Distribution Points --> Right click on the Distribution Point you're using and choose "Refresh Distribution Point"

3. If it doesn't work, try to remove the distribution completely and re-add it (you must WAIT for it to complete the removal before re-adding it, you can use the Package Status to make sure it was removed)

4. If all else fails, go to Site Management --> Computer Management --> Software Distribution --> Advertisements --> Right click on the task sequence advertisement you're deploying and choose "Properties" --> Distribution Points --> check "Access content directly from a distribution point when needed by the running task sequence".

Affected software:

System Center Configuration Manager (SCCM) 2007
System Center Configuration Manager (SCCM) 2007 R2