[rhn-users] Determining whether RHEL4 is registered?
Phil Edwards
phil at linux2000.com
Wed Nov 7 13:29:12 UTC 2007
Timothy Kallinis wrote:
> Hi, I have an interesting dilemma regarding registration with up2date in
> RHEL4. I have a yum (yum-arch) repo I want to use under RHEL4 with
> up2date. However, if a system is not registered, I need to comment out
> the following line:
>
> up2date default
>
> in /etc/sysconfig/rhn/sources
>
Hi Timothy:
I had a slightly similar issue to deal with. As I work for an
organisation which deploys an average of 3 - 5 new servers a week, my
solution may not be wholly appropriate for you, but see what you think:
I copied the contents of the RHEL4 U4 install media onto a server which
could be accessed within our RFC1918 address space using FTP. I
converted this into a yum repository by running the normal yum-arch and
createrepo commands against the directory tree.
I built and installed yum and its associated dependencies from their
various source tarballs. Once I had this process nailed, I generated a
bunch of RPMs to allow any RHEL4 machine to have yum installed
independently of up2date.
Finally, I generated a 'noarch' RPM which contains nothing else apart
from a /etc/yum.repos.d config file which points at the repo I created
on our FTP server.
My base RHEL4 install is extremely minimal and includes only what is
absolutely necessary to get a new server up and running as quickly as
possible. This is used as a base template for live server deployments.
It also has my yum RPMs installed.
Our server deployment process becomes quite simple at this point. We
copy the 'template' install onto the destination hardware and power it
up. At first boot, a provisioning script runs which grabs an XML config
from a central server and then runs a series of yum commands in order to
install any additional software which may be required. This would
typically be Apache/MySQL for a web server, Postfix or sendmail if the
box is to be used as a mail server, etc, etc.
Since the yum install doesn't care about the servers RHN registration
status, the server can stay on our private IP address space while it is
being built, and while any additional software is installed. Once it is
put onto a real internet IP, it can be registered with RHN and have the
latest updates applied automatically.
--
Regards
Phil Edwards
Brighton, UK
More information about the rhn-users
mailing list