[R] exit and save data from the terminal where command is frozen
Duncan Murdoch
murdoch.duncan at gmail.com
Sat Jan 1 22:00:52 CET 2011
On 01/01/2011 3:42 PM, Brian Kidd wrote:
> Hello,
>
> Is there any way to stop an R execution in a terminal where the previous command appears to have caused the code to hang? I basically need to get back to the prompt.
>
> Note that control-c doesn't restore the prompt and running top -o cpu from another terminal shows R at>99% CPU usage. While closing the terminal would work, I'd really like to save the data and the history file if I can. Is the temporary history list and/or variables from the current session located somewhere on my machine that I could get to and save before closing the terminal? Or is this a lost cause?
There's probably no way if Ctrl-C doesn't work.
You might be able to attach gdb to the process and see what's going on
in there, but that's not too likely to be successful.
Next time it would be a good idea to save results on a regular basis so
that you can restart from a more recent save point.
Duncan Murdoch
More information about the R-help
mailing list