Archives September 2022

Install Red Hat Linux and Subscription Manager

1. Install Red Hat Enterprise Linux:

  • Obtain the RHEL installation ISO from the Red Hat Customer Portal.
  • Create a bootable USB drive or DVD from the ISO.
  • Boot the system from the USB drive or DVD.
  • Follow the on-screen instructions to install RHEL, including configuring disk partitions, selecting software packages, and setting up user accounts.

2. Register and Enable Red Hat Subscription:

  • After installing RHEL, you need to register your system with Red Hat to enable access to software updates and support.
  • Open a terminal and run the following command to register your system:

subscription-manager register

  • Enter your Red Hat account credentials when prompted.

3. Attach a Subscription:

  • After registering, attach a subscription to your system. You can view available subscriptions with:

subscription-manager list –available

  • Attach a subscription with:

subscription-manager attach –pool=POOL_ID

  • Replace POOL_ID with the ID of the subscription you want to attach.

4. Enable Repositories:

  • Enable the necessary repositories for software updates and packages:

subscription-manager repos –enable=rhel-8-for-x86_64-baseos-rpms –enable=rhel-8-for-x86_64-appstream-rpms

  • Adjust the repository names according to your RHEL version and architecture.

5. Check Subscription Status:

  • Verify the subscription status of your system:

subscription-manager status

  • Ensure that the status is “Current” to indicate that the system is subscribed and can receive updates.

6. Update Your System:

  • Update the system to install any available updates:

yum update

7. Configure Automatic Updates (Optional):

  • You can configure Subscription Manager to automatically apply updates:

subscription-manager config –rhsm.auto_enable_yum_plugins=1

8. Verify Installation:

  • Verify that your system is registered and receiving updates:

yum repolist

  • This command will show the repositories enabled and the packages available for installation.

By following these steps, you can install Red Hat Enterprise Linux and configure Subscription Manager to manage software updates and subscriptions for your system.

Deploy BgInfo by Group Policy

1. Download and Install BgInfo:

  • Download BgInfo from the official Microsoft Sysinternals website.
  • Extract the downloaded ZIP file and copy the BgInfo.exe and BgInfo64.exe files to a network share that is accessible to all client machines.

2. Create a Configuration File:

  • Launch BgInfo on a test machine and configure the desired settings, such as the information to display and the background color.
  • Save the configuration as a .bgi file to the same network share where you copied the BgInfo executables.

3. Create a Group Policy Object (GPO):

  • Open the Group Policy Management Console (GPMC) on a domain controller or a machine with the Remote Server Administration Tools (RSAT) installed.
  • Right-click on the desired Organizational Unit (OU) or the domain name and select “Create a GPO in this domain, and Link it here.”
  • Give the GPO a descriptive name, such as “Deploy BgInfo.”

4. Edit the Group Policy Object:

  • Right-click on the newly created GPO and select “Edit.”
  • Navigate to “Computer Configuration” > “Policies” > “Windows Settings” > “Scripts (Startup/Shutdown).”
  • Double-click on “Startup” in the right pane.

5. Add a Startup Script to Run BgInfo:

  • Click on the “Add” button in the “Startup Properties” window.
  • In the “Script Name” field, enter the UNC path to the BgInfo executable (e.g., \\server\share\BgInfo.exe).
  • In the “Script Parameters” field, enter the path to the configuration file (e.g., \\server\share\config.bgi).
  • Click “OK” to save the script.

6. Copy BgInfo Files to Client Machines:

  • Ensure that the BgInfo executable (BgInfo.exe or BgInfo64.exe) and the configuration file (config.bgi) are accessible from the network share specified in the startup script.

7. Apply the Group Policy:

  • Close the Group Policy Management Editor and link the GPO to the desired OU or domain.
  • Run gpupdate /force on client machines or wait for Group Policy to apply automatically.

8. Verify Deployment:

  • Restart a client machine (or run gpupdate /force) to apply the Group Policy.
  • The system information specified in the BgInfo configuration file should be displayed on the desktop background.

By following these steps, you can deploy BgInfo using Group Policy to automatically display system information on the desktop background of Windows machines in your domain.

Capture Customized Windows Image by WDS

Step 1: Prepare the Reference Computer
Install Windows on a reference computer.
Customize the Windows installation as needed (install applications, configure settings, etc.).
Step 2: Sysprep the Reference Computer
Open a command prompt with administrative privileges.
Navigate to the Sysprep folder (usually located at C:\Windows\System32\Sysprep).
Run the Sysprep tool with the following options:
bash
sysprep.exe /generalize /oobe /shutdown /unattend:unattend.xml
  • /generalize: Prepares the Windows installation to be imaged.
  • /oobe: Configures the computer to boot to Windows Welcome upon the next restart.
  • /shutdown: Shuts down the computer after Sysprep completes.
  • /unattend:unattend.xml: Specifies an unattend.xml file to automate the Sysprep process. This file is optional but recommended for consistency.

Step 3: Boot the Reference Computer into Windows PE

  • Insert a bootable media (USB drive or DVD) containing Windows PE.
  • Boot the reference computer from the bootable media.

Step 4: Capture the Image

  • In Windows PE, open a command prompt.
  • Use the WDSUTIL command to capture the image. For example:

mathematica
WDSUTIL /Verbose /Progress /Capture-Image /Image:”CustomImage” /Name:”Custom Image” /Description:”Customized Windows Image” /CaptureDir:”D:\Captures”

  • /Image:"CustomImage": Specifies the name for the captured image.
  • /Name:"Custom Image": Specifies a friendly name for the captured image.
  • /Description:"Customized Windows Image": Provides a description for the captured image.
  • /CaptureDir:"D:\Captures": Specifies the directory to store the captured image.

Step 5: Upload the Captured Image to WDS Server

  • After capturing the image, navigate to the WDS server.
  • Use the WDS MMC snap-in or the WDSUTIL command to upload the captured image to the server.

Step 6: Create an Install Image

  • In the WDS MMC snap-in, right-click on “Install Images” and select “Add Install Image.”
  • Specify the location of the captured image file and follow the wizard to create the install image.

Step 7: Deploy the Image

  • Boot a client computer from the network using PXE boot.
  • Select the customized image from the WDS server for deployment.
  • Follow the on-screen instructions to deploy the image to the client computer.

Make sure to test the deployment thoroughly before deploying to production environments.