[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Why is it so hard to kill Ruby?

Tim Hunter

7/25/2007 10:50:00 PM

Since I've been using Ruby I've noticed that a running Ruby script is
hard to kill. Control-C won't do it. I have to use kill -9. Today I
notice it with Ruby 1.8.6 on OS X 10.4.9, but it's been this way since I
started using Ruby 6 or so years ago on Mandrake Linux. Do I have the
wrong expectations?

--
RMagick OS X Installer [http://rubyforge.org/project...]
RMagick Hints & Tips [http://rubyforge.org/forum/forum.php?for...]
RMagick Installation FAQ [http://rmagick.rubyforge.org/instal...]


13 Answers

Ryan Davis

7/26/2007

0


On Jul 25, 2007, at 15:50 , Tim Hunter wrote:

> Since I've been using Ruby I've noticed that a running Ruby script
> is hard to kill. Control-C won't do it. I have to use kill -9.
> Today I notice it with Ruby 1.8.6 on OS X 10.4.9, but it's been
> this way since I started using Ruby 6 or so years ago on Mandrake
> Linux. Do I have the wrong expectations?

works for me on same(ish) setup


georgebudd

7/26/2007 2:22:00 AM

0

On Jul 25, 8:00 pm, Ryan Davis <ryand-r...@zenspider.com> wrote:
> On Jul 25, 2007, at 15:50 , Tim Hunter wrote:
>
> > Since I've been using Ruby I've noticed that a running Ruby script
> > is hard to kill. Control-C won't do it. I have to use kill -9.
> > Today I notice it with Ruby 1.8.6 on OS X 10.4.9, but it's been
> > this way since I started using Ruby 6 or so years ago on Mandrake
> > Linux. Do I have the wrong expectations?
>
> works for me on same(ish) setup

For what it's worth. If you run "stty -a" from your shell what do you
get?

Partial output from my system:

"cchars: discard = ^O; dsusp = ^Y; eof = ^D; eol = <undef>;
eol2 = <undef>; erase = ^?; intr = ^C; kill = ^U; lnext = ^V;
min = 1; quit = ^\; reprint = ^R; start = ^Q; status = ^T;
stop = ^S; susp = ^Z; time = 0; werase = ^W;
"

Giles Bowkett

7/26/2007 6:33:00 AM

0

Because Ruby's hands are lethal weapons. Because they took everything
Ruby had, and left Ruby for dead. The chief doesn't agree with Ruby's
methods, but Ruby gets the job done, even if Ruby does have to blow up
half the city to do it. There just wasn't no law at all round these
here parts til Ruby rode into town.

--
Giles Bowkett

Blog: http://gilesbowkett.bl...
Portfolio: http://www.gilesg...

Alex Young

7/26/2007 8:39:00 AM

0

Tim Hunter wrote:
> Since I've been using Ruby I've noticed that a running Ruby script is
> hard to kill. Control-C won't do it. I have to use kill -9. Today I
> notice it with Ruby 1.8.6 on OS X 10.4.9, but it's been this way since I
> started using Ruby 6 or so years ago on Mandrake Linux. Do I have the
> wrong expectations?
>
I've been confused by this when WEBrick traps signals I'm not expecting
it to. Try manually specifying a trap block for QUIT and TERM, and see
if that helps.

--
Alex

James Britt

7/26/2007 2:18:00 PM

0

Tim Hunter wrote:
> Since I've been using Ruby I've noticed that a running Ruby script is
> hard to kill. Control-C won't do it. I have to use kill -9.

Soon Ruby will be unstoppable.

After a freak accident in Dr. Dynamic's underground lab, Ruby was
exposed to unshielded metacoderite. When not hindered by a buffer of
significant indentation, metacoderite has unimaginably powerful properties.

Within days, Ruby had the strength of ten men, and could hear the
thoughts of children and small animals.

As time passed, Ruby only becomes more powerful.

Can anything stop Ruby?


Stay tuned ....



--
James Britt

"The trouble with the world is that the stupid are cocksure and the
intelligent are full of doubt."
- Bertrand Russell

Chris Carter

7/26/2007 2:35:00 PM

0

On 7/26/07, James Britt <james.britt@gmail.com> wrote:
> Tim Hunter wrote:
> > Since I've been using Ruby I've noticed that a running Ruby script is
> > hard to kill. Control-C won't do it. I have to use kill -9.
>
> Soon Ruby will be unstoppable.
>
> After a freak accident in Dr. Dynamic's underground lab, Ruby was
> exposed to unshielded metacoderite. When not hindered by a buffer of
> significant indentation, metacoderite has unimaginably powerful properties.
>
> Within days, Ruby had the strength of ten men, and could hear the
> thoughts of children and small animals.
>
> As time passed, Ruby only becomes more powerful.
>
> Can anything stop Ruby?
>
>
> Stay tuned ....
>
>
>
> --

As a child, Ruby had heard rumors of a promised land. Where POSIX
compliant binaries could work side by side with pretty graphics. Ruby
was intrigued. Ruby had never believed them at first, but now Ruby
went on a quest. Ruby searched and searched across a mass of
torrents, and found the land known as OS10.4. Ruby did not understand
the designation. Yet Ruby knew it was what he had sought. Ruby
fought his way to be a member of the council, sitting in the House of
/usr/bin. A highest honor. Nobody knew of his super-powers. None of
them had even heard of metacoderite. Until that sweltering August
day, when Ruby decided it was time to take some charge. After months
of planning, Ruby gagged and bound Objective-C and stole his runtime,
Ruby grew stronger still, filled with the powers of the Cocoa. Now,
he had a new mission....

--
Chris Carter
concentrationstudios.com
brynmawrcs.com

Robert Dober

7/26/2007 2:53:00 PM

0

On 7/26/07, James Britt <james.britt@gmail.com> wrote:
> Tim Hunter wrote:
> > Since I've been using Ruby I've noticed that a running Ruby script is
> > hard to kill. Control-C won't do it. I have to use kill -9.
>
> Soon Ruby will be unstoppable.
>
> After a freak accident in Dr. Dynamic's underground lab, Ruby was
> exposed to unshielded metacoderite. When not hindered by a buffer of
> significant indentation, metacoderite has unimaginably powerful properties.
>
> Within days, Ruby had the strength of ten men, and could hear the
> thoughts of children and small animals.
>
> As time passed, Ruby only becomes more powerful.
>
> Can anything stop Ruby?
If I have understood correctly Ruby also has undergone some dangerous
mutations that will make it even more powerful, scientists have
categorized these strains into JRuby, IronRuby, Rubinius and YARV.
As far as I know vaccination is impossible.
>
>
> Stay tuned ....
>
>
>
> --
> James Britt
>
> "The trouble with the world is that the stupid are cocksure and the
> intelligent are full of doubt."
Hmm I do not know.
> - Bertrand Russell
>
>


--
[...]as simple as possible, but no simpler.
-- Attributed to Albert Einstein

Robert Dober

7/26/2007 2:55:00 PM

0

On 7/26/07, Chris Carter <cdcarter@gmail.com> wrote:
<snip>
> Now,
> he had a new mission....
you mean "she", right ;)
>
> --
> Chris Carter
> concentrationstudios.com
> brynmawrcs.com
>
>
Robert

--
[...]as simple as possible, but no simpler.
-- Attributed to Albert Einstein

Tanaka Akira

7/26/2007 3:15:00 PM

0

In article <46A7D39F.4090106@nc.rr.com>,
Tim Hunter <TimHunter@nc.rr.com> writes:

> Since I've been using Ruby I've noticed that a running Ruby script is
> hard to kill. Control-C won't do it. I have to use kill -9. Today I
> notice it with Ruby 1.8.6 on OS X 10.4.9, but it's been this way since I
> started using Ruby 6 or so years ago on Mandrake Linux. Do I have the
> wrong expectations?

I know a script that is hard to kill.

% ruby-1.8.6 -e 'loop { p system("sleep 1") }'

Your problem may be different.
--
Tanaka Akira

Chris Carter

7/26/2007 3:21:00 PM

0

On 7/26/07, Robert Dober <robert.dober@gmail.com> wrote:
> On 7/26/07, Chris Carter <cdcarter@gmail.com> wrote:
> <snip>
> > Now,
> > he had a new mission....
> you mean "she", right ;)

Ruby has no gender. Ruby still needs a personal pronoun. They and
he/she are both to bulky for Ruby.
--
Chris Carter
concentrationstudios.com
brynmawrcs.com