[Yum] Yum service hangs

Michael Stenner mstenner at ece.arizona.edu
Wed Sep 1 16:55:54 UTC 2004


On Wed, Sep 01, 2004 at 12:42:43PM -0400, David L. Parsley wrote:
> > This may not be something timeouts can help though.  How long will it
> > hang?  A few minutes?  Hours?  If the latter, it's probably broken ftp
> > handling (possibly server, more likely client, conceivably both).  In
> > that case, timeouts won't help.

David and Ugo,

> It hangs for _days_; from ps:
> root     10267 10266  0 Aug19 ?        00:00:00 /usr/bin/python
> /usr/bin/yum -R 10 -e 0 -d 0 -y update yum
> 
> from netstat:
> tcp        0      0 galadriel.alfred.:33657 some.ftp.server:40009
> ESTABLISHED 10267/python        
> tcp        0      0 galadriel.alfred.:33656 some.ftp.server:ftp 
> ESTABLISHED 10267/python
> 
> strace'ing it:
> Process 10267 attached - interrupt to quit
> read(8, 
> 
> Tracing fd 8 via /proc, it corresponds to port 40009 - so that's the
> data port, not the control port, as I thought.
> 
> I've seen this happen with my own machines with two different ftp
> servers now.  It seems like the client should, at some point, send some
> kind of 'hey, you gonna send my data?' packet (keepalive or something?),
> whereupon the server should RST - 'who the hell are you?'.  In the case
> of the other ftp server, it reboots every morning.  So, after being hung
> for a day, the server has no clue yum is sitting there waiting for data.

Yeah, it sounds like this is probably some issue in ftplib.  The fact
that it's intermittent naturally makes it much harder to track down.
If you can't get it to break on demand, perhaps you can do this:

   1) grab ftplib from /usr/lib/python2.X/     <- with correct version
   2) edit the copy to set "debugging = 1" in class FTP
   3) put this ftplib in the python path, which can be done in two
      ways:
      *) put it in /usr/share/yum/
      *) put it elsewhere, and add that path to PYTHONPATH before
         running yum.  For example:
           export PYTHONPATH=/home/mstenner/yumtest
           yum -ty update >> /home/mstenner/yumtest/ftp-debug.log
   4) check the log after it happens

That's about all I've got at the moment.

					-Michael
-- 
  Michael D. Stenner                            mstenner at ece.arizona.edu
  ECE Department, the University of Arizona                 520-626-1619
  1230 E. Speedway Blvd., Tucson, AZ 85721-0104                 ECE 524G



More information about the Yum mailing list