Bug 487680

Summary: DNS can hang on slow internet connections, making Control-C less usable
Product: [Fedora] Fedora Reporter: lexual <lex.lists>
Component: yumAssignee: Seth Vidal <skvidal>
Status: CLOSED NOTABUG QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: low    
Version: rawhideCC: ffesti, james.antill, pmatilai, tim.lauridsen
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2009-02-27 22:24:24 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description lexual 2009-02-27 13:12:13 UTC
Description of problem:
Ctrl-C doesn't close yum when on a slow connection [e.g. currently my internet is shaped at around 120kbps (yum shows downloads around 15k/s).]
Problem doesn't really seem to happen when I'm on normal higher speeds.

Version-Release number of selected component (if applicable):


How reproducible:
100%

Steps to Reproduce:
1. yum -y install foo
2. yum starts to download
3. press Ctrl-C
  
Actual results:
Transaction Summary
===============================================================================
Install     59 Package(s)         
Update      91 Package(s)         
Remove       0 Package(s)         

Total size: 155 M
Total download size: 113 M
Is this ok [y/N]: y
Downloading Packages:
(1/29): htmlview-4.0.0-3.fc7.noarch.rpm                 | 8.8 kB     00:00     
(2/29): fprintd-pam-0.1-7.git04fd09cfa.fc11.i386.rpm    |  10 kB     00:00     
(3/29): fprintd-0.1-7.git04fd09cfa.fc11.i386.rpm        |  39 kB     00:02     
(4/29): libusb1-1.0.0- (0%) 15% [=-          ]  0.0 B/s | 8.0 kB     --:-- ETA (4/29): libusb1-1.0.0-1.fc11.i386.rpm                   | 8.0 kB     00:00     

 Current download cancelled, interrupt (ctrl-c) again within two seconds to exit.

^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^

Expected results:
Hitting ctrl-c again works as advertised.


Additional info:

Comment 1 James Antill 2009-02-27 22:24:24 UTC
There isn't much we can do about this, eventually you should hit a mirror where the DNS resolves within a normal amount of time. Running a local caching DNS server will also help.

Comment 2 lexual 2009-07-30 23:42:28 UTC
I must say that I come up against this bug constantly, including when on a wireless connection on my laptop.

The following has almost become muscle memory as a workaround for this buggy behaviour.

Ctrl-Z
sudo ps
sudo kill -9 <pid>

Is a fix, to have a tiny sleep before the next mirror is contacted, so that control-c actually does works.

I think it is really bad behaviour to have information given to the user 

"Current download cancelled, interrupt (ctrl-c) again within two seconds to
exit."

that isn't correct.

Either one lookup gets stuck, or holding ctrl-c down goes through every mirror, instead of cancelling the yum command.