[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 249
  • Last Modified:

s there any file which lists all RPM packages installed ?

I installed Mandriva Linux and I have done many installations using urpmi command. Due to corruption, now my Mandriva Linux became unbootable (I cannot boot it)... How can I see what are the RPMs that are installed ? Is there any file which lists all RPM packages installed ? After I boot Knoppix Live CD, I would like to review all the additional applications that were installed in my corrupted Mandriva Linux , before I format the HDD in order to re-install Mandriva Linux (I will repeat all urpmi names).
Thanks in advance.  
Regards.
0
asgarcymed
Asked:
asgarcymed
2 Solutions
 
owensleftfootCommented:
If you boot from an rpm based live cd you could get the list with "rpm ---dbpath /path-to-rpm-database-on-mandiva -qa" (without the quotes) If you add > myfile.txt on the end of the command it will put the list in myfile.txt.The usual path of the rpm database is /var/lib/rpm but you will have to adjust this for the path of the mounted harddrive. Does mandiva not have a live cdrom?
0
 
alcomancerCommented:
/var/lib/rpm/packages should do it, assuming that the copy of rpm is unmodified.

Good luck.
0
 
nedvisCommented:
How can I see what are the RPMs that are installed ?

In terminal window ( command line shell/Linux Console ) just type:
rpm -qa | more

**************************** explanation of command *********************************
In case you are unfamiliar with the command line, let me break this command down. rpm is the command name. It tells the computer you want to run the rpm program. In unix, the set of letters following a dash (-) is called an option or switch. The -q tells rpm you want the query operation. The following a in the -qa is a modifier for the query option which tells rpm you want to list all the packages. The | more part of the above command is not a feature of rpm at all. It is a standard unix way to show output one page at a time.
More at : http://www.tfug.org/helpdesk/linux/rpm.html
*************************************************************************************

nedvis
0
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

 
asgarcymedAuthor Commented:
Is it possible to get a description of each rpm package that is installed (rather than only listing each rpm package's names) ?
0
 
nedvisCommented:
command for that is :

rpm  -q   -i    <pachage name>
or
rpm -q  --info <package name>

e.g. :   rpm -q  --info package-1.0.3.i386.rpm
*******************************************************************************************
Package query option  -i, --info displays package information, including name, version, and description.
*******************************************************************************************
You might wish to use Mandriva kpackager which will read rpm headers for you and extract informations you are looking for ( rpm package summary/description )
good luck
nedvis
0
 
asgarcymedAuthor Commented:
Thank you.
Regards.
0

Featured Post

[Webinar] Cloud and Mobile-First Strategy

Maybe you’ve fully adopted the cloud since the beginning. Or maybe you started with on-prem resources but are pursuing a “cloud and mobile first” strategy. Getting to that end state has its challenges. Discover how to build out a 100% cloud and mobile IT strategy in this webinar.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now