In this article I will show you how to fix the task sequence error 0x80004005.
The error 0x80004005 is a general error and doesn’t actually mean anything. I have many different fixes which depend on when we see the error in the task sequence.
An Error Occurred While Retrieving Policy For This Computer
This error can appear before you have started to run the task sequence. You will see the error as per below.
An Error Occurred While Retrieving Policy For This Computer (0x80004005). For more information, contact your system administrator or helpdesk operator.
The main causes for the above error are
- DNS issue
- Time sync
- Self-Signed Certificate Has Expired
To troubleshoot this issue we need to look in the smsts.log file to find the root cause. At the above screen press F8 and open the smsts.log file (Should be in the location x:\windows\temp\smstslog\smsts.log).
DNS Issue
If you see the below errors the issue should be because of DNS issues.
- unknown host (gethostbyname failed)
- sending with winhttp failed; 80072ee7
- Failed to get client identity (80072ee7)
Is the DHCP server setting the correct DNS servers? Can you ping the dns name of the SCCM server?
Time sync
If you see the below errors then the issue should be a time sync issue
- SyncTimeWithMP() failed. 80072ee7
- Failed to get time information from MP: http://MPserverFQDN
- An error occurred while retrieving policy for this computer
To fix this issue go in to the client machines BIOS and make sure the time and date are set correctly then run the task sequence again.
I recommend you to press F8 and open the command prompt and run the date and time commands to confirm the correct date and time are set.
Self-Signed Certificate Has Expired
If the self-signed certificate has expired this will also cause the above error. To check if it has expired do the following.
- Open up the SCCM console
- Go to \Administration\Overview\Site Configuration\Servers and Site System Roles
- Left click on the SCCM server that is serving the PXE boot
- Right click on distribution point > Properties
- Click on the communication tab
- Check the expire date
- If it has expired re-create the certificate
0x80004005 Whilst Running SCCM Task Sequence
You could also see this error when running the task sequence. Below is a screenshot I took when I got the error a few days ago.
First thing we need to do is work out which task sequence step is causing the error. To do this follow these steps
- Open the SCCM console
- Go to \Monitoring\Overview\Deployments
- Left click on the required task sequence
- then click on view status
- Find the machine name that had the error (Should be under error tab)
- Left click on the computer under assett details
- Select more details
- Now look at the exit codes to work out which step caused the error
Now we know which step caused the error we can now work out how to fix it.
Drivers
If the error was caused by a driver confirm the following
- Are the drivers being applied to the correct machine model
- Are the drivers distributed
You could try to re-download the drivers and add them back in to SCCM again.
Is the drivers getting applied via a command line? I have seen an issue where there is a syntax error in the command line, for example (Setup.exe /auto upgrade / noreboot /dynamicupgrade /compat scanonly) Should of been (Setup.exe /auto upgrade / noreboot /dynamicupgrade /compat /scanonly) it was missing a / before scanonly.
To test the command line you can log on to the machine and manually run the command line and see if it installs as expected.
Applications
If you identify an application is causing the error we will need to check the applications install command. To do this follow these steps
- Open the SCCM console
- Go to \Software Library\Overview\Application Management\Applications
- Locate the application and right click > Properties
- Click deployment types tab
- Select the application and click edit
- Click programs tab
- Verify the installation program command is correct
- I recommend to manually run this command on a machine that does not have the application installed to verify it installs correctly
Conclusion
How To Fix Task Sequence Error 0x80004005? To fix the 0x80004005 error first make sure the date and time in the computers bios is correct, then confirm DNS resolution is working and make sure the SCCM self-signed certificate for the distribution point has not expired.