LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 10-02-2005, 09:06 AM   #1
TruongAn
Member
 
Registered: Dec 2004
Location: Vietnam (Việt Nam)
Distribution: Gentoo (desktop), Arch linux (laptop)
Posts: 728

Rep: Reputation: 33
How can I get a list of software that was installed via rpm


Hi all.
I 've been using rpm to install software for years.
But a funny things is up to now, I still don't know how
to get a list of installed program.
I maintain this list myself. Take not whenever I installed
something, so I can remove these software.
And now, I lose my list and there is some software
which name I cann't remember.
I think rpm must have a list like this, and how can I get this
list. Please show me.
 
Old 10-02-2005, 09:10 AM   #2
reddazz
LQ Guru
 
Registered: Nov 2003
Location: N. E. England
Distribution: Fedora, CentOS, Debian
Posts: 16,298

Rep: Reputation: 77
Checking out the rpm manual would have been a good start. The command to check all installed packages is
Code:
$rpm -qa
The list will be very long so you may need to pipe the output to less e.g.
Code:
$rpm -qa | less
To find out if a specific package is installed you would do
Code:
$rpm -qa | grep -i nameOfPackage
You can also use a GUI like Synaptic, YAST and rpmdrake.
 
Old 10-02-2005, 10:15 AM   #3
muddywaters
Member
 
Registered: May 2005
Location: Winnipeg, Canada
Distribution: mostly mepis
Posts: 427

Rep: Reputation: 30
Here's a nifty trick I found somewhere.
Open a terminal and key in this:
rpm -qa > installed-programs
This will create a file in your home directory listing the programs.
 
Old 10-03-2005, 09:47 AM   #4
TruongAn
Member
 
Registered: Dec 2004
Location: Vietnam (Việt Nam)
Distribution: Gentoo (desktop), Arch linux (laptop)
Posts: 728

Original Poster
Rep: Reputation: 33
Question Is there any way to obtain the date of the installion

The list come from rpm -qa take 5 minutes to display. Therefore, it is so hard
to read such a long list. Is there any way to obtain the date of the isntallion so
I can filtered the list to find out the package I want?
 
Old 10-03-2005, 10:41 AM   #5
evans0409
Member
 
Registered: Sep 2005
Location: US
Distribution: FC 4
Posts: 39

Rep: Reputation: 15
Re: Is there any way to obtain the date of the installion

Quote:
Originally posted by TruongAn
The list come from rpm -qa take 5 minutes to display. Therefore, it is so hard
to read such a long list. Is there any way to obtain the date of the isntallion so
I can filtered the list to find out the package I want?
use

Code:
 rpm -qa --last | less
to see the installed packages in reverse chronological order. also the man page for rpm is very informative and includes many examples of the kinds of queries you are asking about. check it out.
 
Old 10-03-2005, 10:43 AM   #6
muddywaters
Member
 
Registered: May 2005
Location: Winnipeg, Canada
Distribution: mostly mepis
Posts: 427

Rep: Reputation: 30
If you enter 'man rpm' in a terminal a list of options can be found for this command. The option needed for this is 'last'.
So 'rpm -qa -last' should make a list in cronological order.
Edit: Beat me to it! I really need to start typing with 2 fingers.

Last edited by muddywaters; 10-03-2005 at 10:45 AM.
 
Old 10-04-2005, 02:08 AM   #7
TruongAn
Member
 
Registered: Dec 2004
Location: Vietnam (Việt Nam)
Distribution: Gentoo (desktop), Arch linux (laptop)
Posts: 728

Original Poster
Rep: Reputation: 33
Of course I have checked the man page but

If I found the information in the man page I wouldn't be here to talk.
The man page show me that there is -q option, but I don't see -qa option.
On the other hand, I cannot found any way to obtain the date of the installion.
Is it true that there is no way to get the date?
 
Old 10-04-2005, 03:10 AM   #8
reddazz
LQ Guru
 
Registered: Nov 2003
Location: N. E. England
Distribution: Fedora, CentOS, Debian
Posts: 16,298

Rep: Reputation: 77
I am not sure you can get the date of installation but there could be a way. Anyway, take a look at rpm.org, maybe you will find what you are looking for.
 
Old 10-04-2005, 07:13 AM   #9
homey
Senior Member
 
Registered: Oct 2003
Posts: 3,057

Rep: Reputation: 61
If you run the command: rpm --querytags it shows a list of querry options. One of those options is installtime.
Edit: The date format is obtained with :date
Code:
rpm -qa --qf 'Installed on %{installtime:date}     %{vendor}     %{name} %{version}-%{release}\n' | sort > list.txt

Last edited by homey; 10-04-2005 at 07:18 AM.
 
Old 10-04-2005, 11:04 AM   #10
evans0409
Member
 
Registered: Sep 2005
Location: US
Distribution: FC 4
Posts: 39

Rep: Reputation: 15
Re: Of course I have checked the man page but

Quote:
Originally posted by TruongAn
If I found the information in the man page I wouldn't be here to talk.
The man page show me that there is -q option, but I don't see -qa option.
On the other hand, I cannot found any way to obtain the date of the installion.
Is it true that there is no way to get the date?
Well, if you cannot extract the info you seek from the rpm man page (one of the most extensive man pages out there), perhaps this is not the OS for you. It seems that in addition to you inability to read the man page, you also cannot read the replies to your post, as several people suggested you use rpm -qa --last | less On my system, the first tolines of this output are

setools-gui-2.1.2-1.1 Mon 03 Oct 2005 03:41:14 PM PDT
selinux-policy-targeted-sources-1.27.1-2.3 Mon 03 Oct 2005 03:41:11 PM PDT
cpuspeed-1.2.1-1.23_FC4 Mon 03 Oct 2005 03:41:11 PM PDT

which part of this output confuses you about the date?

advice: don't get snippy in the forum when you know not about which you speak.
 
Old 10-04-2005, 11:53 AM   #11
TruongAn
Member
 
Registered: Dec 2004
Location: Vietnam (Việt Nam)
Distribution: Gentoo (desktop), Arch linux (laptop)
Posts: 728

Original Poster
Rep: Reputation: 33
OK. The problem is solved now.


Everything is alright now.
rpm -qa --last refused to work in kconsole terminal but it work if I start a virtual console instead of
Desktop environment. It think my problem is the lack of RAM, not rpm.
There must be something wrong with my mind these day.

Last edited by TruongAn; 10-04-2005 at 12:35 PM.
 
  


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
How to list installed software on Linux? mojavex Linux - Software 1 09-16-2005 05:40 PM
command to list rpm already installed? ginda Linux - Newbie 2 03-09-2005 06:25 AM
How do you list what software is installed? Tiyogi Linux - Software 5 04-22-2004 08:52 PM
Updating Software when it was originally installed by an RPM jmnovak Linux - General 1 08-22-2003 01:47 PM
How do I get a current list of RPM packages installed on my system? needamiracle Linux - General 1 12-06-2002 05:38 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 12:47 AM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration