Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Tue, 3 Apr 2012 23:14:09 -1000
From: cpb@....log2.net
To: owl-users@...ts.openwall.com
Subject: Re: Upgrading to current gives dependency problem after kernel upgrade and boot

On Wed, Apr 04, 2012 at 01:56:53AM +0400, Solar Designer wrote:
> On Tue, Apr 03, 2012 at 09:41:01PM +0000, Zenny wrote:
> > # rpm -Uvh ~build/RPMS/*.rpm
> If you're not into developing Owl, then I suggest that you only upgrade
> using our pre-built RPMs.

Hello again Zenny,

Thanks for trying the suggestions; while it is true that rpm cannot figure
how to accomplish what you (or the installworld script) are asking for, there
is reason to be optimistic (I'm saying RPM-hell is never as bad as DLL-hell).

Let me suggest you take a step back and use rpm to analyze the problem. When
you get an error like this:

> # rpm -Uvh ~build/RPMS/*.rpm
> error: Failed dependencies:
>   perl(Crypt::PasswdMD5) is needed by syslinux-perl-4.04-owl2
>   perl(Digest::SHA1) is needed by syslinux-perl-4.04-owl2

It is either because:
 1. You asked to upgrade (or remove) some perl modules WITHOUT also upgrading
    (removing) something which depends upon those modules ("syslinux").

    In this case RPM doesn't want to remove the perl modules because syslinux
    is "sitting" on them. You might be able to force it with --force, or you
    might be missing a syslinux....rpm file in your RPMS directory (so *.rpm
    did not include it).

OR

 2. You asked to upgrade (or install) some syslinux package WITHOUT also
    upgrading (installing) some perl modules which the new one needs.

    In this case RPM can't find a dependency, and so it doesn't want to install
    syslinux, because there's nothing for it to sit on. Again, you might be
    able to force it with --force, or you might be missing the perl module
    rpms you need to go with the syslinux (on the same rpm command line).

These two situations are very different, but I think RPM gives the same error
in either case. You can use the rpm options "-q" to query installed rpms, and
"-qp" to query an .rpm file you might have laying around. You can use
"--requires" and "--provides" to see what packages expect from the system and
what they provide to the system once installed. Finally, you can use
"--whatprovides" to search your installed system to locate which (installed)
rpm is the provider.

For example, on my system what does my current lftp package need?
  # rpm -q lftp --requires
  less  
  /bin/sh  
  (...more stuff...)
  libcrypto.so.5()(64bit)  
  libssl.so.5()(64bit)  

OK, and what package is it that is providing libssl to my lftp?
  # rpm -q --whatprovides 'libssl.so.5()(64bit)'
  openssl-0.9.7m-owl5

So I know these if either of these packages (lftp and openssl) undergo a
major change, that any "rpm -Uvh ..." commands will have to include both of
them in a single command line (transaction). In fact, the group extends beyond
just this pair of packages, but you get the idea.

Here's an rpm file I found on the internet. What will it provide if I'm able
to install it?
  # rpm -qp rcs-5.7-26.i686.rpm --provides
  rcs = 5.7-26

Hmm. Not much, just rcs. OK. Well, what else would I need to have already in
order to install it?
  # rpm -qp rcs-5.7-26.i686.rpm --requires
  rpmlib(PayloadFilesHavePrefix) <= 4.0-1
  rpmlib(CompressedFileNames) <= 3.0.4-1
  libc.so.6  
  libc.so.6(GLIBC_2.0)  
  libc.so.6(GLIBC_2.1)  
  libc.so.6(GLIBC_2.1.3)  
  libc.so.6(GLIBC_2.2)  
  libc.so.6(GLIBC_2.3)  
  rpmlib(PayloadIsBzip2) <= 3.0.5-1

OK, again, not much, just libc6 and some basic capabilities of RPM itself.

Using -q, -qp, --requires, --provides, and --whatprovides, you can study your
current installed system's web of RPM dependencies, and sniff out what your
~/build/RPMS/*.rpm packages need (wherever they came from)...

Of course, since you have the source code, you can just go read the specfile...
--info is also very, well, informative, though it does not show the requires
or the provides...oh well.

So good luck and report back when you figure it out (or post more details of
how you got to where you are). Again, I'm not an expert, and you've already
heard the advice to "just go binary", but this is the way I wish RPM deps had
been explained to me, so I hope I've given you some ideas about how to navigate
out of your rpm squeeze. As you can glean from my my deps above, I am running
Owl-stable not Owl-current, (for reasons you can probably guess...), as the
ABI breakage is pretty large, but that's what happens jumping over an entire
release of Redhat (4 to 6). The difference between -stable and -current right
now is large and going to get larger, so brace yourself (and consider just
grabbing the -current RPMs, if you are not into fiddling around with RPM),
but keep in mind that this is absolutely NOT DLL-hell, there is a way out,
and it can be discovered, although RPM may need some help and occasional
--force, and even the installworld script cannot take you from arbitrary A
to arbitrary B.

Best wishes, wish I could help more,

Chris Bopp
Honolulu, Hawaii

Powered by blists - more mailing lists

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.