LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Setting up YUM local repository using Apache (https://www.linuxquestions.org/questions/linux-newbie-8/setting-up-yum-local-repository-using-apache-863324/)

vintage2010 02-17-2011 08:58 AM

Setting up YUM local repository using Apache
 
Before posting I viewed the similiar threads but didn't find my problem --

so here goes...

I am setting up a local YUM repository in which I will have one computer accessing the RHN network and the clients will pull the updates from that server.

I have seven linux computers that I need to have access this repo server via apache.

I called Red Hat support and this what they told me to do....

On the YUM Repo Server -
> go to /etc/httpd/conf
> copy original to something else (you name, just save the original)
>edit the httpd.conf file
> add in ServerAdmin root@10.24.79.195
>add in ServerName 10.24.79.195 (ip of repo server)
> keep DocumentRoot "/var/www/html"
> save and close

> service httpd restart
>cd /var/www/html/yum/rhel5
> run the createrepo .
> run the yum clean all

On RHEL client
> create a ".repo file" -- EX: my.repo
> file @ /etc/yum.repos.d/my.repo
> Contents of "my.repo
[rhel5-server]
name=RHEL 5.5 Server Repository
baseurl=http://10.24.79.195/var/www/htmlyum/rhel5
enabled=1
gpgcheck=0

> save and close
> run the yum list command.

My issues --
When I run the yum list command on the client side -- it retrieves packages
but what do I do after that??

When I run the yum update -- I get this

Loaded plugins: rhnplugin, security
Bad id for repo: rhel 5 , byte = 4
This system is not registered with RHN.
RHN support will be disabled.
Setting up Update Process
No Packages marked for Update

Another issue --- I have no idea how to configure apache -- when I was on the phone with Red Hat we went so fast that I couldn't write down everything.

Any helpful solutions?

szboardstretcher 02-18-2011 08:57 AM

Well, it sounds like it is working, and your system is up to date.

If you'd like to test to see that yum is in fact able to pull something from your repo, then try:

Code:

yum install screen
which will install the "screen" program

then, since this is a test, if you do not want that package,

Code:

yum erase screen

vintage2010 02-21-2011 10:56 AM

Another update --- then I will close.

I had spaces in my config files and had the wrong IP address. I haven't been able to test yet but I have opened a case with Red Hat.
I'm just not getting it -- the YUM repository setup.

I will close this post -- Thank you for the information "szboardstretcher" ;)

szboardstretcher 02-21-2011 11:02 AM

Quote:

Originally Posted by vintage2010 (Post 4266007)
Another update --- then I will close.

I had spaces in my config files and had the wrong IP address. I haven't been able to test yet but I have opened a case with Red Hat.
I'm just not getting it -- the YUM repository setup.

I will close this post -- Thank you for the information "szboardstretcher" ;)

Good luck.

If you could update this when you find an answer, I'd be interested to find out what the issue was.


All times are GMT -5. The time now is 04:47 PM.