Can RPM database be corrected manually?

Can RPM database be corrected manually?

Post by Mike Olive » Tue, 23 Apr 2002 18:11:09



[Linux RH6.2, kernel 2.4.18]

I've installed some stuff, e.g. the new kernel, via "make install"
from the source package rather than by RPM.  Now when I try to
add new stuff by RPM, it sometimes fails because it thinks the
kernel is too old, when in fact it's not.

I could use --nodeps, I suppose, but then I'm not sure what's
the point in using RPM at all.  What I'd like to do is set
RPM straight as to what I *actually* have installed, by changing
its database.  Can this be done?  How?

 
 
 

Can RPM database be corrected manually?

Post by peter pils » Tue, 23 Apr 2002 20:43:07



> [Linux RH6.2, kernel 2.4.18]

> I've installed some stuff, e.g. the new kernel, via "make install"
> from the source package rather than by RPM.  Now when I try to
> add new stuff by RPM, it sometimes fails because it thinks the
> kernel is too old, when in fact it's not.

> I could use --nodeps, I suppose, but then I'm not sure what's
> the point in using RPM at all.  What I'd like to do is set
> RPM straight as to what I *actually* have installed, by changing
> its database.  Can this be done?  How?

in fact : no

there is no way to scan your harddisk and update the rpm-database according
to the found files.

If you wan to use rpm you need to install everything with rpm.
There is ony possible trick that might work in your case:
install the needed dependency (kernel-package in your case) and then make
install again.

However I would not recommend this. In my daily work I install a
distribution with all common packages and then forget about rpm for the
rest of the machines live and install all manually. All this rpm-stuff
never has the version you need, the configuration you need and the latest
security-fixes you need.
If you compile things on your own you just know what you have and where you
have it.

peter

--
peter pilsl

http://www.goldfisch.at

 
 
 

Can RPM database be corrected manually?

Post by evan.co.. » Wed, 24 Apr 2002 00:32:39





>> [Linux RH6.2, kernel 2.4.18]

>> I've installed some stuff, e.g. the new kernel, via "make install"
>> from the source package rather than by RPM.  Now when I try to
>> add new stuff by RPM, it sometimes fails because it thinks the
>> kernel is too old, when in fact it's not.

>> I could use --nodeps, I suppose, but then I'm not sure what's
>> the point in using RPM at all.  What I'd like to do is set
>> RPM straight as to what I *actually* have installed, by changing
>> its database.  Can this be done?  How?

>in fact : no

Try rpm -rebuilddb
 
 
 

Can RPM database be corrected manually?

Post by AndrĂ© Kelp » Wed, 24 Apr 2002 02:05:57



Quote:> However I would not recommend this. In my daily work I install a
> distribution with all common packages and then forget about rpm for the
> rest of the machines live and install all manually. All this rpm-stuff
> never has the version you need, the configuration you need and the latest
> security-fixes you need.
> If you compile things on your own you just know what you have and where
> you have it.

Two simple tools:

http://asic-linux.com.mx/~izto/checkinstall/

http://freshrpms.net/apt/

this is all you will ever need to keep your System clean and up to date!

greetings Andr

 
 
 

Can RPM database be corrected manually?

Post by Mike Olive » Wed, 24 Apr 2002 04:08:55




> > [Linux RH6.2, kernel 2.4.18]

> > I've installed some stuff, e.g. the new kernel, via "make install"
> > from the source package rather than by RPM.  Now when I try to
> > add new stuff by RPM, it sometimes fails because it thinks the
> > kernel is too old, when in fact it's not.

> > I could use --nodeps, I suppose, but then I'm not sure what's
> > the point in using RPM at all.  What I'd like to do is set
> > RPM straight as to what I *actually* have installed, by changing
> > its database.  Can this be done?  How?

> in fact : no

> there is no way to scan your harddisk and update the rpm-database according
> to the found files.

That's not what I wanted to do.

I wanted to go into the DB like a bull in a china shop and edit it
by main force, so that it would subsequently know, if it knows
what's good for it, that my kernel is 2.4.18.

But I have no idea where the DB is stored or what its format is.
I can probably figure these things out, but I thought I'd ask
the experts first.

 
 
 

Can RPM database be corrected manually?

Post by Davi » Wed, 24 Apr 2002 10:20:53



> That's not what I wanted to do.

> I wanted to go into the DB like a bull in a china shop and edit it
> by main force, so that it would subsequently know, if it knows
> what's good for it, that my kernel is 2.4.18.

> But I have no idea where the DB is stored or what its format is.
> I can probably figure these things out, but I thought I'd ask
> the experts first.

I think the packages database is in:
/var/lib/rpm

But I have no idea as to how to edit it.

--
Confucius say: He who play in root, eventually kill tree.
Registered with the Linux Counter.  http://counter.li.org

 
 
 

Can RPM database be corrected manually?

Post by The Real Be » Wed, 24 Apr 2002 10:33:41






> >> [Linux RH6.2, kernel 2.4.18]

> >> I've installed some stuff, e.g. the new kernel, via "make install"
> >> from the source package rather than by RPM.  Now when I try to
> >> add new stuff by RPM, it sometimes fails because it thinks the
> >> kernel is too old, when in fact it's not.

> >> I could use --nodeps, I suppose, but then I'm not sure what's
> >> the point in using RPM at all.  What I'd like to do is set
> >> RPM straight as to what I *actually* have installed, by changing
> >> its database.  Can this be done?  How?

> >in fact : no

> Try rpm -rebuilddb

OK, since I'm a trusting soul I did that.  Now, what did I do and where did I do
it?  All the rpms in /var/lib/rpm have been rewritten, but that doesn't tell me
anything.  Any text files I can look at?  I'm curious to know just what I
have...  

xrpm used to work, but now it complains about some python inadequacy, and python
complains about some other inadequacy and the other inadequacy complains...

--
Cheers,
Bev    
+++++++++++++++++++++++++++++++++++++++++++
        Save the whales for dessert

 
 
 

Can RPM database be corrected manually?

Post by Rinaldi J. Montess » Wed, 24 Apr 2002 10:39:20







>> >> [Linux RH6.2, kernel 2.4.18]

>> >> I've installed some stuff, e.g. the new kernel, via "make install"
>> >> from the source package rather than by RPM.  Now when I try to
>> >> add new stuff by RPM, it sometimes fails because it thinks the
>> >> kernel is too old, when in fact it's not.

>> >> I could use --nodeps, I suppose, but then I'm not sure what's
>> >> the point in using RPM at all.  What I'd like to do is set
>> >> RPM straight as to what I *actually* have installed, by changing
>> >> its database.  Can this be done?  How?

>> >in fact : no

>> Try rpm -rebuilddb

> OK, since I'm a trusting soul I did that.  Now, what did I do and where did I do
> it?  All the rpms in /var/lib/rpm have been rewritten, but that doesn't tell me
> anything.  Any text files I can look at?  I'm curious to know just what I
> have...  

> xrpm used to work, but now it complains about some python inadequacy, and python
> complains about some other inadequacy and the other inadequacy complains...

This works here:  rpm -qa | sort | less

As to editing the contents, I have no idea.  Nor do I want one :-)

Rinaldi
--
Aint Nobody's Business If You Do

 
 
 

Can RPM database be corrected manually?

Post by The Real Be » Wed, 24 Apr 2002 14:03:54








> >> >> [Linux RH6.2, kernel 2.4.18]

> >> >> I've installed some stuff, e.g. the new kernel, via "make install"
> >> >> from the source package rather than by RPM.  Now when I try to
> >> >> add new stuff by RPM, it sometimes fails because it thinks the
> >> >> kernel is too old, when in fact it's not.

> >> >> I could use --nodeps, I suppose, but then I'm not sure what's
> >> >> the point in using RPM at all.  What I'd like to do is set
> >> >> RPM straight as to what I *actually* have installed, by changing
> >> >> its database.  Can this be done?  How?

> >> >in fact : no

> >> Try rpm -rebuilddb

> > OK, since I'm a trusting soul I did that.  Now, what did I do and where did I do
> > it?  All the rpms in /var/lib/rpm have been rewritten, but that doesn't tell me
> > anything.  Any text files I can look at?  I'm curious to know just what I
> > have...

> > xrpm used to work, but now it complains about some python inadequacy, and python
> > complains about some other inadequacy and the other inadequacy complains...

> This works here:  rpm -qa | sort | less

> As to editing the contents, I have no idea.  Nor do I want one :-)

"Ideas hurt and thinking makes my brain itch."

Thanks, now I have a handy list.  Way longer than I expected.

--
Cheers,
Bev  
++++++++++++++++++++++++++++++++++++++++++++++++++++
              Non illegitimi carborundum.

 
 
 

Can RPM database be corrected manually?

Post by Vladimir Florinsk » Wed, 24 Apr 2002 16:17:47




>> there is no way to scan your harddisk and update the rpm-database
>> according to the found files.

> That's not what I wanted to do.

> I wanted to go into the DB like a bull in a china shop and edit it by
> main force, so that it would subsequently know, if it knows what's good
> for it, that my kernel is 2.4.18.

> But I have no idea where the DB is stored or what its format is. I can
> probably figure these things out, but I thought I'd ask the experts
> first.

There is documentation on this (the database format and the librpm
interface). Red Hat has the book on their web site. But this is the wrong
approach and goes against the philosophy behind package management.

The correct method is to create the kernel rpm. This will not be easy for
a big package such as the kernel. Again, RedHat's book tells how to
prepare the spec file, etc.

I would suggest an easier option though: upgrade to RH 7.2 or another
modern distribution. This will install a 2.4.9 (or later) kernel which
should be good enough for you.

--

Vladimir

 
 
 

Can RPM database be corrected manually?

Post by Mike Olive » Fri, 26 Apr 2002 14:56:37



> I would suggest an easier option though: upgrade to RH 7.2 or another
> modern distribution. This will install a 2.4.9 (or later) kernel which
> should be good enough for you.

But that kernel wouldn't have my customizations, right?

Besides I never managed to get 7.0 working, so I'm reluctant to
touch 7.x in general, especially after seeing the stuff about
it running slow on AMD machines.

 
 
 

Can RPM database be corrected manually?

Post by Vladimir Florinsk » Sat, 27 Apr 2002 03:16:41




>> I would suggest an easier option though: upgrade to RH 7.2 or another
>> modern distribution. This will install a 2.4.9 (or later) kernel which
>> should be good enough for you.

> But that kernel wouldn't have my customizations, right?

What are these customizations you find so important? Building kernels is
not a useful excersize in itself and there is usually no advantage of
doing it. If you need a new driver, build it separately.

In any case you can build the kernel from the kernel-source RPM, or from
kernel.org, whatever. You can have as many kernels installed at the same
time as you like. But you should have at least one 2.4 kernel RPM
installed to get rid of your dependency problems.

Quote:> Besides I never managed to get 7.0 working, so I'm reluctant to touch
> 7.x in general, especially after seeing the stuff about it running slow
> on AMD machines.

Red Hat versions X.0 are usually of inferior quality, but X.2 are good. As
far as "running slow", you seem to be confused here.

--
Vladimir

 
 
 

Can RPM database be corrected manually?

Post by Ken Bloo » Sat, 27 Apr 2002 16:08:25




>>[Linux RH6.2, kernel 2.4.18]

>>I've installed some stuff, e.g. the new kernel, via "make install"
>>from the source package rather than by RPM.  Now when I try to
>>add new stuff by RPM, it sometimes fails because it thinks the
>>kernel is too old, when in fact it's not.

>>I could use --nodeps, I suppose, but then I'm not sure what's
>>the point in using RPM at all.  What I'd like to do is set
>>RPM straight as to what I *actually* have installed, by changing
>>its database.  Can this be done?  How?

> in fact : no

> there is no way to scan your harddisk and update the rpm-database according
> to the found files.

> [snip]

> However I would not recommend this. In my daily work I install a
> distribution with all common packages and then forget about rpm for the
> rest of the machines live [snip]

unless you use checkinstall, as I do, so everything installed on my
system is an RPM. It turns out to be pretty convenient because if I
install something once, then the next time I reinstall the machine I
might want to install the same software again.
 
 
 

1. Recovering the /var/lib/rpm RPM database?

Hey,

I lost my RPM database (the directory /var/lib/rpm). Don't ask me
how....

Does anybody have any suggestions on how to build a new one without
having to install all packages again. Maybe somebody wrote a tool that
compares SPEC files with existing files on your computer and updates the
database for you if the correct file are found??

cheers,

Edgar

--
Edgar Vonk

2. Allowing access to internal Printer

3. Incorporating RPM into RPM "database (depot?)"

4. bus error - Solaris 2.6

5. RPM-database & non-rpm packages

6. diskless workstation dual boot

7. manually edit ldif database file

8. programmer wanted - Vancouver, Canada

9. how do I update the RPM DB for manually installed packages?

10. Am I correct?

11. Am I in the correct newsgroup?

12. "who am i" doesn't give correct info

13. Qddb Database Applications (Corrected)