Can I attach ruby-debug to a running process?



I’m having a problem which shows up in-deterministically after some
time. Something goes wrong, and apparently the rails-process hangs,
without exiting. I was thinking about using ruby-debug to attach to one
of these processes, to find out where in my application that the problem
happens. Is this possible?