So after operating system installation is complete, you'll want to plan to create at least one repository for installation of additional packages. Now if you're using the Red Hat satellite subscription service, much of this will be done for you already. Now that service is beyond the scope of this class. But there's a lot of good information available from Red Hat on their satellites service. But I understand that you want to understand the concepts that I'm going to go over for creating your own repository, regardless of whether you use subscription service or not, you probably will. So you're going to want to create a basic repository using the RHEL installation media, at least as practice. Now the graphics to follow show the steps to create such a repository. This process requires that the Red Hat Linux installation media, this is the example that I'm using. It requires that the Red Hat Linux installation media is loaded in an optical device on the Linux system. This would be the case if the operating system was installed from a virtual media library, in a VIO server on a power system server. Something you might do, and something I'll cover later in another video. So the first step is to create a mount point for the optical media. In the second step, you mount the optical drive containing the Red Hat installation media. The third step imports the GPG key for signature verification. Now in the fourth step, you create the repository file in the etc/yum.repos.d directory. I'm going to call this file RHEL-disk.repo, but you can call it whatever makes sense for you. If it's not a Red Hat installation media, if it's some other media, you would want to name it appropriately. Now there are two repositories in RHEL 8. One's called base OS, and one's called App stream. This is different from RHEL 7 and earlier, where all the content is in the same repository. So make note of that. You see we've created a stance in the file for both. Notice that when the repository source is a local file, the syntax is file, colon, slash slash, and then slash, and the location. Note there three slashes, file, colon, slash slash and then slash, and then the full path. Now check to see that yum can read your new repository file successfully using the command yum, space, list. Now we haven't talked about these commands yet, but we will, just give me a moment. Now, finally, perform a couple of installations to test that the repository is built correctly and can be used. Congratulations, you're ready to install all the system software that you're going to need, or mostly anyway. So that was one simple example of a yum repository. Let me address a couple of other repository examples before we move on to the installation commands. You can also source the images from an HTTP server on the network, as you see in the first example here. In the second example you see the addition of the GPG key entry to enable signature checking on the repository to ensure it's a trusted copy of the package. Then finally, let's talk in a little bit more detail about using yum to manage repositories. Like I said, I was going to address the yum command here. So the simplest command is yum space repolist, and that lists the repositories that are defined. Now this could throw errors if there are repositories that are inaccessible, maybe a network problem, maybe the repository address has changed, any number of things. But it's working against the repository files that you've configured in etc/yum.repos.d. Now to see a list of only the enabled repositories, this might eliminate some of those errors that you're seeing. You would add the argument enabled to the commands. So be yum space repolist space enabled. Now you could still see some errors, but it's less likely as long as the repository files are being well-maintained. That's the format of the command I use mostly. Now next, you might want to get details about a repository. Simply type in yum space repoinfo. Now this will give you details for all the repositories. Add the name of a repository to the command and you'll get the details for only that repository. Again, adding the enabled argument to the command displays details for only the enabled repositories. Also, yum, repolist minus V is another way to get this information plus a little extra. Finally, you might want to clean up the cached data being held for yum repositories, make it reread. To do that, run yum space clean with the option associated with the aspect of the cache that you want to clear. Now the quickest way to invalidate and reload the cache is by using the expired-cache argument.