Skip to content

Instantly share code, notes, and snippets.

@derekjkeller
Forked from myersCody/satellite_notes.md
Created November 12, 2020 07:27
Show Gist options
  • Select an option

  • Save derekjkeller/f34f58127fbcdc4991b18d0e5ad592fe to your computer and use it in GitHub Desktop.

Select an option

Save derekjkeller/f34f58127fbcdc4991b18d0e5ad592fe to your computer and use it in GitHub Desktop.

Revisions

  1. @myersCody myersCody revised this gist Jun 3, 2020. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions satellite_notes.md
    Original file line number Diff line number Diff line change
    @@ -4,6 +4,7 @@
    ### Resources

    **iso files**:

    *redhat only link*
    http://download.devel.redhat.com/released/Satellite-6/6.6-GA/Sat-RHEL-7/Satellite/x86_64/iso/

  2. @myersCody myersCody revised this gist Jun 3, 2020. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions satellite_notes.md
    Original file line number Diff line number Diff line change
    @@ -4,13 +4,13 @@
    ### Resources

    **iso files**:
    <redhat only link>
    *redhat only link*
    http://download.devel.redhat.com/released/Satellite-6/6.6-GA/Sat-RHEL-7/Satellite/x86_64/iso/

    **manifest**:
    You will need a manifest that contain the sku's available to you.

    <redhat only link>
    *redhat only link*
    http://file.rdu.redhat.com/~rjerrido/manifests/

    **docs**:
  3. @myersCody myersCody revised this gist Jun 2, 2020. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions satellite_notes.md
    Original file line number Diff line number Diff line change
    @@ -292,7 +292,7 @@ Now go to `Content->Products`, select all of the repos and sync them.
    **Create an Activation Key**
    Now go to `Content->Activation Keys->Create Activation Key`. Create the new key, then add the `Red Hat Satellite Infrastructure Subscription` to the key. Then click on `Repository sets` and make sure that all of the repos are enabled.

    # Configuring Discovery Server Container
    #### Configuring Discovery Server Container

    Now go to `Content->Products->Create Product`, name it `discovery-server-image` and hit create. Now go to the new product and go to the `Repositories` tab and click `New Repository`. Name the repo `redhat-registry` and change the type to `docker` then:

    @@ -304,6 +304,6 @@ After you have created the new repository, go ahead an attempt to sync it.

    After it is synced, you can find where it is published by going to `Content->Container Image Tags->latest` and then click on the `Lifecycle Environments`.

    # Host Machine
    #### Host Machine
    yum install -y http://<your_ip>/pub/katello-ca-consumer-latest.noarch.rpm
    subscription-manager register --org="Default_Organization" --activationkey="vagrant-key"
  4. @myersCody myersCody revised this gist Jun 2, 2020. 1 changed file with 7 additions and 9 deletions.
    16 changes: 7 additions & 9 deletions satellite_notes.md
    Original file line number Diff line number Diff line change
    @@ -1,7 +1,7 @@
    #### Configuring and Installing Satellite to handle Discovery offline install

    ### Installing Satellite
    ## Resources
    ## Installing Satellite
    ### Resources

    **iso files**:
    <redhat only link>
    @@ -28,7 +28,7 @@ https://access.redhat.com/documentation/en-us/red_hat_satellite/6.6/html-single/
    https://access.redhat.com/documentation/en-us/red_hat_satellite/6.2/html/content_management_guide/managing_container_images


    ## Setting up your VM
    ##### Setting up your VM

    **VM Hardware Requirements**
    When you clone a vm, you will need to follow the hardware requirements for satellite.
    @@ -44,7 +44,7 @@ ansible-playbook install_satellite_internal.yml -i hosts.yml --private-key ssh_k
    ssh -i id_sonar_jenkins_rsa root@
    ```

    ## How to update satellite
    ##### How to update satellite

    **WARNING:** You will need to have the vcenter registered with the subscription-manager. To do so, you may need to reach out to satellite support contact.

    @@ -57,7 +57,7 @@ satellite-maintain upgrade list-versions
    satellite-maintain upgrade check --target-version 6.6.z


    ### Resize the filesystem to pass the disk space check
    ##### Resize the filesystem to pass the disk space check


    I listed the block device, to see the disk itself is now bigger, but partition inside were still small
    @@ -239,7 +239,7 @@ data blocks changed from 3511296 to 24482816
    ```

    # Upgrade Satellite
    ### Upgrade Satellite

    ```
    @@ -251,7 +251,7 @@ data blocks changed from 3511296 to 24482816
    ```

    # Configuring Discovery with Satellite UI
    ## Configuring Discovery with Satellite UI

    **Login:**
    https://<your_ip>/users/login
    @@ -266,8 +266,6 @@ admin

    - Note: You can find the default password by using: `satellite-installer --help`

    ### Configuring Satellite

    **Upload Manifest (Optional)**
    Go to `Content->Subscriptions`, and then click on the `Manage Manifest` tab. Upload a manifest that provides access to the `Red Hat Satellite Infrastructure Subscription` subscription. Make sure that the subscription is new enough to contain the `Red Hat Discovery` under provides.

  5. @myersCody myersCody created this gist Jun 2, 2020.
    311 changes: 311 additions & 0 deletions satellite_notes.md
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,311 @@
    #### Configuring and Installing Satellite to handle Discovery offline install

    ### Installing Satellite
    ## Resources

    **iso files**:
    <redhat only link>
    http://download.devel.redhat.com/released/Satellite-6/6.6-GA/Sat-RHEL-7/Satellite/x86_64/iso/

    **manifest**:
    You will need a manifest that contain the sku's available to you.

    <redhat only link>
    http://file.rdu.redhat.com/~rjerrido/manifests/

    **docs**:

    1) **Configure Docs**

    https://access.redhat.com/documentation/en-us/red_hat_satellite/6.0/html-single/installation_guide/index#sect-Red_Hat_Satellite-Installation_Guide-Installing_RednbspHat_Satellite_with_an_ISO_Image

    2) **Firewall docs**

    https://access.redhat.com/documentation/en-us/red_hat_satellite/6.6/html-single/installing_satellite_server_from_a_connected_network/index#ports-and-firewalls-requirements_satellite

    3) **Container Images In Satellite**

    https://access.redhat.com/documentation/en-us/red_hat_satellite/6.2/html/content_management_guide/managing_container_images


    ## Setting up your VM

    **VM Hardware Requirements**
    When you clone a vm, you will need to follow the hardware requirements for satellite.

    - 8 gbs of ram
    - 110 gbs of disk space

    I have cloned a rhel7 vm in vcenter called: `cmyers-rhel7-satellite`

    **Install Satellite on vcenter**
    ```
    ansible-playbook install_satellite_internal.yml -i hosts.yml --private-key ssh_keys/id_sonar_jenkins_rsa
    ssh -i id_sonar_jenkins_rsa root@
    ```

    ## How to update satellite

    **WARNING:** You will need to have the vcenter registered with the subscription-manager. To do so, you may need to reach out to satellite support contact.

    subscription-manager repos --enable rhel-7-server-satellite-maintenance-6-rpms

    yum install -y rubygem-foreman_maintain

    satellite-maintain upgrade list-versions

    satellite-maintain upgrade check --target-version 6.6.z


    ### Resize the filesystem to pass the disk space check


    I listed the block device, to see the disk itself is now bigger, but partition inside were still small

    ```
    [root@dhcp-8-29-137 ~]# lsblk
    NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
    fd0 2:0 1 4K 0 disk
    sda 8:0 0 110G 0 disk
    ├─sda1 8:1 0 1G 0 part /boot
    └─sda2 8:2 0 15G 0 part
    ├─rhel_dhcp182--50-root 253:0 0 13.4G 0 lvm /
    └─rhel_dhcp182--50-swap 253:1 0 1.6G 0 lvm [SWAP]
    sr0 11:0 1 1024M 0 rom
    ```

    Then I used a tool called fdisk to create a new one

    ```
    [root@dhcp-8-29-137 ~]# fdisk /dev/sda
    Welcome to fdisk (util-linux 2.23.2).
    Changes will remain in memory only, until you decide to write them.
    Be careful before using the write command.
    Command (m for help): p
    Disk /dev/sda: 118.1 GB, 118111600640 bytes, 230686720 sectors
    Units = sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    Disk label type: dos
    Disk identifier: 0x000d87ff
    Device Boot Start End Blocks Id System
    /dev/sda1 * 2048 2099199 1048576 83 Linux
    /dev/sda2 2099200 33554431 15727616 8e Linux LVM
    [root@dhcp-8-29-137 ~]# Command (m for help): n
    Partition type:
    p primary (2 primary, 0 extended, 2 free)
    e extended
    Select (default p): p
    Partition number (3,4, default 3):
    First sector (33554432-230686719, default 33554432):
    Using default value 33554432
    Last sector, +sectors or +size{K,M,G} (33554432-230686719, default 230686719):
    Using default value 230686719
    Partition 3 of type Linux and of size 94 GiB is set
    [root@dhcp-8-29-137 ~]# Command (m for help): w
    The partition table has been altered!
    Calling ioctl() to re-read partition table.
    WARNING: Re-reading the partition table failed with error 16: Device or resource busy.
    The kernel still uses the old table. The new table will be used at
    the next reboot or after you run partprobe(8) or kpartx(8)
    Syncing disks.
    [root@dhcp-8-29-137 ~]# reboot
    ```

    Now after the reboot I see the new partition at 94 gb

    ```
    [root@dhcp-8-29-137 ~]# lsblk
    NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
    fd0 2:0 1 4K 0 disk
    sda 8:0 0 110G 0 disk
    ├─sda1 8:1 0 1G 0 part /boot
    ├─sda2 8:2 0 15G 0 part
    │ ├─rhel_dhcp182--50-root 253:0 0 13.4G 0 lvm /
    │ └─rhel_dhcp182--50-swap 253:1 0 1.6G 0 lvm [SWAP]
    └─sda3 8:3 0 94G 0 part
    sr0 11:0 1 1024M 0 rom
    ```

    Create a PV out of it:

    ```
    [root@dhcp-8-29-137 ~]# pvcreate /dev/sda3
    Physical volume "/dev/sda3" successfully created.
    ```

    Adding the PV to the existing VG

    ```
    [root@dhcp-8-29-137 ~]# vgextend rhel_dhcp182-50 /dev/sda3
    Volume group "rhel_dhcp182-50" successfully extended
    ```

    Adding 80 gb to the lv, we'll keep some in case we need to add swap or anything

    ```
    [root@dhcp-8-29-137 ~]# lvextend -L +80G /dev/mapper/rhel_dhcp182--50-root
    Size of logical volume rhel_dhcp182-50/root changed from 13.39 GiB (3429 extents) to 93.39 GiB (23909 extents).
    Logical volume rhel_dhcp182-50/root successfully resized.
    ```

    Need to resize the filesystem:

    ```
    [root@dhcp-8-29-137 ~]# xfs_growfs /dev/mapper/rhel_dhcp182--50-root
    meta-data=/dev/mapper/rhel_dhcp182--50-root isize=512 agcount=4, agsize=877824 blks
    = sectsz=512 attr=2, projid32bit=1
    = crc=1 finobt=0 spinodes=0
    data = bsize=4096 blocks=3511296, imaxpct=25
    = sunit=0 swidth=0 blks
    naming =version 2 bsize=4096 ascii-ci=0 ftype=1
    log =internal bsize=4096 blocks=2560, version=2
    = sectsz=512 sunit=0 blks, lazy-count=1
    realtime =none extsz=4096 blocks=0, rtextents=0
    data blocks changed from 3511296 to 24482816
    ```

    # Upgrade Satellite

    ```
    # satellite-maintain upgrade check --target-version 6.6.z
    # satellite-maintain upgrade run --target-version 6.6.z
    # reboot
    ```

    # Configuring Discovery with Satellite UI

    **Login:**
    https://<your_ip>/users/login

    ```
    # username:
    admin
    # password:
    <your_password>
    ```

    - Note: You can find the default password by using: `satellite-installer --help`

    ### Configuring Satellite

    **Upload Manifest (Optional)**
    Go to `Content->Subscriptions`, and then click on the `Manage Manifest` tab. Upload a manifest that provides access to the `Red Hat Satellite Infrastructure Subscription` subscription. Make sure that the subscription is new enough to contain the `Red Hat Discovery` under provides.

    - This step is optional depending on how much the customer uses satellite. If they have an already established satellite, its probably likely that it is already configured with their subscription.

    **Add the Subscription (Optional)**
    After you upload the manifest, click the `Add Subscriptions` tab. Search through the pages until you find the `Red Hat Satellite Infrastructure Subscription` subscription. Click the checkbox and make sure to add 1 to the `Quanity to Allocate` tab and then click `Submit`.

    - Again optional, I infact did not have to complete this step after uploading the manifest.

    **Enable Discovery Content**
    Now go to `Content->Red Hat Repositories` and search for `discovery`. Click on the `Red Hat Discovery 0 for RHEL 8 x86_64` repo and click the `+` for `x86_64` to enable it.

    We will also need to enable the following repos:
    - Red Hat Ansible Engine 2.8 for RHEL 8 x86_64 (RPMs)
    - Red Hat Enterprise Linux 8 for x86_64 - AppStream (RPMs)
    - Red Hat Enterprise Linux 8 for x86_64 - BaseOS (RPMs)

    These repos are required in order to get discovery-tools installed.

    **Sync the content**
    Now go to `Content->Products`, select all of the repos and sync them.

    **Create an Activation Key**
    Now go to `Content->Activation Keys->Create Activation Key`. Create the new key, then add the `Red Hat Satellite Infrastructure Subscription` to the key. Then click on `Repository sets` and make sure that all of the repos are enabled.

    # Configuring Discovery Server Container

    Now go to `Content->Products->Create Product`, name it `discovery-server-image` and hit create. Now go to the new product and go to the `Repositories` tab and click `New Repository`. Name the repo `redhat-registry` and change the type to `docker` then:

    - add `http://registry.access.redhat.com/` to `Upstream URL`
    - add `discovery-tech-preview/discovery-server-rhel8` to `Upstream Repository Name`
    - Enter your username & password to the Upstream Authorization section

    After you have created the new repository, go ahead an attempt to sync it.

    After it is synced, you can find where it is published by going to `Content->Container Image Tags->latest` and then click on the `Lifecycle Environments`.

    # Host Machine
    yum install -y http://<your_ip>/pub/katello-ca-consumer-latest.noarch.rpm
    subscription-manager register --org="Default_Organization" --activationkey="vagrant-key"