Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

what, exactly, does rpm -i do?

Status
Not open for further replies.

iggystar

IS-IT--Management
Jul 12, 2001
126
US
if I use rpm to "install" something, what exacly happens?

Where does the file go that I just "installed" go?

Why doesn't RPM tell me? Why doesn't it ask me where I want it? Why does it feel like I'm only 1/2 done even though rpm is supposed to "install" for me?
 
try
man rpm
and U will know
try rpm -iv and U will see ;-)
Do U know, that -v is for verbose?
rpm -i extracts the files from archive and runs the install script.
bubak
 
I have never encountered a single time where rpm -i does anything.

It certain doesn't run any install script that I've ever seen. Is that functionality dependant on the creator of the RPM file?

If you think I'm lying go to rpmfind.net and download the rpm file for Apache for RH 7.1 and run rpm -i apache.rpm (or whatever the exact filename is)
it is over in 1/10000th of a second and doesn't do a darn thing as far as I can tell.

The man page for RPM is horrible. All it says about RPM -i is that "This installs a new package". That's an exact quote. So my question of what EXACTLY that means is not an indication that I didn't read the man page. It's an indication that the man page is bad.
 
I tried your suggestion of using rpm -iv and this is what the total output was:
apache-1.3.19-5
thats it.

I'm not sure what that's supposed to be telling me. Is this another example of amazingly obtuse unix documentation? If -v is verbose I wonder what terse gets me? A punch in the gut perhaps.

I may have to become a crusader for OpenSource Docs. These guys don't know how to write. I blame the colleges. :-D

Good thing getting apache going is just something I'm doing for kicks...if I had a deadline I'd be doomed. :)
 
Hello,
rpm -i will install all files contained in the RPM regardless of output to console. Its magic, just accept it. I believe the rpm will install config info in /etc/httpd, and create a user directory in /home/httpd.

Try this command, It will give you all the info you want (I think):
rpm -vv -i

Incidently, RPM is the easy choice, that brings with it many problems. If you want to install apache (and know everything about it), do it from scratch Download the source, untar it, configure/build it, and install it. Apache documentation is fairly good.

I hope this NFO was helpful
-Out0fOrder
 
man rpm on redhat 7.1 says -i as displaying package information. This is consistant with iggystar's output

I install packages using rpm -Uvh
 
Hi,

Some rpm examples.....

rpm -Fvh rpmname.rpm (freshen packages - update only if prior version installed)

rpm -Uvh rpmname.rpm (upgrade packages if prior version installed - if not installed then install now)

rpm -ivh rpmname.rpm  (install package only if no prior version installed)


The 'v' means verbose - i.e. gives info messages & the 'h' means print hash marks as a progress indicator #########

Regards
 
Thanks for all the input.

I still dont understand what my problem with RPM is. It just isn't doing anything. I've tried every variation that I've seen posted and its not putting any files anywhere. Maybe I have a bad .rpm file.

I finally did just build it and install it by hand. It was pretty easy and it worked. I'll have to fuss with RPM at some other time. Right now I want to fuss with Apache.

Thanks :)
 
Hi,

I assume you are doing rpm as root and have done a cd to the directory containing the rpms (or supplied full path on command line) - it won't work otherwise. A few more useful commands ....

rpm -qpl apache-1.3.19-5.i386.rpm (list files inside an unistalled rpm)
rpm -qip apache-1.3.19-5.i386.rpm (show package description for uninstalled package)

rpm -qa (list all installed packages)
rpm -qa | grep ^a (list all installed packages beginning with 'a')

rpm -qp --scripts apache-1.3.19-5.i386.rpm (show install / remove scripts of package)

[all of the above work for installed packages if you leave out the 'p' flag]

In fact, you can have hours of fun......

Regards

 
I still dont get it. I run rpm -Uvh on Samba that I just downloaded.

It threw a bunch of crap into /usr/src/redhat/SOURCES/ and that's it.

By what measurement of reasonable people does that count as installed?

Is there some convention that I need to get used to? After running rpm should I pet the magic duck and then move ever letter in ever file 2 places to left? What gives?

None of the files have descriptive names like README of CONFIGURE. My teeth are starting to hurt again.
 
if it throws sth to src dir, U R not installing samba....rpm, but samba...srpm, and U just get extracted sources, that U should compile. BTW. try rpm -qa, select one, try rpm -e, works it ok?
bubak
 
Hi,

Just download these beauties into somewhere like /home/yourlogon/download :


Then do :

$cd /home/yourlogon/download (or wherever you put the rpms)
$su [enter root password as prompted]
#rpm -Uvh apache*.rpm
#exit
$

That's it...
Regards
 
rpm with source code in my experiences usually can be made with rpm --rebuild. It will compile the source and make the rpms in source directories (watch the logging to find where they go). from there you can install or update the rpms(rpm -Uvh).
 
what about:

man rpm

This will answer every question in the foroum...
Disclaimer:
Beware: Studies have shown that research causes cancer in lab rats.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top