LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Enterprise Linux Forums > Linux - Enterprise
User Name
Password
Linux - Enterprise This forum is for all items relating to using Linux in the Enterprise.

Notices

Reply
 
Search this Thread
Old 01-11-2007, 11:16 AM   #1
chad504
LQ Newbie
 
Registered: Sep 2005
Distribution: FC5, FC6, RHEL 4
Posts: 10

Rep: Reputation: 0
Looking for Alternative to RHN Satellite Server basic functionality


Due to the cost of RHN satellite server, I'm looking for an alternative. The essential concepts that I am looking to duplicate are:

I'm looking for a way to export an RPM list (inc. version) from a system, and duplicate it. Including installation of updated RPMs. where the end result is an exact cloe of an existing system.

Using a kickstart server and some other tools this sounds realistic. However, I cannot figure out what to google to get started, and I figure someone has already accomplished some prtion of this.
 
Old 01-11-2007, 11:42 AM   #2
PatrickNew
Senior Member
 
Registered: Jan 2006
Location: Charleston, SC, USA
Distribution: Debian, Gentoo, Ubuntu, RHEL
Posts: 1,148
Blog Entries: 1

Rep: Reputation: 48
You're just looking for a red hat clone? People have those. Try CentOS and... oh well there's others but I forget them. I'm sure their fans will mention them here though.
 
Old 01-11-2007, 11:47 AM   #3
chad504
LQ Newbie
 
Registered: Sep 2005
Distribution: FC5, FC6, RHEL 4
Posts: 10

Original Poster
Rep: Reputation: 0
No, I have 128 Red Hat Licenses, I'm looking to duplicate the basic functionality, as outlined above, of the RHN Satellite Server. I need the ability to clone a system, duplicating the installed RPMs and versions. The cost to do this through a satellite server is prohibitive at the moment.
 
Old 01-11-2007, 11:54 AM   #4
PatrickNew
Senior Member
 
Registered: Jan 2006
Location: Charleston, SC, USA
Distribution: Debian, Gentoo, Ubuntu, RHEL
Posts: 1,148
Blog Entries: 1

Rep: Reputation: 48
Ah, you just want to clone the satellite server. Well, I'm afraid I'm quite useless there. The computers you are installing to, is it identical hardware? If so, you could set one system up exactly as you want it, with a clean install, the dd the character device of the hard disk into an image file, and have a quick script that would download the image file and dd it to the drive. Course, that's useless if the hardware isn't the same.
 
Old 01-11-2007, 12:04 PM   #5
chad504
LQ Newbie
 
Registered: Sep 2005
Distribution: FC5, FC6, RHEL 4
Posts: 10

Original Poster
Rep: Reputation: 0
The hardware may/not be the same. The architecture will stay constant. Essentially I will configure a new server for a development environment, and once the applications/systems need to progress through production I want to be able to take a snapshot of that servers RPMs, including updates, and reproduce to a new server possibly a second/third/forth... development server or prod.

I'm not looking for soem of the basic functionality that the satellite server provides.
https://www.redhat.com/rhn/rhndetails/architecture/
 
Old 01-17-2007, 01:47 PM   #6
jcims
LQ Newbie
 
Registered: Jan 2007
Posts: 2

Rep: Reputation: 0
Hi Chad,

Have you had any luck in this search? I'm trying to do the same thing for a customer of ours. They have a development and production environment, and i'm trying to come up with a way for them to install a set of packages in dev, test the setup, then copy that set of packages to production. (Edit: Right now they have ~250 updates waiting for them if they just do an up2date -u)

Seems like you could run rpm -qa on the 'source' box, tack on the architecture tags and then run 'up2date --get <filename>' on all of the lines of the output, but that seems super tedious and a bit risky. I couldn't find an rpm queryflag that provides the filename of the RPM that was installed, either.
 
Old 01-18-2007, 08:54 AM   #7
chad504
LQ Newbie
 
Registered: Sep 2005
Distribution: FC5, FC6, RHEL 4
Posts: 10

Original Poster
Rep: Reputation: 0
No I haven't yet. I have used the 'rpm -qa" > file, to get a base list. However you need to do a lot of editing to get it cleaned up enough to use. The sed script for that one was ugly. I also thought about having a system save the updated RPMs, and copying them to my kickstart server, to host the updates.

I'm still working on the basic concept, I'll keep you posted.
 
Old 01-19-2007, 09:18 AM   #8
jcims
LQ Newbie
 
Registered: Jan 2007
Posts: 2

Rep: Reputation: 0
Hey Chad,

This is the process i came up with, i haven't tested it yet tho:

rpm -q -a --queryformat="up2date --get %{NAME}-%{VERSION}-%{RELEASE}-{%ARCH}.rpm" | sort > end.sh

then copy it to the other system and

rpm -q -a --queryformat="up2date --get %{NAME}-%{VERSION}-%{RELEASE}-{%ARCH}.rpm" | sort > start.sh

diff start.sh end.sh | sed -e 's/> //' > get.sh

sh ./get.sh
rpm -Uvh *.rpm

That will get almost all of the packages updated, and you can hand-pick the rest.

Also

rpm -q -a --queryformat="%{NAME} %{VENDOR}" | grep -v "Red Hat"

will show all the non-redhat packages on the box


HTH
 
Old 01-22-2007, 03:59 PM   #9
chad504
LQ Newbie
 
Registered: Sep 2005
Distribution: FC5, FC6, RHEL 4
Posts: 10

Original Poster
Rep: Reputation: 0
Ok, I took your ideas and expanded to this:

Here is what I created to generate a "gold image":
#!/bin/bash
FILENAME="rpm-`uname -n`.sh"
FILENAME="rpm-master`date '%m-%d-%y-%H.%M'.sh"
echo $FILENAME
rpm -qa --queryformat 'up2date -d %{NAME}-%{VERSION}-%{RELEASE}-%{ARCH}.rpm\n' | sort >$FILENAME


Then this to run on the new system:
#!/bin/bash
START_FILENAME="rpm-`uname -n`.sh"
MASTER_FILENAME="rpm-master-<date>.sh"
MASTER_PATH="http://<kickstart-server>/kickstart/clone/"

echo $FILENAME
wget -P /root/ $MASTER_PATH$MASTER_FILENAME
rpm -qa --queryformat 'up2date -d %{NAME}-%{VERSION}-%{RELEASE}-%{ARCH}.rpm\n' | sort >/root/$START_FILENAME
#diff /root/$START_FILENAME /root/$MASTER_FILENAME | sed -e 's/>//' |sed '/</d;/---/d' >/root/host-update.sh
diff /root/$START_FILENAME /root/$MASTER_FILENAME | sed -e 's/>//' |sed '/</d;/*-/d'


Then I encountered the issue that you cannot pull down a specific RPM from RHN, that I could find. I could only do a get for the package name, minus any version/architecture info.
 
Old 01-22-2007, 04:07 PM   #10
chort
Senior Member
 
Registered: Jul 2003
Location: Silicon Valley, USA
Distribution: OpenBSD 4.6, OS X 10.6.2, CentOS 4 & 5
Posts: 3,660

Rep: Reputation: 69
Perhaps something like cfengine would be useful? It's a tool for synchronizing configurations across multiple systems. When I was in the hosting business was used it to push out html branding and minor software revisions to hundreds of different servers in our datacenters.
 
Old 01-24-2007, 11:28 AM   #11
chad504
LQ Newbie
 
Registered: Sep 2005
Distribution: FC5, FC6, RHEL 4
Posts: 10

Original Poster
Rep: Reputation: 0
I have found that I can do a up2date --get * it pulls down the headers, but not the associatedRPM files. I figured, that I could use this, and post them on my kickstart server. I have a valid number of licenses, for the updates, I'm looking for a way to do it locally, without 100 servers going out over my internet connection, plus the ability to clone a system, to a specific patch list and revision level.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
basic WINE functionality mr.v. Linux - Newbie 4 04-29-2011 02:59 AM
LXer: Review: Conglomerate XML Editor reaches basic functionality LXer Syndicated Linux News 0 01-17-2006 05:46 AM
No touchpad features beyond basic ps/2 functionality tisource Linux - Laptop and Netbook 1 02-27-2005 03:15 PM
New to RHN: Can't get the network functionality to connect to my Win2K domain dwoeltje Linux - Newbie 0 06-25-2004 09:26 AM
? on cloning errata for RHN Satellite Server dmorgan Red Hat 1 04-08-2004 09:30 PM


All times are GMT -5. The time now is 04:09 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration