On 04/25/2013 08:53 PM, James Antill wrote:
On Thu, 2013-04-25 at 19:32 +0300, Panu Matilainen wrote:
On 04/25/2013 06:02 PM, James Antill wrote:
On Thu, 2013-04-25 at 09:09 +0300, Panu Matilainen wrote:
Something in commit fc395ef14b135b3591488816ec902057fd8d03f4 makes
diskspacecheck=0 not disable the disk space check at all. Moving
the thing to initActionTs() where other similar initialization
is done makes it work again. In addition, enable filtering of
inode problems also to behave the same as rpm's --ignorespace.
Should change the documentation in yum.conf to explain that this does
inodes too now. Apart from that ACK.
Ok, I can add a blurb about that. Another alternative could be adding a
separate option to skip inode check, at least the special case that
"inspired" me to look at this would actually benefit from having them
separated (weird filesystem which supposedly has no inode limit but
apparently advertises this with 0 for total inodes...)
Yeh, that was the other obvious choice ... I'm happy for you to do that
if it helps you. Should be fairly trivial. My guess is that it was never
there because while running out of data space is trivial/common running
out of inodes is not.
Okay, since you're not opposed to a separate config option, perhaps that
makes more sense as indeed running out of inodes is by far more rare
than the running out of disk. I'll commit the part that resurrects
diskspacecheck=0 separately and post another patch to add diskinodecheck
config option for a separate review.
Oh, I wasn't talking about removing functions, just the apparently dead
code. Basically:
Ugh :(.
--- a/yum/__init__.py
+++ b/yum/__init__.py
@@ -6181,16 +6181,12 @@ much more problems).
% self.conf.bugtracker_url)
raise Errors.YumRPMCheckError,retmsgs
- tsConf = {}
- for feature in ['diskspacecheck']: # more to come, I'm sure
- tsConf[feature] = getattr( self.conf, feature )
- #
testcb = RPMTransaction(self, test=True)
# overwrite the default display class
if display:
testcb.display = display
- tserrors = self.ts.test( testcb, conf=tsConf )
+ tserrors = self.ts.test( testcb )
del testcb
if len( tserrors ) > 0:
...and perhaps also:
--- a/rpmUtils/transaction.py
+++ b/rpmUtils/transaction.py
@@ -111,10 +111,6 @@ class TransactionWrapper:
origflags = self.getTsFlags()
self.addTsFlag(rpm.RPMTRANS_FLAG_TEST)
- # FIXME GARBAGE - remove once this is reimplemented elsehwere
- # KEEPING FOR API COMPLIANCE ONLY
- if conf.get('diskspacecheck') == 0:
- self.ts.setProbFilter(rpm.RPMPROB_FILTER_DISKSPACE)
tserrors = self.ts.run(cb.callback, '')
self.ts.setFlags(origflags)
Neither of these affects diskspacecheck functionality wrt yum itself,
but I guess it is entirely possible that these do make a difference to
some caller, as the api compliance comment notes.
Yeh, at worst we should have some comment in _doTestTransaction()
saying that those lines do nothing. I'd rather not remove the rpmUtils
bits though.
How does it not work? (I'd have bet $1 that it did :).
Well, how many ways there are for diskspacecheck=0 not working? :D When
trying to install something into a full filesystem, setting
diskspacecheck=0 should cause the test to be skipped in both
test-transaction and the actual transaction, but these bits have no
effect whatsoever with yum itself. Haven't tried other API users.
My guess is that it broke at around the same time as the part in cli.py
did, but I haven't bothered hunting what exactly it was about commit
fc395ef14b135b3591488816ec902057fd8d03f4 that broke it. It seems kinda
counter-intuitive but...
- Panu -
_______________________________________________
Yum-devel mailing list
[email protected]
http://lists.baseurl.org/mailman/listinfo/yum-devel