Michael Stenner wrote: >On Wed, Aug 11, 2004 at 12:01:09PM -0400, Paul Pianta wrote: > > >>I ran a 'tail -f /var/log/messages' on the server while running a yum >>update on one of the clients. Everything goes well but rather slowly. >>The tail shows me that the ftp client is logging in - downloading >>something (ie. header or package) then logging out, then it does this >>all again for the next header/package. All of this logging in and out >>obviously slows down the whole business. >> >>I am wondering if this is a natural yum behaviour or it is due to my ftp >>client and authentication stuff. >> >> > >Here's the deal. Yum uses urlgrabber, a python module for handling >urls (duh), which in turn uses urllib2, a built-in python url-handling >module, which in turn uses things like ftplib and httplib. Now, what >you're describing is the way ftplib handles things. It's not really >optimized for multiple downloads. There is such a thing as a caching >ftp opener (which supposedly reuses connections), but we haven't >explored it very much. Most people tend to use http and it's a bit >easier for us to work with, so that gets most of our attention. > >My point is: this isn't exactly a bug. It's known current behavior. >It's not really desired, but we haven't done a lot to address it. >If anybody out there does try to pursue this, they should chat with us >(me and Ryan) on the yum-devel list because there are some fairly >subtle interaction issues that need to be considered. > >Note: this problem doesn't exist with an http server that supports >keepalive; those connections are reused. > > Thanks Michael Well I guess I will just have to live with it being slow - no big ... unless someone has already implemented something similar using http? I need a system that will authenticate clients against a custom repository. Depending on their key - they can access (or not) a base repo, and several other 'optional' repos - ie. packages that they have the right to download on top of the base packages. I thought about blocking access to repos with .htaccess but it would be painful to maintain the .htaccess files for many clients (and anyway I think yum would exit on authentication failure). I am just throwing the idea out there incase I am missing some really simple solution with http. If you have a complicated http solution - thanks but I already have a working complicated ftp setup :) - it's just that it's a bit slow. Thanks again pantz -- Before you criticize someone, walk a mile in their shoes ... That way when you do criticize them, you're a mile away and you have their shoes!