Good morning. I have a real fuzzy question to ask; we have a calculation engine which is composed by n virtual machines each of them with a jvm 2GB of memory on Linux Red Hat each of them with the "R" package which comes along with the Red Hat Linux distribution. We have now to increase the number of "nodes" trying to avoid to use new virtual or physical machines. So my question is: is it possible to install multiple jvm on the same machine each of them with its independent instance of R ? Should I "duplicate" the initial R installation to get different instances with different libraries ? Is it enough or even in this case the different instances "share" something so they are not really "fully independent" ? Thanks so much for you help Angelo Linardi ** Le e-mail provenienti dalla Banca d'Italia sono trasmesse in buona fede e non comportano alcun vincolo ne' creano obblighi per la Banca stessa, salvo che cio' non sia espressamente previsto da un accordo scritto. Questa e-mail e' confidenziale. Qualora l'avesse ricevuta per errore, La preghiamo di comunicarne via e-mail la ricezione al mittente e di distruggerne il contenuto. La informiamo inoltre che l'utilizzo non autorizzato del messaggio o dei suoi allegati potrebbe costituire reato. Grazie per la collaborazione. -- E-mails from the Bank of Italy are sent in good faith but they are neither binding on the Bank nor to be understood as creating any obligation on its part except where provided for in a written agreement. This e-mail is confidential. If you have received it by mistake, please inform the sender by reply e-mail and delete it from your system. Please also note that the unauthorized disclosure or use of the message or any attachments could be an offence. Thank you for your cooperation. **
R: Securities earning covariance
8 messages · Oliver Ruebenacker, ANGELO.LINARDI at bancaditalia.it, R. Michael Weylandt
I'm somewhat confused: i) What does this have to do with your subject line? ii) There does not exist -- to my knowledge -- an implementation of R which runs on the JVM. iii) Have you simply looked into R's native parallel computing options? That seems to be (maybe?) what you are trying to do. Incidentally, thanks to the in-memory model, it is possible to spawn multiple R processes which use the same package libraries [the package is the thing in the library, which is tied to the filesystem] on the same machine (I'm thinking real, but this shouldn't be a problem with a reasonable VM setup either) Michael
On Fri, Jun 15, 2012 at 3:05 AM, <ANGELO.LINARDI at bancaditalia.it> wrote:
Good morning. I have a real fuzzy question to ask; we have a calculation engine which is composed by n virtual machines each of them with a jvm 2GB of memory on Linux Red Hat each of them with the "R" package which comes along with the Red Hat Linux distribution. We have now to increase the number of "nodes" trying to avoid to use new virtual or physical machines. So my question is: is it possible to install multiple jvm on the same machine each of them with its independent instance of R ? Should I "duplicate" the initial R installation to get different instances with different libraries ? Is it enough or even in this case the different instances "share" something so they are not really "fully independent" ? Thanks so much for you help Angelo Linardi ** Le e-mail provenienti dalla Banca d'Italia sono trasmesse in buona fede e non comportano alcun vincolo ne' creano obblighi per la Banca stessa, salvo che cio' non sia espressamente previsto da un accordo scritto. Questa e-mail e' confidenziale. Qualora l'avesse ricevuta per errore, La preghiamo di comunicarne via e-mail la ricezione al mittente e di distruggerne il contenuto. La informiamo inoltre che l'utilizzo non autorizzato del messaggio o dei suoi allegati potrebbe costituire reato. Grazie per la collaborazione. -- E-mails from the Bank of Italy are sent in good faith but they are neither binding on the Bank nor to be understood as creating any obligation on its part except where provided for in a written agreement. This e-mail is confidential. If you have received it by mistake, please inform the sender by reply e-mail and delete it from your system. Please also note that the unauthorized disclosure or use of the message or any attachments could be an offence. Thank you for your cooperation. **
______________________________________________ R-help at r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.
Hello, On Fri, Jun 15, 2012 at 10:15 AM, R. Michael Weylandt
<michael.weylandt at gmail.com> wrote:
ii) There does not exist -- to my knowledge -- an implementation of R which runs on the JVM.
I think he means driving the R framework from Java via JNI. I think
the questions boils down to whether you can open multiple independent
R sessions on the same system and then address them separately via JNI
(I don't know, but I would assume you can do that without multiplying
the installation).
Take care
Oliver
Oliver Ruebenacker Bioinformatics Consultant (http://www.knowomics.com/wiki/Oliver_Ruebenacker) Knowomics, The Bioinformatics Network (http://www.knowomics.com) SBPAX: Turning Bio Knowledge into Math Models (http://www.sbpax.org)
Hello,
first of all tank to both of you for your fast response.
Going back to Michael's wonderful ASCII art masterpiece, what we have now is something like this:
------- JVM -----------
---- JAVA ----
JDBC
|
|
Algorithm
|
---- JAVA ----
------- JVM -----------
|
RNI
|
R
What we want is something like the following (on the same virtual machine):
------- JVM1 ----------- ------- JVM2 -----------
---- JAVA ---- ---- JAVA ----
JDBC JDBC
| |
| |
Algorithm Algorithm
| |
---- JAVA ---- ---- JAVA ----
------- JVM1 ----------- ------- JVM2 -----------
| |
RNI RNI
| |
R(1) R(2)
My question is: is that possible ? How can I address R(1) from JVM1 and R(2) from JVM2 ? Is data calculated in R(1) and R(2) completely independent or the 2 instances "share" something in memory ?
Thanks again for you kindness and help.
Angelo
-----Messaggio originale-----
Da: Oliver Ruebenacker [mailto:curoli at gmail.com]
Inviato: venerd? 15 giugno 2012 17.36
A: R. Michael Weylandt
Cc: LINARDI ANGELO; r-help at r-project.org
Oggetto: Re: [R] R: Securities earning covariance
Hello,
On Fri, Jun 15, 2012 at 10:15 AM, R. Michael Weylandt
<michael.weylandt at gmail.com> wrote:
ii) There does not exist -- to my knowledge -- an implementation of R which runs on the JVM.
I think he means driving the R framework from Java via JNI. I think
the questions boils down to whether you can open multiple independent
R sessions on the same system and then address them separately via JNI
(I don't know, but I would assume you can do that without multiplying
the installation).
Take care
Oliver
Oliver Ruebenacker Bioinformatics Consultant (http://www.knowomics.com/wiki/Oliver_Ruebenacker) Knowomics, The Bioinformatics Network (http://www.knowomics.com) SBPAX: Turning Bio Knowledge into Math Models (http://www.sbpax.org) ** Le e-mail provenienti dalla Banca d'Italia sono trasmesse in buona fede e non comportano alcun vincolo ne' creano obblighi per la Banca stessa, salvo che cio' non sia espressamente previsto da un accordo scritto. Questa e-mail e' confidenziale. Qualora l'avesse ricevuta per errore, La preghiamo di comunicarne via e-mail la ricezione al mittente e di distruggerne il contenuto. La informiamo inoltre che l'utilizzo non autorizzato del messaggio o dei suoi allegati potrebbe costituire reato. Grazie per la collaborazione. -- E-mails from the Bank of Italy are sent in good faith but they are neither binding on the Bank nor to be understood as creating any obligation on its part except where provided for in a written agreement. This e-mail is confidential. If you have received it by mistake, please inform the sender by reply e-mail and delete it from your system. Please also note that the unauthorized disclosure or use of the message or any attachments could be an offence. Thank you for your cooperation. **
Hello,
first of all thanks to both of you for your fast response.
Going back to Michael's wonderful ASCII art masterpiece, what we have now is something like this:
------- JVM -----------
---- JAVA ----
JDBC
|
|
Algorithm
|
---- JAVA ----
------- JVM -----------
|
RNI
|
R
What we want is something like the following (on the same virtual machine):
------- JVM1 ----------- ------- JVM2 -----------
---- JAVA ---- ---- JAVA ----
JDBC JDBC
| |
| |
Algorithm Algorithm
| |
---- JAVA ---- ---- JAVA ----
------- JVM1 ----------- ------- JVM2 -----------
| |
RNI RNI
| |
R(1) R(2)
My question is: is that possible ? How can I address R(1) from JVM1 and R(2) from JVM2 ? Is data calculated in R(1) and R(2) completely independent or the 2 instances "share" something in memory ?
Thanks again for you kindness and help.
Angelo
-----Messaggio originale-----
Da: Oliver Ruebenacker [mailto:curoli at gmail.com]
Inviato: venerd? 15 giugno 2012 17.36
A: R. Michael Weylandt
Cc: LINARDI ANGELO; r-help at r-project.org
Oggetto: Re: [R] R: Securities earning covariance
Hello,
On Fri, Jun 15, 2012 at 10:15 AM, R. Michael Weylandt
<michael.weylandt at gmail.com> wrote:
ii) There does not exist -- to my knowledge -- an implementation of R which runs on the JVM.
I think he means driving the R framework from Java via JNI. I think
the questions boils down to whether you can open multiple independent
R sessions on the same system and then address them separately via JNI
(I don't know, but I would assume you can do that without multiplying
the installation).
Take care
Oliver
Oliver Ruebenacker Bioinformatics Consultant (http://www.knowomics.com/wiki/Oliver_Ruebenacker) Knowomics, The Bioinformatics Network (http://www.knowomics.com) SBPAX: Turning Bio Knowledge into Math Models (http://www.sbpax.org) ** Le e-mail provenienti dalla Banca d'Italia sono trasmesse in buona fede e non comportano alcun vincolo ne' creano obblighi per la Banca stessa, salvo che cio' non sia espressamente previsto da un accordo scritto. Questa e-mail e' confidenziale. Qualora l'avesse ricevuta per errore, La preghiamo di comunicarne via e-mail la ricezione al mittente e di distruggerne il contenuto. La informiamo inoltre che l'utilizzo non autorizzato del messaggio o dei suoi allegati potrebbe costituire reato. Grazie per la collaborazione. -- E-mails from the Bank of Italy are sent in good faith but they are neither binding on the Bank nor to be understood as creating any obligation on its part except where provided for in a written agreement. This e-mail is confidential. If you have received it by mistake, please inform the sender by reply e-mail and delete it from your system. Please also note that the unauthorized disclosure or use of the message or any attachments could be an offence. Thank you for your cooperation. **
On Fri, Jun 15, 2012 at 11:03 AM, <ANGELO.LINARDI at bancaditalia.it> wrote:
Hello, first of all thanks to both of you for your fast response. Going back to Michael's wonderful ASCII art masterpiece, what we have now is something like this: ------- ?JVM ----------- ? ---- ?JAVA ?---- ? ? ? ? ?JDBC ? ? ? ? ? ? ? | ? ? ? ? ? ? ? | ? ? ? ?Algorithm ? ? ? ? ? ? ? | ? ?---- JAVA ---- ------- ?JVM ----------- ? ? ? ? ? ? ?| ? ? ? ? ? RNI ? ? ? ? ? ? ?| ? ? ? ? ? ? R What we want is something like the following (on the same virtual machine): ------- ?JVM1 ----------- ? ? ? ? ? ? ? ? ? ? ? ------- ?JVM2 ----------- ? ---- ?JAVA ?---- ? ? ? ? ? ? ? ? ? ? ? ? ? ? ---- ?JAVA ?---- ? ? ? ? ?JDBC ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?JDBC ? ? ? ? ? ? ? | ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?| ? ? ? ? ? ? ? | ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?| ? ? ? ?Algorithm ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? Algorithm ? ? ? ? ? ? ? | ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?| ? ?---- JAVA ---- ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?---- JAVA ---- ------- ?JVM1 ----------- ? ? ? ? ? ? ? ? ? ? ? ------- ?JVM2 ----------- ? ? ? ? ? ? ?| ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? | ? ? ? ? ? RNI ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? RNI ? ? ? ? ? ? ?| ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? | ? ? ? ? ? ? R(1) ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? R(2) My question is: is that possible ? How can I address R(1) from JVM1 and R(2) from JVM2 ? Is data calculated in R(1) and R(2) completely independent or the 2 instances "share" something in memory ?
Best I understand it (and RNI seems Windows-only so I can't verify) you have nothing to worry about. As long as you start 2 R processes (which seems to be the only thing that could happen with two JVMs) the memory should be kept independently. The only exception I can think of is that if you choose to install a new package on one R process it might be available to the other as a read-only resource (but I'm not sure even this would happen depending on how your VM handles that bit) but data integrity should be guaranteed. Michael
Thanks again for you kindness and help. Angelo -----Messaggio originale----- Da: Oliver Ruebenacker [mailto:curoli at gmail.com] Inviato: venerd? 15 giugno 2012 17.36 A: R. Michael Weylandt Cc: LINARDI ANGELO; r-help at r-project.org Oggetto: Re: [R] R: Securities earning covariance ? ? Hello, On Fri, Jun 15, 2012 at 10:15 AM, R. Michael Weylandt <michael.weylandt at gmail.com> wrote:
ii) There does not exist -- to my knowledge -- an implementation of R which runs on the JVM.
?I think he means driving the R framework from Java via JNI. I think the questions boils down to whether you can open multiple independent R sessions on the same system and then address them separately via JNI (I don't know, but I would assume you can do that without multiplying the installation). ? ? Take care ? ? Oliver -- Oliver Ruebenacker Bioinformatics Consultant (http://www.knowomics.com/wiki/Oliver_Ruebenacker) Knowomics, The Bioinformatics Network (http://www.knowomics.com) SBPAX: Turning Bio Knowledge into Math Models (http://www.sbpax.org) ** Le e-mail provenienti dalla Banca d'Italia sono trasmesse in buona fede e non comportano alcun vincolo ne' creano obblighi per la Banca stessa, salvo che cio' non sia espressamente previsto da un accordo scritto. Questa e-mail e' confidenziale. Qualora l'avesse ricevuta per errore, La preghiamo di comunicarne via e-mail la ricezione al mittente e di distruggerne il contenuto. La informiamo inoltre che l'utilizzo non autorizzato del messaggio o dei suoi allegati potrebbe costituire reato. Grazie per la collaborazione. -- E-mails from the Bank of Italy are sent in good faith but they are neither binding on the Bank nor to be understood as creating any obligation on its part except where provided for in a written agreement. This e-mail is confidential. If you have received it by mistake, please inform the sender by reply e-mail and delete it from your system. Please also note that the unauthorized disclosure or use of the message or any attachments could be an offence. Thank you for your cooperation. **
On Fri, Jun 15, 2012 at 10:35 AM, Oliver Ruebenacker <curoli at gmail.com> wrote:
? ? Hello, On Fri, Jun 15, 2012 at 10:15 AM, R. Michael Weylandt <michael.weylandt at gmail.com> wrote:
ii) There does not exist -- to my knowledge -- an implementation of R which runs on the JVM.
?I think he means driving the R framework from Java via JNI. I think the questions boils down to whether you can open multiple independent R sessions on the same system and then address them separately via JNI (I don't know, but I would assume you can do that without multiplying the installation).
Yes, that seems to be the issue at play and best I understand the set-up you get this "for free" from the in-memory model. You shouldn't need two R installations any more than you need to install the JVM twice to run two JVMs on one box. Best, Michael
? ? Take care ? ? Oliver -- Oliver Ruebenacker Bioinformatics Consultant (http://www.knowomics.com/wiki/Oliver_Ruebenacker) Knowomics, The Bioinformatics Network (http://www.knowomics.com) SBPAX: Turning Bio Knowledge into Math Models (http://www.sbpax.org)
Hello,
By RNI, do you mean the Microsoft Raw Native Interface or the
Rengine R Native Interface?
Take care
Oliver
On Fri, Jun 15, 2012 at 12:03 PM, <ANGELO.LINARDI at bancaditalia.it> wrote:
Hello, first of all thanks to both of you for your fast response. Going back to Michael's wonderful ASCII art masterpiece, what we have now is something like this: ------- ?JVM ----------- ? ---- ?JAVA ?---- ? ? ? ? ?JDBC ? ? ? ? ? ? ? | ? ? ? ? ? ? ? | ? ? ? ?Algorithm ? ? ? ? ? ? ? | ? ?---- JAVA ---- ------- ?JVM ----------- ? ? ? ? ? ? ?| ? ? ? ? ? RNI ? ? ? ? ? ? ?| ? ? ? ? ? ? R What we want is something like the following (on the same virtual machine): ------- ?JVM1 ----------- ? ? ? ? ? ? ? ? ? ? ? ------- ?JVM2 ----------- ? ---- ?JAVA ?---- ? ? ? ? ? ? ? ? ? ? ? ? ? ? ---- ?JAVA ?---- ? ? ? ? ?JDBC ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?JDBC ? ? ? ? ? ? ? | ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?| ? ? ? ? ? ? ? | ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?| ? ? ? ?Algorithm ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? Algorithm ? ? ? ? ? ? ? | ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?| ? ?---- JAVA ---- ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?---- JAVA ---- ------- ?JVM1 ----------- ? ? ? ? ? ? ? ? ? ? ? ------- ?JVM2 ----------- ? ? ? ? ? ? ?| ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? | ? ? ? ? ? RNI ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? RNI ? ? ? ? ? ? ?| ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? | ? ? ? ? ? ? R(1) ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? R(2) My question is: is that possible ? How can I address R(1) from JVM1 and R(2) from JVM2 ? Is data calculated in R(1) and R(2) completely independent or the 2 instances "share" something in memory ? Thanks again for you kindness and help. Angelo -----Messaggio originale----- Da: Oliver Ruebenacker [mailto:curoli at gmail.com] Inviato: venerd? 15 giugno 2012 17.36 A: R. Michael Weylandt Cc: LINARDI ANGELO; r-help at r-project.org Oggetto: Re: [R] R: Securities earning covariance ? ? Hello, On Fri, Jun 15, 2012 at 10:15 AM, R. Michael Weylandt <michael.weylandt at gmail.com> wrote:
ii) There does not exist -- to my knowledge -- an implementation of R which runs on the JVM.
?I think he means driving the R framework from Java via JNI. I think the questions boils down to whether you can open multiple independent R sessions on the same system and then address them separately via JNI (I don't know, but I would assume you can do that without multiplying the installation). ? ? Take care ? ? Oliver -- Oliver Ruebenacker Bioinformatics Consultant (http://www.knowomics.com/wiki/Oliver_Ruebenacker) Knowomics, The Bioinformatics Network (http://www.knowomics.com) SBPAX: Turning Bio Knowledge into Math Models (http://www.sbpax.org) ** Le e-mail provenienti dalla Banca d'Italia sono trasmesse in buona fede e non comportano alcun vincolo ne' creano obblighi per la Banca stessa, salvo che cio' non sia espressamente previsto da un accordo scritto. Questa e-mail e' confidenziale. Qualora l'avesse ricevuta per errore, La preghiamo di comunicarne via e-mail la ricezione al mittente e di distruggerne il contenuto. La informiamo inoltre che l'utilizzo non autorizzato del messaggio o dei suoi allegati potrebbe costituire reato. Grazie per la collaborazione. -- E-mails from the Bank of Italy are sent in good faith but they are neither binding on the Bank nor to be understood as creating any obligation on its part except where provided for in a written agreement. This e-mail is confidential. If you have received it by mistake, please inform the sender by reply e-mail and delete it from your system. Please also note that the unauthorized disclosure or use of the message or any attachments could be an offence. Thank you for your cooperation. **
Oliver Ruebenacker Bioinformatics Consultant (http://www.knowomics.com/wiki/Oliver_Ruebenacker) Knowomics, The Bioinformatics Network (http://www.knowomics.com) SBPAX: Turning Bio Knowledge into Math Models (http://www.sbpax.org)