(This message was already forwarded to bibiko@eva.mpg.de)
Hello -
I recently upgraded my OS and started having strange problems with the R bundle. Multiple helper daemons would be spawned every time I typed in a function name!
The problem code is patched below. I use MacPorts' "R", which does not match the "/Lib.*" regexp. Instead, it should match "/opt/local/lib/R/bin/exec/R". Any other patch should work as well.
Without the patch, every time there is an error with the "help" function, a new "R" is spawned; (see the attached as an example). I had over 20 processes running at once, and was wondering why my fans were on and my system was slow... :-)
Thanks! -Andrew.
-- Andrew D. Fernandes, Ph.D. (andrew@fernandes.org) Departments of Biochemistry and Applied Mathematics The University of Western Ontario, Canada Mobile Telephone +1 519 614 8106
Index: Bundles/R.tmbundle/Support/bin/startRhelperDaemon.sh =================================================================== --- Bundles/R.tmbundle/Support/bin/startRhelperDaemon.sh (revision 11908) +++ Bundles/R.tmbundle/Support/bin/startRhelperDaemon.sh (working copy) @@ -1,4 +1,4 @@ -RPID=$(ps aw | grep '[0-9] /Lib.*TMRHelperDaemon' | awk '{print $1}' ) +RPID=$(ps aw | egrep '[0-9] (/Lib.*TMRHelperDaemon)|(/opt/.*TMRHelperDaemon)' | awk '{print $1}' ) #check whether Helper daemon runs if not start it if [ -z "$RPID" ]; then WDIR="$TM_BUNDLE_SUPPORT"/bin
On 21.01.2010, at 18:10, Andrew Fernandes wrote:
I recently upgraded my OS and started having strange problems with the R bundle. Multiple helper daemons would be spawned every time I typed in a function name!
The problem code is patched below. I use MacPorts' "R", which does not match the "/Lib.*" regexp. Instead, it should match "/opt/local/lib/R/bin/exec/R". Any other patch should work as well.
Without the patch, every time there is an error with the "help" function, a new "R" is spawned; (see the attached as an example). I had over 20 processes running at once, and was wondering why my fans were on and my system was slow... :-)
Hi Andrew,
your're the first who installed R in a different location. But I agree, I'll try to make it universal for all locations.
Thanks and cheers,
--Hans
Hi Andrew,
just committed a fix to generalize this query for all locations hopefully ;)
Again, thanks for the hint.
Cheers, --Hans
On 21 Jan 2010, at 18:28, Hans-Jörg Bibiko wrote:
The problem code is patched below. I use MacPorts' "R", which does not match the "/Lib.*" regexp. Instead, it should match "/opt/local/ lib/R/bin/exec/R". Any other patch should work as well.
your're the first who installed R in a different location. But I agree, I'll try to make it universal for all locations.
Yes, I've never seen that before either. Being an R user myself, I'd be interested to hear your reasons for installing R from MacPorts, which is almost guaranteed to be inferior to the official binary distribution (and less easy to install).
I haven't tried MacPort's R myself, but I suspect that it's just a slightly adapted Unix build, whereas the R Core Team puts a lot of effort into compiling R for Mac OS X with the right tools and settings to get optimal performance and reliable operation on all current OS X platforms.
Just curious, Stefan