similar to: Background R session on Unix and SIGINT

Displaying 20 results from an estimated 6000 matches similar to: "Background R session on Unix and SIGINT"

2019 Apr 30
2
Background R session on Unix and SIGINT
Yeah, I get that they are async. What happens is that the background process is not doing anything when the process gets a SIGINT. I.e. the background process is just listening on its standard input. AFAICT for an interactive process such a SIGINT is just swallowed, with a newline outputted to the terminal. But apparently, for this background process, it is not swallowed, and it is triggered
2019 Apr 30
2
Background R session on Unix and SIGINT
OK, I managed to create an example without callr, but it is still somewhat cumbersome. Anyway, here it is. Terminal 1: mkfifo fif R --no-readline --slave --no-save --no-restore < fif Terminal 2: cat > fif Sys.getpid() This will make Terminal 1 print the pid of the R process, so we can send a SIGINT: Terminal 3: kill -INT pid The R process is of course still running happily. Terminal 2
2019 Apr 30
2
[External] Re: Background R session on Unix and SIGINT
Unfortunately --interactive also makes the session interactive(), which is bad for me, as it is a background session. In general, I don't want the interactive behavior, but was wondering if I could send as SIGINT to try to interrupt the computation of the background process, and if that does not work, then I would send a SIGKILL and start up another process. It all works nicely, except for
2019 Apr 30
0
Background R session on Unix and SIGINT
Can you give an example without callr? The key is how is the process stated and what it is doing which is entirely opaque in callr. Windows doesn't have signals, so the process there is entirely different. Most of the WIN32 processing is event-based. Cheers, Simon > On Apr 30, 2019, at 4:17 PM, G?bor Cs?rdi <csardi.gabor at gmail.com> wrote: > > Yeah, I get that they are
2019 Apr 30
0
[External] Re: Background R session on Unix and SIGINT
A Simon pointed out the interrupt is recorded but not processed until a safe point. When reading from a fifo or pipe R runs non-interactive, which means is sits in a read() system call and the interrupt isn't seen until sometime during evaluation when a safe checkpoint is reached. When reading from a terminal R will use select() to wait for input and periodically wake and check for
2019 May 01
0
[External] Re: Background R session on Unix and SIGINT
Gabor, I think you're talking about two independent things. You can interrupt the computation, no question about that. It's just that if you send an interrupt while you're *not* doing any computations, it will be signaled but not raised until the interrupts are checked since there is no one to check it. This goes back to my original response - the interactive REPL calls
2019 Apr 30
0
Background R session on Unix and SIGINT
Interrupts are not synchronous in R - the signal only flags the request for interruption. Nothing actually happens until R_CheckUserInterrupt() is called at an interruptible point. In you case your code is apparently not calling R_CheckUserInterrupt() until later as a side-effect of the next evaluation. Cheers, Simon > On Apr 30, 2019, at 3:44 PM, G?bor Cs?rdi <csardi.gabor at
2013 May 01
2
Catch SIGINT from user in backend C++ code
Hi, I was wondering if anybody knew how to trap SIGINTs (ie Ctrl-C) in backend C++ code for R extensions? I'm writing a package that uses the GPU for some hefty matrix operations in a tightly coupled parallel algorithm implemented in CUDA. The problem is that once running, the C++ module cannot apparently be interrupted by a SIGINT, leaving the user sat waiting even if they realise
2012 May 22
1
Capturing signals from within external libs
I have a continuous loop running in an external library that I am calling from C (R API). This loop is processing events in real time with the possibility of significant lag between events. When processing an event, I can make use of R_CheckUserInterrupt, but while the external library code is waiting on a new event, I don't have an opportunity to call this - my entry points are only on
2001 Jun 27
2
OpenSSH, Cygwin, eXceed, and SIGINT
All, When logging into an HP-UX 10.2 system from a Windows NT machine running Cygwin and openssh 2.9p2, control-c sends a sigint to the ssh client on the NT system, thus killing the ssh process. Interestingly enough, this behavior is only observed when using X11 forwarding. I can eliminate the behavior by changing clientloop.c to ignore SIGINT (signal(SIGINT, SIG_IGN) ) but then I'm bak to
2018 May 06
1
Ubuntu 18.04 bionic: availability of R Ubuntu packages/ppa?
awesome, merci Dirk! and my apologies for not scrolling down better, I failed to see that the 18.04 update was linked to the R 3.5 issue . Further, please forgive my impatience, but I was very curious to see if the package tidyverse could be installed: I have the impression that it is short of being installed, missing just a few simple packages (with no apparent non-R dependencies). Indeed, a
2004 Jun 14
5
mkChar can be interrupted
Hi, As was discussed earlier in another thread and as documented in R-exts .Call() should not be interruptible by Ctrl-C. However the following code, which spends most of its time inside mkChar, turned out to be interruptible on RH-7.3 R-1.8.1 gcc-2.96: #include <Rinternals.h> #include <R.h> SEXP foo0(const SEXP nSexp) { int i, n; SEXP resSexp; if (!isInteger(nSexp))
2004 Nov 22
1
patch to fix non-echo tty on scp SIGINT
A long-time missing feature (or bug, depending on how you look at it) is that a Ctrl-C at the password prompt in scp does not restore the terminal settings, thus dropping you to the command prompt without any keyboard echo. (A "reset" command will fix it.) This is a pretty regular occurance for me, and some others I've talked to - usually when you realize that the scp command you
2007 Oct 02
3
[PATCH] SIGTERM and SIGINT handler to flush xentop -b outputs
# HG changeset patch # User inakoshi.hiroya@jp.fujitsu.com # Date 1191287395 -28800 # Node ID 5543e74774a826b1781893982ed5052312b820fc # Parent 83239b2890723e0c06bad507bb273a970784b18e Flush stdout when xentop -b gets SIGINT and SIGTERM. It is useful when you stop xentop -b by keyboard interrupt or by other programs such as killall from a batch script. You would have missed the bottom part of
2009 Dec 29
1
Error Code: 20. Error Desc: Received SIGUSR1 or SIGINT
Hi Rsync Support, Recently we encountered issue on our prod environment because the rsync seems hanging, it took time building the list.Previously the rsync process was working before 10:24am not until 10:25am. See sample log below. We have one source server and the data files will be rsync to 2 webservers. Please advise what could be the cause of the issue. Please let me know if you need
2004 Dec 03
1
Getting R to emit an image file as a pipe or Base64 strea m: Mac OSX 10.3 - R 2.0.1
> From: Yuandan Zhang > > If you want to call R from perl, why don't you do a simple > system call like: > > $callR="/usr/loca/bin/R CMD BATCH plotscript.R"; > system ($callR); > > It is not necessary to start X display if anything can be > done in background But the problem is jpeg()/png() are not available unless an X display is available to the
2004 Dec 03
1
Getting R to emit an image file as a pipe or Base64 stream: Mac OSX 10.3 - R 2.0.1
Hi All, Anybody know how to make R emit base64 encoded text in some way that perl can grab it, instead of planting a file on your harddrive when calling JPEG or PNG? I've managed to get these scripts to work and put a file on the harddisk #!/usr/bin/perl -Wall # by jin kee. a simple script to demonstrate # the needed steps to get R to emit a jpeg. use strict; my($callR, $callRold); # need
2007 Apr 13
1
spec''ing out a trap/SIGINT
How would you spec out a call to Signal.trap (a ^C or a unix SIGINT)? Scott
2014 Jan 16
1
SIGINT is a bad choice for changing log levels
Guus, I would like to ask you to reconsider using SIGINT for logging change. It?s a pain to kill tincd when started from the command line. Ctrl-C does not work as expected. Great for debugging perhaps, but in normal use cases, when trying to make a connection work and test changes it?s a pain. On BSD there is SIGINFO (29), which can be sent by pressing Ctrl-T, but I am not sure whether that
2008 Apr 14
1
clean-up actions after non-local exits
Dear R-devel, Some time ago I started a thread that boiled down to clean-up actions after non-local exits in R, see below. I wonder if there has been any progress on this? R-ext 2.6.1 doesn't say much on the subject. How, for example, do people deal with a situation where their C (C++) function opens a file and then receives a signal or longjump-s on error(), how do they make sure the