[Rd] Ctrl-c crashes R when run as sudo (PR#7819)

MSchwartz at MedAnalytics.com MSchwartz at MedAnalytics.com
Tue Apr 26 18:30:37 CEST 2005


On Tue, 2005-04-26 at 11:41 -0400, Manuel Morales wrote:
> On Tue, 2005-04-26 at 10:34 -0500, Marc Schwartz wrote:
> > On Tue, 2005-04-26 at 16:47 +0200, Manuel.A.Morales at williams.edu wrote:
> > > I tried to submit this in R, but not sure if it worked.
> > > 
> > > When running R as sudo, using ctrl-c dumps me to the command line.
> > > Hitting exit to exit the terminal window results in R taking 100% of
> > > resources.
> > > 
> > > I am using R-2.1.0 on Fedora Core 3.
> > > 
> > > Thanks.
> > > 
> > > Manuel
> > 
> > I suspect that we are going to need more information.
> > 
> > Running on a fully updated FC3 box using Xfce's Terminal, gnome-terminal
> > and kconsole, I cannot duplicate this issue either as a user or as root
> > using sudo.
> > 
> Note that this doesn't happen if I run R as a normal user or as root.
> I.e.,
> 
> R
> <ctrl-c>
> or
> 
> su
> R
> <ctrl-c>
> works fine.
> 
> sudo R
> <ctrl-c>
> does not.
> 
> > Attach the output of:
> > 
> > > R.version 
> > 
> 
> > R.version
>          _
> platform i686-pc-linux-gnu
> arch     i686
> os       linux-gnu
> system   i686, linux-gnu
> status
> major    2
> minor    1.0
> year     2005
> month    04
> day      18
> language R
> 
> 
> > Was there a program running in R at the time, or were you at the R
> > prompt when you hit ctrl-c?
> > 
> 
> R prompt
> 
> > Which desktop environment and terminal emulator are you using? 
> > 
>  
> Gnome and gnome-terminal, although the problem also happens when using
> xterm.
> 
> > Have you perhaps re-mapped ctrl-c using modified keybindings?
> 
> No. And ctrl-c works fine as a normal user or as root.

Manuel,

Please be sure to copy R-bugs at biostat.ku.dk when you reply so that the
thread is properly archived in the bug tracking system.

I tried this under GNOME using gnome-terminal and the unpatched version
of R 2.1.0 and still could not duplicate the problem.

Can you post back with the contents of /etc/sudoers?

The other possibility would be to run:

sudo R -d gdb

in gnome-terminal. When you get to the (gdb) prompt, type 'r' (without
the quotes) for run, which will start up R.

If you can replicate the problem under gdb and R exits after a ctrl-c,
you should be left at a (gdb) prompt. If that occurs, type 'bt' (without
the quotes), which will display a backtrace. If that all works, post the
output of gdb from the crtl-c through and including the backtrace here.

Marc



More information about the R-devel mailing list