Unattended Setup does not Use Computer Name Specified by User during OOBE to Join the Domain

Applies to: Windows Vista EnterpriseWindows Vista BusinessWindows Vista Ultimate More

Source: Microsoft Support

RAPID PUBLISHING


RAPID PUBLISHING ARTICLES PROVIDE INFORMATION DIRECTLY FROM WITHIN THE MICROSOFT SUPPORT ORGANIZATION. THE INFORMATION CONTAINED HEREIN IS CREATED IN RESPONSE TO EMERGING OR UNIQUE TOPICS, OR IS INTENDED SUPPLEMENT OTHER KNOWLEDGE BASE INFORMATION.

Result


After you deploy a Windows Vista image or Windows Server 2008 image you may encounter the following issues:

  • When logging into the computer you receive the following error message "The trust relationship between this workstation and the primary domain failed."
  • The computer account in Active Directory is a random computer name instead of the computer name specified during OOBE when the image booted up for the first time.

Cause



This behavior is by design. Domain joining occurs much earlier in the process than the Computer Name page in OOBE. The OOBE phase of setup cannot correctly change the computer name in the domain if the computer has already been joined to a domain during installation.

Resolution




A workaround is as follows:

1. Do not use the Microsoft-Windows-UnattendedJoin section to auto join the domain.

2. Use the Microsoft-Windows-Shell-Setup\FirstLogonCommands section to automatically run a script post setup. This script is to join the computer to the domain and reboot.

More Information


 This issue is resolved in Windows 7 since a random computer name is used and users are no longer prompted to enter the computer name during the OOBE phase.

Sample script: Join a Computer to a Domain
http://www.microsoft.com/technet/scriptcenter/scripts/ad/computer/cptrvb06.mspx?mfr=true

DISCLAIMER


MICROSOFT CORPORATION AND/OR ITS RESPECTIVE SUPPLIERS MAKE NO REPRESENTATIONS ABOUT THE SUITABILITY, RELIABILITY, OR ACCURACY OF THE INFORMATION AND RELATED GRAPHICS CONTAINED HEREIN. ALL SUCH INFORMATION AND RELATED GRAPHICS ARE PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT AND/OR ITS RESPECTIVE SUPPLIERS HEREBY DISCLAIM ALL WARRANTIES AND CONDITIONS WITH REGARD TO THIS INFORMATION AND RELATED GRAPHICS, INCLUDING ALL IMPLIED WARRANTIES AND CONDITIONS OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, WORKMANLIKE EFFORT, TITLE AND NON-INFRINGEMENT. YOU SPECIFICALLY AGREE THAT IN NO EVENT SHALL MICROSOFT AND/OR ITS SUPPLIERS BE LIABLE FOR ANY DIRECT, INDIRECT, PUNITIVE, INCIDENTAL, SPECIAL, CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER INCLUDING, WITHOUT LIMITATION, DAMAGES FOR LOSS OF USE, DATA OR PROFITS, ARISING OUT OF OR IN ANY WAY CONNECTED WITH THE USE OF OR INABILITY TO USE THE INFORMATION AND RELATED GRAPHICS CONTAINED HEREIN, WHETHER BASED ON CONTRACT, TORT, NEGLIGENCE, STRICT LIABILITY OR OTHERWISE, EVEN IF MICROSOFT OR ANY OF ITS SUPPLIERS HAS BEEN ADVISED OF THE POSSIBILITY OF DAMAGES.