C4X2
Mission Specialist
Mission Specialist
  • 519 Views

Re: RHA Labs as VMs?

okay i got it, thanks for your time : ) 

0 Kudos
Reply
Loading...
Tracy_Baker
Starfighter Starfighter
Starfighter
  • 671 Views

Re: RHA Labs as VMs?

Second question: Anyone try getting a DO180 up and running this way?

Program Lead at Arizona's first Red Hat Academy, est. 2005
Estrella Mountain Community College
0 Kudos
Reply
Loading...
Tracy_Baker
Starfighter Starfighter
Starfighter
  • 579 Views

Re: RHA Labs as VMs?

Here my written step-by-step guide, which seems to work. Note that the RH134 8.2 setup tries to do DNS resolution on a number of bastion*.example.com FQDNs when using the rht-f0finish command on foundation0 and rht-verify-classroom on classroom. It takes a LOOOONG time to get past this. I and I'm not certain why it is doing this (any help?).

-----

1) Convert .img to .vmdk: qemu-img convert -O vmdk <src.img> <dest.vmdk>
Get the utility here: https://cloudbase.it/qemu-img-windows/

2) Create blank VM in VMware (I'm using Workstation 15.5 Pro):
-- Hardware = Workstation 10.x
-- I will install the operating system later
-- Linux (Red Hat Enterprise Linux 7 64-bit)
-- Give it a name
-- (2) CPUs
-- 16G mem (8 will do)
-- Use host-only networking
-- LSI Logic (recommended)
-- SCSI (Recommended)
-- Create a new virtual disk
-- at least 105G of HDD space - store as single file
-- NEXT then Finish

3) Edit virtual machine settings
-- Processors: turn on Virtualize Intel VT-x/EPT or AMD-V/RVI
-- Network Adapter (existing): change to VMnet3
-- add second Network Adapter, set to VMnet4
-- add second HDD (SCSI), point it to the .vmdk file (Use existing virtual disk),
   Keep Existing Format

4) Start VM
-- change BIOS to point to second disk, if need be (you have to be very, very fast to hit F2
and the cursor must be in the VM window. If you miss it, you have to reboot and try again)

5) install course
-- at boot: prompt: f0 rh124 (or rh134, rh294)

6) during RHEL installation
-- set timezone (There may still be a bug where, if it starts in New York (US EST/EDT), you have to choose a different time zone, then choose New York)
-- Begin Installation button
-- wait a good long while, there will be some GUI stuff, then some CLI stuff, then the GUI again.
-- Press the Reboot button

7) Change the boot drive back to the first (105Gb) hard drive (Again, gotta be FAST to hit that F2 button)

8) when foundation0 boots up, log in as kiosk using redhat as the password

9) Open a terminal
-- (at this time, another course could be install using (as the root user):
rht-usb usbcourse <course>, where <course> would be rh124, rh134, or rh294

-- verify course: rht-verify-f0 (no FAILs should be seen, a WARNING on time is OK)

-- finish / start classroom: rht-f0finish
(again, wait a long while... this should have all PASS)
then it will download the images and start the other VMs (NOTE: I've noticed, twice now with RH134, that this step is trying to resolve a number of bastion*.example.com FQDNs -- like bastion16.example.com, bastion38.example.com, bastion91.example.com, etc. It takes up A LOT of time. They all error out. Once finished, it complains about DNS FAILing, but it works)

-- ssh into classroom, then rht-verify-classroom (this should have all PASS), then exit.
The bastion*.example.com thing happens here, too

10) At this point, you can remove the second HDD from the VMware VM (foundation0) as it is no longer needed -- especially if you are going to distribute this as a OVA/OVF file.

11) you can now go into the VMs and do the labs...

Program Lead at Arizona's first Red Hat Academy, est. 2005
Estrella Mountain Community College
Reply
Loading...
mehmetoren
Mission Specialist
Mission Specialist
  • 606 Views

Re: RHA Labs as VMs?

Foundation 0 (instructor vm) supports installation of up to 200 student kiosks and default number is 200. After initial setup of instructor vm, it will search for all the students kiosk defined by default number.

Probably your lab setup doesn't have an active link and a virtual network environment. Actually you don't need it for VMware workstation and standalone instructor vm and that's why it takes too long to check FQDN because there isn't any response from the network I guess.

To prevent FQDN check for 200 VMs and shorten discovery time, please try to run 'rht-setmaxstations 1' before running 'rht-f0finish'.
This command will limit the number of kiosks to 1. Of course, you can specify another number up to 200 according to your needs as well.

0 Kudos
Reply
Loading...
ralii
Starfighter Starfighter
Starfighter
  • 598 Views

Re: RHA Labs as VMs?

Hi Tracy,

Nice detailed instructions!!

So, a couple of thoughts for everyone to consider.

In step 5, when creating a VM, I would change "f0 rh124" to "standalone rh124" assuming you do not need to support an "actual classroom". This will simplify your networking and potential "damage" that can confuse the named process on foundation0/classroom. Consequently, in step 3 you will only need "one NIC" which is connected to the "outside/upstream" world (perhaps DNATed like a virbr0 in RHEL).

In step 6, the timezone problem should be gone (for US/Eastern) with a funky hack that I did to the kickstart before release.

In step 9, the failure/timeout of the latter bastionX is likely a problem with the "resolv.conf" or "named" process on the classroom VM. Confirm that the named process is running on the classroom VM. I would be curious to know if curriculum broke something in there.... Technically, both RH124 and RH134 are running the same VM image for classroom, so I am a little surprised that you are not seeing the failure with RH124 too.

--Rob
Retired Highlander of UCF

Reply
Loading...
Tracy_Baker
Starfighter Starfighter
Starfighter
  • 585 Views

Re: RHA Labs as VMs?

Thanks @ralii!

An update:

In step 5, when creating a VM, I would change "f0 rh124" to "standalone rh124" assuming you do not need to support an "actual classroom". This will simplify your networking and potential "damage" that can confuse the named process on foundation0/classroom. Consequently, in step 3 you will only need "one NIC" which is connected to the "outside/upstream" world (perhaps DNATed like a virbr0 in RHEL).

I've done a standalone installation (because, you are right, that's all I need) a few times now and have written up an installation "guide". In it I've use hardware 15.x, NVMe, ...

In step 6, the timezone problem should be gone (for US/Eastern) with a funky hack that I did to the kickstart before release.

This is true -- the time zone is not set during the installation of the OS.

In step 9, the failure/timeout of the latter bastionX is likely a problem with the "resolv.conf" or "named" process on the classroom VM. Confirm that the named process is running on the classroom VM. I would be curious to know if curriculum broke something in there.... Technically, both RH124 and RH134 are running the same VM image for classroom, so I am a little surprised that you are not seeing the failure with RH124 too.

classroom is reachable, I can ssh into it from workstation. While there, I checked named and resolv.conf, as seen here:

1.JPG


It seems to me that, if it (RH124 / RH134) installed without the bastion*.example.com "issue," it will work. Even so, you may have to let the system settle down after using rht-vmctl start all -- because access to the bastion, workstation, servera, and serverb VMs is not immediately available. This is true even using a "standalone" installation.

Program Lead at Arizona's first Red Hat Academy, est. 2005
Estrella Mountain Community College
Reply
Loading...
Tracy_Baker
Starfighter Starfighter
Starfighter
  • 582 Views

Re: RHA Labs as VMs?

So here's an update set of instructions -- for standalone mode. Again, I'm using VMware Workstation 15.5 Pro

1) Convert .img to .vmdk: qemu-img convert -O vmdk <src.img> <dest.vmdk>
Get the utility here: https://cloudbase.it/qemu-img-windows/

2) Create blank VM in VMware (I'm using Workstation 15.5 Pro):
-- Hardware = Workstation 10.x [I've also used 15.x]
-- I will install the operating system later
-- Linux (Red Hat Enterprise Linux 8 64-bit)
-- Give it a name
-- (2) CPUs
-- 16G mem (8 will do)
-- 1 NIC, on VMnet3
-- LSI Logic (recommended)
-- SCSI (Recommended) [I've also used NVMe]
-- Create a new virtual disk (stored as a single file)
-- minimum 105Gb
-- NEXT then Finish

3) Edit virtual machine settings
-- Processors: turn on Virtualize Intel VT-x/EPT or AMD-V/RVI
(I also turned on Virtualize IOMMU (IO memory management unit))

-- add second HDD (SCSI), point it to the .vmdk file (Use existing virtual disk), Keep Existing Format

4) Start VM
-- (if needed) change BIOS to point to second disk, if need be (you have to be very, very fast to hit F2 and the cursor must be in the VM window. If you miss it, you have to reboot and try again)

5) install course
-- at boot: prompt: standalone rh124 (or rh134, rh294)

6) during RHEL installation
-- set timezone
-- Begin Installation button
-- wait a good long while, there will be some GUI stuff, then some CLI stuff, then the GUI again.
-- Press the Reboot button

7) Change the boot drive back to the first (200Gb) hard drive (Again, gotta be FAST to hit that F2 button)

8) when foundation0 boots up, log in as kiosk using redhat as the password

9) Open a terminal -- install course as: standalone rh124
-- at this time, another course could be install using (as the root user):
rht-usb usbcourse <course>, where <course> would be rh124, rh134, or rh294

-- verify course: rht-verify-f0 (no FAILs should be seen, a WARNING on time is OK)

-- finish / start classroom: rht-f0finish
(again, wait a long while... this should have all PASS) then it will download the images and start the other VMs

-- ssh into classroom, then rht-verify-classroom (this should have all PASS), then exit.

10) At this point, you can remove the second HDD from the VMware VM (foundation0) as it is no longer needed -- especially if you are going to distribute this as a OVA/OVF file.

11) you can now go into the VMs and do the labs...

Program Lead at Arizona's first Red Hat Academy, est. 2005
Estrella Mountain Community College
0 Kudos
Reply
Loading...
atopa
Cadet
Cadet
  • 558 Views

Re: RHA Labs as VMs?

I would add the following command to point 9.

dnf install -y open-vm-tools-desktop xorg-x11-drv-vmware

This will add display autoresize and clipboard functionality to Foundation0.

0 Kudos
Reply
Loading...
Tracy_Baker
Starfighter Starfighter
Starfighter
  • 544 Views

Re: RHA Labs as VMs?

I suppose you could do this if using VMware. What happens if you are using different hypervisor?

Program Lead at Arizona's first Red Hat Academy, est. 2005
Estrella Mountain Community College
0 Kudos
Reply
Loading...
atopa
Cadet
Cadet
  • 536 Views

Re: RHA Labs as VMs?

I have created Foundation0 in VMware WS, Virtualbox and KVM/QEMU. VMware WS version uses open-vm-tools package. Virtualbox version have own driver but this needs kernel-header, kernel-devel, gcc and libelf-devel packages for building driver.

KVM/QEMU version works without any changes. It is also fast with virtio-drivers.

0 Kudos
Reply
Loading...
Join the discussion
You must log in to join this conversation.