LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 02-12-2013, 04:16 PM   #1
theKbStockpiler
Member
 
Registered: Sep 2009
Location: Central New York
Distribution: RPM Distros,Mostly Mandrake Forks;Drake Tools/Utilities all the way!GO MAGEIA!!!
Posts: 986

Rep: Reputation: 53
Rpm file questions


I was wondering if it matters where a rpm file is located when it is installed using
Quote:
rpm -ivh package-name
I usually put it in the home directory. Does it have to be and can I delete it after I install the rpm file? Does it matter what directory BASH is in when it is installed?

Thanks in advance!
 
Old 02-12-2013, 04:27 PM   #2
Kustom42
Senior Member
 
Registered: Mar 2012
Distribution: Red Hat
Posts: 1,604

Rep: Reputation: 415Reputation: 415Reputation: 415Reputation: 415Reputation: 415
Quote:
Originally Posted by theKbStockpiler View Post
I was wondering if it matters where a rpm file is located when it is installed
Absolutely not! However, you should make sure that you are pathing to the right place. If I do a wget on an rpm, I then do a:

Code:
rpm -ivh ./rpmfile.rpm
instead of just

Code:
rpm -ivh rpmfile.rpm
Relying on your BASH $PATH variable is not always 100% reliable.

Quote:
Originally Posted by theKbStockpiler View Post

I usually put it in the home directory. Does it have to be and can I delete it after I install the rpm file? Does it matter what directory BASH is in when it is installed?
Does not matter where you are at when you install it and you can safely delete after installing. The spec files for RPMs tell the package manager where the files are supposed to go and what to do with them. You can do an rpm --list to see what files it will install and where.

Last edited by Kustom42; 02-12-2013 at 04:29 PM.
 
1 members found this post helpful.
Old 02-12-2013, 04:32 PM   #3
blue_print
Member
 
Registered: May 2010
Location: In world
Distribution: RHEL, CentOS, Ubuntu
Posts: 275
Blog Entries: 3

Rep: Reputation: 50
You can keep the RPM file anywhere (but not in /lib, /dev, /proc, /sys ). But if you execute the command from one place and the rpm is in another location, you will need to give the path to the RPM file. Example, the RPM "a.rpm" is located in /tmp and you're in /home/.


rpm -ivh a.rpm -> Doesn't work
rpm -ivh /tmp/a.rpm - Works
cd /tmp;rpm -ivh a.rpm - Works

Yes, you can delete the rpm file after the installation.
 
1 members found this post helpful.
  


Reply



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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How can I generate / build and RPM from *.src.rpm file sreekumartg Red Hat 3 02-23-2007 05:23 PM
questions on writing own rpm .spec file adrianmak Linux - Software 0 08-18-2005 06:03 AM
cannot build source rpm/ rpm questions kpachopoulos Fedora 3 07-24-2005 09:15 AM
RPM File Questions BajaNick Linux - General 6 08-18-2003 04:38 PM
binary vs source RPM (and other RPM questions) calimer Linux - Software 4 06-22-2003 12:33 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 05:55 PM.

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