Forum: Ruby-core [Ruby 1.9 - Bug #4608][Open] Ctrl-c to interrupt script causes hang and 100% cpu's core load

Cf606c95d4030b7f27ec6ab1cdba4677?d=identicon&s=25 Roman Ralovets (Guest)
on 2011-04-24 21:17
(Received via mailing list)
Issue #4608 has been reported by Roman Ralovets.

----------------------------------------
Bug #4608: Ctrl-c to interrupt script causes hang and 100% cpu's core
load
http://redmine.ruby-lang.org/issues/4608

Author: Roman Ralovets
Status: Open
Priority: Normal
Assignee:
Category: core
Target version: 1.9.2
ruby -v: ruby 1.9.2p180 (2011-02-18 revision 30909) [i686-linux]


I have got this bug after updating Ubuntu from 10.10 to 11.04 Beta.
Using shell commands like `echo anything` causes hang and 100% cpu's
core load, if during downloading a file you press ctrl-c to interrupt.
Without using shell commands all right, we get "^CInterrupted"
In the Ubuntu 10.10 all right.
For a wonder autotest have got the same problem after updating ubuntu to
11.04 Beta: if I press ctrl-c to close autotest it hangs and loads 100%
cpu's core


roma@roma-comp:~/downloader$ ruby test.rb
Getting a file .. waiting for ctrl-c
^C^C^C
-----
  PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND
13159 roma      20   0 14052 8556 2568 R  100  0.4   1:52.68 ruby
test.rb
Cf606c95d4030b7f27ec6ab1cdba4677?d=identicon&s=25 Roman Ralovets (Guest)
on 2011-04-25 17:48
(Received via mailing list)
Issue #4608 has been updated by Roman Ralovets.


This bug has been repeated on another computer with ubuntu 11.04 (ruby
1.9.2p180)
if using ruby 1.8.7 (2010-08-16 patchlevel 302) [i686-linux] it all
works well.
----------------------------------------
Bug #4608: Ctrl-c to interrupt script causes hang and 100% cpu's core
load
http://redmine.ruby-lang.org/issues/4608

Author: Roman Ralovets
Status: Open
Priority: Normal
Assignee:
Category: core
Target version: 1.9.2
ruby -v: ruby 1.9.2p180 (2011-02-18 revision 30909) [i686-linux]


I have got this bug after updating Ubuntu from 10.10 to 11.04 Beta.
Using shell commands like `echo anything` causes hang and 100% cpu's
core load, if during downloading a file you press ctrl-c to interrupt.
Without using shell commands all right, we get "^CInterrupted"
In the Ubuntu 10.10 all right.
For a wonder autotest have got the same problem after updating ubuntu to
11.04 Beta: if I press ctrl-c to close autotest it hangs and loads 100%
cpu's core


roma@roma-comp:~/downloader$ ruby test.rb
Getting a file .. waiting for ctrl-c
^C^C^C
-----
  PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND
13159 roma      20   0 14052 8556 2568 R  100  0.4   1:52.68 ruby
test.rb
B58e3dccd17ecb20f65567f8b6ae163e?d=identicon&s=25 Mr Corn (Guest)
on 2011-04-26 12:40
(Received via mailing list)
Issue #4608 has been updated by Mr Corn.


I have the same problem with a freshly installed Ubuntu 11.04 and ruby
1.9.2p180.
STRG-c works in irb-shell, but not in the rails shell. Same problem with
autotest. No problems with ruby 1.8.7.
----------------------------------------
Bug #4608: Ctrl-c to interrupt script causes hang and 100% cpu's core
load
http://redmine.ruby-lang.org/issues/4608

Author: Roman Ralovets
Status: Open
Priority: Normal
Assignee:
Category: core
Target version: 1.9.2
ruby -v: ruby 1.9.2p180 (2011-02-18 revision 30909) [i686-linux]


I have got this bug after updating Ubuntu from 10.10 to 11.04 Beta.
Using shell commands like `echo anything` causes hang and 100% cpu's
core load, if during downloading a file you press ctrl-c to interrupt.
Without using shell commands all right, we get "^CInterrupted"
In the Ubuntu 10.10 all right.
For a wonder autotest have got the same problem after updating ubuntu to
11.04 Beta: if I press ctrl-c to close autotest it hangs and loads 100%
cpu's core


roma@roma-comp:~/downloader$ ruby test.rb
Getting a file .. waiting for ctrl-c
^C^C^C
-----
  PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND
13159 roma      20   0 14052 8556 2568 R  100  0.4   1:52.68 ruby
test.rb
4e2fecf95c856f2acc9dd8cd4927e5c2?d=identicon&s=25 Jason Earl (Guest)
on 2011-05-04 19:04
(Received via mailing list)
Issue #4608 has been updated by Jason Earl.


I filed a similar bug on Rail's lighthouse a few days ago too. I've
found Natty in fact to be pretty bad in some areas regarding stablity, I
really hope the Ubuntu team clean up the various issues soon (So anyone
reading this, I suggest hold back from using Natty if you haven't
installed it for a bit). I know the 2.6.38 kernel changed some
scheduling bits, I'm not sure if this is what's triggering this.

http://rails.lighthouseapp.com/projects/8994/ticke...

This appears to be a process management / deadlock issue I think. If you
manually install a kernel from Maverick (i.e. download the kernel +
headers and use dpkg -i to install) it will prevent the issue, so this
is a kernel change that has triggered this.

It takes a kill -9 to stop the process, so it's must be in some deadlock
----------------------------------------
Bug #4608: Ctrl-c to interrupt script causes hang and 100% cpu's core
load
http://redmine.ruby-lang.org/issues/4608

Author: Roman Ralovets
Status: Open
Priority: Normal
Assignee:
Category: core
Target version: 1.9.2
ruby -v: ruby 1.9.2p180 (2011-02-18 revision 30909) [i686-linux]


=begin
I have got this bug after updating Ubuntu from 10.10 to 11.04 Beta.
Using shell commands like `echo anything` causes hang and 100% cpu's
core load, if during downloading a file you press ctrl-c to interrupt.
Without using shell commands all right, we get "^CInterrupted"
In the Ubuntu 10.10 all right.
For a wonder autotest have got the same problem after updating ubuntu to
11.04 Beta: if I press ctrl-c to close autotest it hangs and loads 100%
cpu's core


roma@roma-comp:~/downloader$ ruby test.rb
Getting a file .. waiting for ctrl-c
^C^C^C
-----
  PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND
13159 roma      20   0 14052 8556 2568 R  100  0.4   1:52.68 ruby
test.rb

-----
I'm waiting for such a result:

roma@roma-comp:~/downloader$ ruby test.rb
Getting a file .. waiting for ctrl-c
^CInterrupted
---

=end
02da662c083396641da96c1d32fc86ed?d=identicon&s=25 Motohiro KOSAKI (Guest)
on 2011-06-05 16:03
(Received via mailing list)
Issue #4608 has been updated by Motohiro KOSAKI.

Status changed from Open to Third Party's Issue

I think this is the same issue with Bug #4777.

----------------------------------------
Bug #4608: Ctrl-c to interrupt script causes hang and 100% cpu's core
load
http://redmine.ruby-lang.org/issues/4608

Author: Roman Ralovets
Status: Third Party's Issue
Priority: Normal
Assignee:
Category: core
Target version: 1.9.2
ruby -v: ruby 1.9.2p180 (2011-02-18 revision 30909) [i686-linux]


=begin
I have got this bug after updating Ubuntu from 10.10 to 11.04 Beta.
Using shell commands like `echo anything` causes hang and 100% cpu's
core load, if during downloading a file you press ctrl-c to interrupt.
Without using shell commands all right, we get "^CInterrupted"
In the Ubuntu 10.10 all right.
For a wonder autotest have got the same problem after updating ubuntu to
11.04 Beta: if I press ctrl-c to close autotest it hangs and loads 100%
cpu's core


roma@roma-comp:~/downloader$ ruby test.rb
Getting a file .. waiting for ctrl-c
^C^C^C
-----
  PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND
13159 roma      20   0 14052 8556 2568 R  100  0.4   1:52.68 ruby
test.rb

-----
I'm waiting for such a result:

roma@roma-comp:~/downloader$ ruby test.rb
Getting a file .. waiting for ctrl-c
^CInterrupted
---

=end
8824b39071f775c0be35a2320408e92d?d=identicon&s=25 Fred Schoeneman (fred_schoeneman)
on 2011-06-13 18:16
Want to add to this bug description for autotest with ruby 1.9.2 on
Ubuntu 11.04 as it seems related to this bug:

 https://github.com/grosser/autotest/issues/23#issu...
This topic is locked and can not be replied to.