LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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 06-06-2013, 03:51 PM   #1
gusthecat
LQ Newbie
 
Registered: Feb 2012
Posts: 19

Rep: Reputation: Disabled
rpm fails but still shows installed


How do you handle this condition in a spec file:

if some actions fails and the error status is properly caught the rpm should not be listed in rpm db as installed


If I exit 1 on failure the rpm is still listed.
 
Old 06-06-2013, 04:13 PM   #2
John VV
LQ Muse
 
Registered: Aug 2005
Location: A2 area Mi.
Posts: 17,624

Rep: Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651
Are you trying to use "rpm" to install the rpm ,or the best way using your package manager
" yum" or " zypper "
 
Old 06-07-2013, 08:03 AM   #3
gusthecat
LQ Newbie
 
Registered: Feb 2012
Posts: 19

Original Poster
Rep: Reputation: Disabled
the package is installed via rpm.
 
Old 06-07-2013, 01:08 PM   #4
John VV
LQ Muse
 
Registered: Aug 2005
Location: A2 area Mi.
Posts: 17,624

Rep: Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651
When you use " yum " are there any errors
 
Old 06-08-2013, 02:42 PM   #5
Gad
Member
 
Registered: May 2013
Distribution: FreeBSD
Posts: 566

Rep: Reputation: 114Reputation: 114
Quote:
Originally Posted by John VV View Post
Are you trying to use "rpm" to install the rpm ,or the best way using your package manager
" yum" or " zypper "
Yes, "gusthecat" are you able to provide your displays output?
 
Old 06-10-2013, 09:13 AM   #6
gusthecat
LQ Newbie
 
Registered: Feb 2012
Posts: 19

Original Poster
Rep: Reputation: Disabled
Folks thanks for replying but based on your questions to me I'm not sure I asked my question correctly.
Let me try again

I'm writing a spec file to install some files and update a database.
If during that process something fails, for example writing to the database fails I can catch that
error and but how do I exit the installer and not have the rpm database updated showing the failed package
is installed?
 
Old 06-10-2013, 12:59 PM   #7
John VV
LQ Muse
 
Registered: Aug 2005
Location: A2 area Mi.
Posts: 17,624

Rep: Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651
The package manager ( yum or zypper) will handle that

if a dependency can not be met,or an error during the install , then it will not install

Last edited by John VV; 06-10-2013 at 01:01 PM.
 
Old 06-10-2013, 01:45 PM   #8
Gad
Member
 
Registered: May 2013
Distribution: FreeBSD
Posts: 566

Rep: Reputation: 114Reputation: 114
Whatever dependencies are missing would need to be manually installed either using RPM, YUM etc...
 
  


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
Password Complexity using PAM FAILS and shows no effect Rahil Parikh Linux - Server 2 11-24-2010 07:30 AM
Software shows up as installed and not installed at same time in zypper. LazerPhreak Linux - Software 2 12-13-2009 01:01 AM
installed apache from source, didn't remove rpm, updated rpm causes problems leftPeg Linux - Newbie 5 06-06-2007 09:20 PM
Doom3 demo shows screen then fails ctlphd Linux - Games 8 04-07-2005 04:15 PM
rpm -q not shows installed rpm mla Linux - Software 4 10-31-2004 02:49 PM

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

All times are GMT -5. The time now is 06:39 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