Saturday, March 19, 2022

Create bootable Windows PE media

 The Windows Assessment and Deployment Kit (ADK) deployment tools and ADK Windows PE Add ons, include command-line utilities that make it easy to create bootable WinPE media:

  • CopyPE creates a working set of Windows PE files
  • MakeWinPEMedia uses the working set of files to create bootable Windows PE media. MakeWinPEMedia can create bootable Windows PE USB drives, virtual hard disks, or ISOs that allow you to boot a VM or burn to a DVD or CD.

Note

If you're using the ADK for Windows 10, version 1803 or earlier, Windows PE is included in the ADK when you choose the Windows Preinstallation environment option during setup and doesn't require a separate addon.

Step 1: Create working files

No matter what type of media you're going to create, the first thing to do is create a working set of Windows PE files on your technician PC.

  1. Make sure your PC has the ADK and ADK Windows PE add-on installed.

  2. Start the Deployment and Imaging Tools Environment as an administrator.

  3. Run copype to create a working copy of the Windows PE files. For more information about copype, see Copype command line options.

    cmd
  1. copype amd64 C:\WinPE_amd64
    

Step 2: Customize Windows PE

The customizations below are common, but not every Windows PE image requires customizations. When you add packages to Window PE, it can slow performance and boot time. Only add additional packages when necessary.

Common customizations

  • For Windows 11: If you're launching Windows Setup from Window PE, add the WinPE-WMI and WinPE-SecureStartup optional components. If you don't include these optional components, you may see an error that your PC doesn't meet the minimum hardware requirements.
  • Add an update. To learn more, see: WinPE: mount and customize.
  • Add a video or network driver. (Windows PE includes generic video and network drivers, but in some cases, additional drivers are needed to show the screen or connect to the network.). To learn more, see WinPE: Add drivers.
  • Add PowerShell scripting support. To learn more, see WinPE: Adding Windows PowerShell support to Windows PE. PowerShell scripts are not included in this lab.
  • Set the power scheme to high-performance. Speeds deployment. Note, our sample deployment scripts already set this scheme automatically. See WinPE: Mount and Customize: High Performance.
  • Optimize Windows PE: Recommended for devices with limited RAM and storage (for example, 1GB RAM/16GB storage). After you add drivers or other customizations to Windows PE, see Image optimization to help reduce the boot time.

Step 3: Create bootable media

Now that you now have a set of working files, you can use MakeWinPEMedia to build bootable WinPE media.

Create a bootable Windows PE USB drive

  1. Attach a USB drive to your technician PC.

  2. Start the Deployment and Imaging Tools Environment as an administrator.

  3. Optional You can format your USB key prior to running MakeWinPEMedia. MakeWinPEMedia will format your Windows PE drive as FAT32. If you want to be able to store files larger than 4GB on your Windows PE USB drive, you can create a multipartition USB drive that has an additional partition formatted as NTFS. See Create a multipartition USB drive for instructions.

  4. Use MakeWinPEMedia with the /UFD option to format and install Windows PE to the USB flash drive, specifying the USB key's drive letter:

    cmd
  1. MakeWinPEMedia /UFD C:\WinPE_amd64 P:
    

    Warning

    This command reformats the partition.

    See MakeWinPEMedia command line options for all available options.

The bootable Windows PE USB drive is ready. You can use it to boot a PC into Windows PE.

Create a WinPE ISO, DVD, or CD

  1. Use MakeWinPEMedia with the /ISO option to create an ISO file containing the Windows PE files:

    cmd
  1. MakeWinPEMedia /ISO C:\WinPE_amd64 C:\WinPE_amd64\WinPE_amd64.iso
    
  2. Optional Burn a DVD or CD: In Windows Explorer, right-click the ISO file, and select Burn disc image > Burn, and follow the prompts.

Create a Windows PE VHD to use with Hyper-V

You can create a bootable VHD to use with Hyper-V.

Tip

If you're planning to run Windows PE in Hyper-V, consider using an ISO file format instead of a VHD to enable faster setup of the virtual PC.

To install Windows PE to a VHD:

  1. Create a virtual hard drive (.vhdx):

    cmd
  • diskpart
    create vdisk file="C:\WinPE.vhdx" maximum=1000
    attach vdisk
    create partition primary
    assign letter=V
    format fs=ntfs quick
    exit
    
  • Prepare the drive by using MakeWinPEMedia:

    cmd
  • MakeWinPEMedia /UFD C:\WinPE_amd64 V:
    
  • Detach the drive:

    cmd
    1. diskpart
      select vdisk file="C:\WinPE.vhdx"
      detach vdisk
      exit
      

    Boot from the media you created

    Now that you've created bootable Windows PE media, you can use it to boot your PC.

    1. Insert the media into the PC you want to boot.
    2. Turn on the PC.
    3. Press the key or key combination that will bring up the boot menu. This key or key combination is different depending on your PC manufacturers. If you don't know which key combination will bring up your PC's boot menu, contact your PC manufacturer.
    4. From the boot menu, select the bootable Windows PE media.

    Your PC will boot into Windows PE.

    Troubleshooting

    1. If Windows PE doesn't appear, try the following workarounds, rebooting the PC each time:

      • To boot a PC that supports UEFI mode: In the firmware boot menus, try manually selecting the boot files: \EFI\BOOT\BOOTX64.EFI.
      • If your PC requires storage or video drivers to boot, try adding those same drivers to the Windows PE image. For more information, see WinPE: Mount and Customize.
    2. If the PC doesn't connect to network locations, see WinPE Network Drivers: Initializing and adding drivers.

    Sunday, March 13, 2022

    Join Domain option missing on Windows 10/11

    The join Domain option is missing in Windows 10 / 11 Pro

    How do I add Windows 10 / 11 pro to a domain?

    1. Join Domain From Settings

    1. Click on Start and select Settings.
    2. Go to Accounts.

    3. Click on “Access work or School” from the left pane.
    4. Click on “Connect” button.
    5. Click on “Join this device to a local Active Directory Domain.
    6. Now enter the Domain name and click Next.
    7. Follow the on-screen instructions to join the Domain.

    2. Join Domain from This PC Properties

    1. Open “File Explorer” from the taskbar.
    2. Right-click on This PC and select Properties.
    3. Under “Computer name, domain and workgroup settings“, click on Change.

    4. In the System Properties window, click on the Computer Name tab.

    5. Click on Network ID button to join a domain or Workgroup.
    6. Follow the on-screen instructions to Join the domain.

    3.  Join a Domain using Command Prompt

    1. Type cmd in the search bar.
    2. Right-click on Command Prompt and select “Run as Administrator“.
    3. In the Command Prompt, enter the following command and hit enter.
      netdom /domain:<domainname> /user:<username> /password:<password> member <computer name> /joindomain
    4. In the above command replace Domain with your domain name, the user with your username. Add the password and make sure to change the computer name with your PC name.

    5. This should add your computer to the Domain.

    4. Adding Other Users to Domain

    1. Open the Command Prompt as Admin.
    2. In the Command Prompt window, type the following command and hit enter.
      netdom /domain:KFM /user:rct /password:P@ssw0rd member <computer name> /add
    3. To run the above command you need to be the Administrator of the domain. And it is necessary that you run this command to add the new user to the domain before the user can join that domain.
    4. Now on the user front, enter the following command and hit enter.
    5. netdom /domain:KFM /user:rct /password:P@ssw0rd member <computer name> /joindomain
    6. Here also make necessary changes to the above command to join the domain.

    In the above command, Netdom is a command line tool that is built-into Windows Server 2008 and above. It can be used to not only join domain but create an account and trust relationships. So if you deal with the Domains frequently, this can be really handy utility to learn.




    How to add a website as a trusted site

     

    Microsoft Edge

    To add a trusted site for Microsoft Edge, follow the steps below.

    1. Open the Control Panel.
    2. Click or double-click the Internet Options icon.
    3. In the Internet Properties window, click the Security tab.
    4. Select the Trusted sites entry and click the Sites button.

    Trusted sites in Internet Properties for Microsoft Edge

    1. Enter the address for the trusted website in the Add this website to the zone text field.
    2. Click the Add button, then click OK to save the website addition.


    Internet Explorer

    To add a trusted site for Internet Explorer, follow the steps below.

    1. Open the Control Panel.
    2. Click or double-click the Internet Options icon.
    3. In the Internet Properties window, click the Security tab.
    4. Select the Trusted sites entry and click the Sites button.

    Trusted sites in Internet Properties for Microsoft Edge

    1. Enter the address for the trusted website in the Add this website to the zone text field.
    2. Click the Add button, then click OK to save the website addition.


    Google Chrome

    To add a trusted site for Google Chrome, follow the steps below.

    1. Open the Control Panel.
    2. Click or double-click the Internet Options icon.
    3. In the Internet Properties window, click the Security tab.
    4. Select the Trusted sites entry and click the Sites button.

    Trusted sites in Internet Properties for Microsoft Edge

    1. Enter the address for the trusted website in the Add this website to the zone text field.
    2. Click the Add button, then click OK to save the website addition.


    To manage security settings for a website at a more granular level, follow the steps below.

    1. In the browser address bar, click the lock icon or "Not secure" text to the left of the website address and select the Site settings option.
    2. In the Settings window, review the security options listed and change any settings as desired.


    Firefox

    To set security permissions for a trusted site in Firefox, follow the steps below.

    1. In the browser address bar, click the shield icon to the left of the website address.
    2. Click the gear icon for Content Blocking or Permissions to adjust the security settings for the website.


    1. In the Options window, review and make the desired changes to the security options and permissions for the website.