RPM Community Forums

Mailing List Message of <rpm-users>

RE: Attempting to compile rpm5 for RH Linux EL5

From: Saravanan Shanmugham (sarvi) <sarvi@cisco.com>
Date: Fri 18 Sep 2009 - 18:11:38 CEST
Message-ID: <C6A1C20DB743364EB446E923B2229FEF097C293F@xmb-sjc-229.amer.cisco.com>
Separating the symbol files and into their own package is definitely in
the plans.

The question is the turnaround time between someone posting a traceback
on the web and a backend system translating the traceback with symbols.

One option is to have a filesystem where all the files have been
extracted and ready for translation. But can cost additional diskspace
which can add up in the long run.

If the RPMs are archived, the system would need to identify the RPMS
involved in traceback, download, extract them, do the translation, then
discard the extracted stuff.
This could takes some time to do, specially if you have to download the
whole RPM, and if you had to uncompress/untar each RPM in its entirity. 

From RPM, tar.gz or CPIO, this can be expenseive. As I understand it you
need to unzip and untar the file, piping it to a filter to get the
file(s) you want. 

XAR format maintains an index, that allows you to go to and extract a
specific file, and the individual files are compressed, as I understand
it, meaning the ones of interest can be extracted, which can be more
efficient.

At this point, I am just trying to understand/measure that cost
impact/tradeoff, and was looking to try these features.

Sarvi
 

-----Original Message-----
From: rpm-users-owner@rpm5.org [mailto:rpm-users-owner@rpm5.org] On
Behalf Of Jeff Johnson
Sent: Friday, September 18, 2009 5:34 AM
To: rpm-users@rpm5.org
Subject: Re: Attempting to compile rpm5 for RH Linux EL5


On Sep 18, 2009, at 2:04 AM, Saravanan Shanmugham (sarvi) wrote:

> Thanks. I was able to get it compiled and installed.
>
> I am proposing the use of RPM5 for package management internally. One 
> point of interest to me in RPM5 is the use of XAR format, and more 
> specifically the option of being able to extract specific files from 
> within the XAR archive without having to untar/extracting everything.
> Atleast that's what the xar wiki page claims.
>

You can extract specific files from any archive format, including
cpio/tar/xar, rather easily.

> We need a way to be able to extract specific executables and libraries

> from a specific version of the build, from its archived RPMs, on 
> demand, to help decode a crash or traceback.
>

So you would seem to want debugging symbols. What is more commonly done
is to split the symbols from the executable/library and put into a
separate -debuginfo package.

GDB then loads the detached symbols.

> So far, I haven't been able to figure out the RPM5 option or XAR 
> option that allows me to do extract a specific file or list of files.
>

For cpio payloads it starts with
	rpm2cpio foo*.rpm | cpio -itv
to display the files in a payload. Then one adds logic (described in
"man cpio") to select which files you want.

> Is there such an option. If not how easy do you think it is to 
> implement such an option, if we can help.
>

Each archive format has a different selection process. But rpm2cpio is
used to seek to the start of the payload.

73 de Jeff
______________________________________________________________________
RPM Package Manager                                    http://rpm5.org
User Communication List                             rpm-users@rpm5.org
Received on Fri Sep 18 18:14:21 2009
Driven by Jeff Johnson and the RPM project team.
Hosted by OpenPKG and Ralf S. Engelschall.
Powered by FreeBSD and OpenPKG.