After installing RHEL the first steps that you will want to accomplish is registering your system with Red Hat, attaching your system to the appropriate subscription, and running YUM update to bring your system up to date.  If this is within a corporate network many times you’ll run into the problems of not being able to connect to the Red Hat network until you make some configuration changes both within Subscription Manager, and YUM.

The steps required to get this setup are fairly easy, however if you’ve never had to do it before might be difficult to locate.

First in order to register the system with Red Hat you’ll want to run the subscription-manger config command to set your company proxy, and port number.  You’ll want to use the command:

You can then register your system with the command:

If you leave off the username and password options you will just be prompted to answer these connections the first time you are connecting before registration completes.

Next we can attach our system to the appropriate subscription.  We first need to view what subscriptions we have available:

 

Available Subscriptions

Look through the various subscriptions you have and make note of the pool ID for the one that matches your system.  If all your subscriptions are the same you can use the auto option, however many companies have a variety of subscriptions so you’ll want to have control over which one you connect to.  Run the following command to attach to the required pool:

 

Once this has completed you are now ready to update your system with YUM.  However you’ll need to adjust the configuration of /etc/yum.conf and add the line proxy=webproxy.l3pdu.com:8080 to the last line in the configuration so that YUM will work via your company proxy.

This can be done with VIM by typing the command:

 

/etc/yum.conf

Edit the file, and then save the configuration.

 

 

 

You can then run your first update on the system to bring everything up to date with the command:

I like running it without the -y option so I can see what is all going to be installed and have the option of choosing no if needed for any reason.  However if you don’t want to have to do this, just add -y to the command and all the updates will be installed and updated automatically.

And that’s pretty much it.  There are other configuration options in subscription-manager, such as telling it to stay on a current version of RHEL.  For instance if for some reason you need to always be at 7.2 and don’t want to upgrade to 7.3 or any other versions later on you can set your release with the command:

There are other options you can view by double tabbing either after the subscription-manager command, or after you have typed in an option such as config, release, list, etc.  That will show you all the — options that are available to you as well.

subscription-manager options

 

 

 

Hopefully you have found this short tutorial helpful.  Feel free to ask me any questions you may have.

Leave a Reply

Your email address will not be published. Required fields are marked *

six + three =