inla.qsample failing (it might be R4.0, it might be macOS High Sierra?)

262 views
Skip to first unread message

Daniel Simpson

unread,
May 5, 2020, 1:25:29 PM5/5/20
to R-inla discussion group
Hi everyone,

I've hit an annoying problem with the current version of INLA (testing version downloaded this morning).

> Q = INLA:::inla.rw1(100) + Diagonal(100)
> x = inla.qsample(n=1, Q=Q)
dyld: lazy symbol binding failed: Symbol not found: _dtrsm_
  Referenced from: /Library/Frameworks/R.framework/Versions/4.0/Resources/library/INLA/bin/mac/64bit/inla (which was built for Mac OS X 10.14)
  Expected in: /Library/Frameworks/R.framework/Versions/4.0/Resources/library/INLA/bin/mac/64bit/../../pardiso/libnopardiso/mac/libpardiso600-MACOS-X86-64-RINLA.dylib

dyld: Symbol not found: _dtrsm_
  Referenced from: /Library/Frameworks/R.framework/Versions/4.0/Resources/library/INLA/bin/mac/64bit/inla (which was built for Mac OS X 10.14)
  Expected in: /Library/Frameworks/R.framework/Versions/4.0/Resources/library/INLA/bin/mac/64bit/../../pardiso/libnopardiso/mac/libpardiso600-MACOS-X86-64-RINLA.dylib

Error in file(rng.file, "rb") : cannot open the connection
In addition: Warning message:
In file(rng.file, "rb") :
  cannot open file '/var/folders/0d/jv983_5x6lq1b9qxd7zx3jjc0000gn/T//RtmpYzyPje/file10c2139cb3d48/file10c216499ae0e': No such file or directory

My strong suspicion is it's a mismatch between the binary and my system. Should I upgrade my OS or downgrade my R? (Relevant sessionInfo() below)

Thanks!

Dan

> sessionInfo()
R version 4.0.0 (2020-04-24)
Platform: x86_64-apple-darwin17.0 (64-bit)
Running under: macOS High Sierra 10.13.6

Helpdesk

unread,
May 5, 2020, 1:44:05 PM5/5/20
to Daniel Simpson, R-inla discussion group
its an error on Mac due to an upgrade in a compiler. That version have
been recompiled with a fix, so just remove the package, and install it
again

H

On Tue, 2020-05-05 at 10:25 -0700, Daniel Simpson wrote:
> Hi everyone,
>
> I've hit an annoying problem with the current version of INLA
> (testing version downloaded this morning).
>
> > Q = INLA:::inla.rw1(100) + Diagonal(100)
> > x = inla.qsample(n=1, Q=Q)
> dyld: lazy symbol binding failed: Symbol not found: _dtrsm_
> Referenced from:
> /Library/Frameworks/R.framework/Versions/4.0/Resources/library/INLA/b
> in/mac/64bit/inla (which was built for Mac OS X 10.14)
> Expected in:
> /Library/Frameworks/R.framework/Versions/4.0/Resources/library/INLA/b
> in/mac/64bit/../../pardiso/libnopardiso/mac/libpardiso600-MACOS-X86-
> 64-RINLA.dylib
>
> dyld: Symbol not found: _dtrsm_
> Referenced from:
> /Library/Frameworks/R.framework/Versions/4.0/Resources/library/INLA/b
> in/mac/64bit/inla (which was built for Mac OS X 10.14)
> Expected in:
> /Library/Frameworks/R.framework/Versions/4.0/Resources/library/INLA/b
> in/mac/64bit/../../pardiso/libnopardiso/mac/libpardiso600-MACOS-X86-
> 64-RINLA.dylib
>
> Error in file(rng.file, "rb") : cannot open the connection
> In addition: Warning message:
> In file(rng.file, "rb") :
> cannot open file
> '/var/folders/0d/jv983_5x6lq1b9qxd7zx3jjc0000gn/T//RtmpYzyPje/file10c
> 2139cb3d48/file10c216499ae0e': No such file or directory
>
> My strong suspicion is it's a mismatch between the binary and my
> system. Should I upgrade my OS or downgrade my R? (Relevant
> sessionInfo() below)
>
> Thanks!
>
> Dan
>
> > sessionInfo()
> R version 4.0.0 (2020-04-24)
> Platform: x86_64-apple-darwin17.0 (64-bit)
> Running under: macOS High Sierra 10.13.6
>
> --
> You received this message because you are subscribed to the Google
> Groups "R-inla discussion group" group.
> To unsubscribe from this group and stop receiving emails from it,
> send an email to r-inla-discussion...@googlegroups.com
> .
> To view this discussion on the web, visit
> https://groups.google.com/d/msgid/r-inla-discussion-group/d3e9e8e8-2ab6-4167-92fe-fb86703f3748%40googlegroups.com
> .
--
Håvard Rue
Helpdesk
he...@r-inla.org

Daniel Simpson

unread,
May 5, 2020, 2:31:39 PM5/5/20
to INLA help, R-inla discussion group
Hi Håvard,
It works just using the standard download script for the stable branch, but not for the testing branch.

With the testing branch I get
> r <- inla(y~1, data = list(y = rnorm(10)))
dyld: lazy symbol binding failed: Symbol not found: _dtrsm_
  Referenced from: /Library/Frameworks/R.framework/Versions/4.0/Resources/library/INLA/bin/mac/64bit/inla (which was built for Mac OS X 10.14)
  Expected in: /Library/Frameworks/R.framework/Versions/4.0/Resources/library/INLA/bin/mac/64bit/../../pardiso/libnopardiso/mac/libpardiso600-MACOS-X86-64-RINLA.dylib

dyld: Symbol not found: _dtrsm_
  Referenced from: /Library/Frameworks/R.framework/Versions/4.0/Resources/library/INLA/bin/mac/64bit/inla (which was built for Mac OS X 10.14)
  Expected in: /Library/Frameworks/R.framework/Versions/4.0/Resources/library/INLA/bin/mac/64bit/../../pardiso/libnopardiso/mac/libpardiso600-MACOS-X86-64-RINLA.dylib

sh: line 1: 70107 Abort trap: 6           '/Library/Frameworks/R.framework/Versions/4.0/Resources/library/INLA/bin/mac/64bit/inla.run' -b -s -v -t 4 '/private/var/folders/0d/jv983_5x6lq1b9qxd7zx3jjc0000gn/T/RtmpWJFCNF/file110f14ced742/Model.ini' > '/private/var/folders/0d/jv983_5x6lq1b9qxd7zx3jjc0000gn/T/RtmpWJFCNF/file110f14ced742/Logfile.txt'
Error in inla.inlaprogram.has.crashed() : 
  The inla-program exited with an error. Unless you interupted it yourself, please rerun with verbose=TRUE and check the output carefully.
  If this does not help, please contact the developers at <he...@r-inla.org>.

D

Daniel Simpson

unread,
May 5, 2020, 2:33:38 PM5/5/20
to INLA help, R-inla discussion group
The "(which was built for Mac OS X 10.14)" messages in the error make me strongly suggest I need to update my OS.

D

Helpdesk

unread,
May 5, 2020, 2:48:59 PM5/5/20
to Daniel Simpson, R-inla discussion group
On Tue, 2020-05-05 at 14:31 -0400, Daniel Simpson wrote:
> Hi Håvard,
> It works just using the standard download script for the stable
> branch, but not for the testing branch.
>

hmm, it was fixed, but now its not. let me check again...

Helpdesk

unread,
May 5, 2020, 4:00:42 PM5/5/20
to Daniel Simpson, R-inla discussion group
Should be fine now. just remove the install INLA package and install
the testing version again.

Cici Chen

unread,
Mar 18, 2021, 10:22:24 PM3/18/21
to R-inla discussion group
I am having exactly the same problem! And it looks like I am among the rare ones having this problem and cannot really find a solution, despite a long search. 

I decided to run some time-consuming analysis on an older iMac with macOS High Sierra. Because of the specs there was no way for me to upgrade the OS so I am stuck with it. Now INLA won't run and I believe it is a problem with incompatible libraries. I have tried to install/uninstall Rstudio, R, and INLA (stable and testing versions both). Also tried to install INLA directly in R and not R studio (which was suggested in another discussion thread). Nothing worked. 

Is there a solution to this? My session info and INLA error messages are attached below. Many thanks!

> sessionInfo()
R version 4.0.4 (2021-02-15)
Platform: x86_64-apple-darwin17.0 (64-bit)
Running under: macOS High Sierra 10.13.6

Matrix products: default
BLAS:   /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/4.0/Resources/lib/libRlapack.dylib

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

attached base packages:
[1] parallel  stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
[1] INLA_21.03.17 sp_1.4-5      foreach_1.5.1 Matrix_1.3-2 

loaded via a namespace (and not attached):
[1] compiler_4.0.4     tools_4.0.4        MatrixModels_0.5-0 splines_4.0.4      codetools_0.2-18  
[6] grid_4.0.4         iterators_1.0.13   lattice_0.20-41   
> result = inla(formula, family = "gaussian", data = data)
dyld: lazy symbol binding failed: Symbol not found: ____chkstk_darwin
  Referenced from: /Library/Frameworks/R.framework/Versions/4.0/Resources/library/INLA/bin/mac/64bit/first/libjemalloc.2.dylib (which was built for Mac OS X 10.15)
  Expected in: /usr/lib/libSystem.B.dylib

dyld: Symbol not found: ____chkstk_darwin
  Referenced from: /Library/Frameworks/R.framework/Versions/4.0/Resources/library/INLA/bin/mac/64bit/first/libjemalloc.2.dylib (which was built for Mac OS X 10.15)
  Expected in: /usr/lib/libSystem.B.dylib

dyld: lazy symbol binding failed: Symbol not found: ____chkstk_darwin
  Referenced from: /Library/Frameworks/R.framework/Versions/4.0/Resources/library/INLA/bin/mac/64bit/first/libjemalloc.2.dylib (which was built for Mac OS X 10.15)
  Expected in: /usr/lib/libSystem.B.dylib

dyld: Symbol not found: ____chkstk_darwin
  Referenced from: /Library/Frameworks/R.framework/Versions/4.0/Resources/library/INLA/bin/mac/64bit/first/libjemalloc.2.dylib (which was built for Mac OS X 10.15)
  Expected in: /usr/lib/libSystem.B.dylib

sh: line 1: 76791 Abort trap: 6           '/Library/Frameworks/R.framework/Versions/4.0/Resources/library/INLA/bin/mac/64bit/inla.run' -b -s -v -t4:1 -B0 '/private/var/folders/fx/pfw7fc7d1tnc9z1k9bntmhzr0000gn/T/RtmpSL4Ce0/file1298a172eec75/Model.ini' > '/private/var/folders/fx/pfw7fc7d1tnc9z1k9bntmhzr0000gn/T/RtmpSL4Ce0/file1298a172eec75/Logfile.txt'
Error in inla.inlaprogram.has.crashed() : 
  The inla-program exited with an error. Unless you interupted it yourself, please rerun with verbose=TRUE and check the output carefully.
  If this does not help, please contact the developers at <he...@r-inla.org>.

Helpdesk

unread,
Mar 19, 2021, 5:17:40 AM3/19/21
to Cici Chen, R-inla discussion group

yes, its an OS issue. I have two availble macs, running 10.14.6 ,
10.15.5. I usually compile on 10.15.5, which is second most recent OS
(which is 11.xx)

as long as I do not have access to a Mac running 10.13 I cannot compile
on it.

it seems that the issue it complains about, is the jemalloc library,
which can be removed. let me check and come back to you

Best
H
he...@r-inla.org
Screenshot from 2021-03-19 12-10-12.png

Cici Chen

unread,
Mar 22, 2021, 10:30:03 AM3/22/21
to R-inla discussion group
In case this might help with other uses. 

If you have issues of running INLA on macOS High Sierra, can install INLA but have the following error message when running INLA:
"dyld: lazy symbol binding failed: Symbol not found: ____chkstk_darwin
  Referenced from: /Library/Frameworks/R.framework/Versions/4.0/Resources/library/INLA/bin/mac/64bit/first/libjemalloc.2.dylib (which was built for Mac OS X 10.15)
  Expected in: /usr/lib/libSystem.B.dylib"

Please install the most recent version of INLA (Version_21.03.20) and try the following in R (by setting mkl=FALSE). It should be working just fine.
library(INLA)
inla.setOption(mkl=FALSE)

milind sharma

unread,
Oct 30, 2021, 4:23:37 PM10/30/21
to R-inla discussion group

Thanks for the suggestion above. I am currently trying to run an INLA code on MacOS High Sierra and got the same error even after `inla.setOption(mkl=FALSE)`

```
dyld: lazy symbol binding failed: Symbol not found: ____chkstk_darwin
  Referenced from: /Library/Frameworks/R.framework/Versions/4.1/Resources/library/INLA/bin/mac/64bit/first/libjemalloc.2.dylib (which was built for Mac OS X 10.15)
  Expected in: /usr/lib/libSystem.B.dylib
```

Here is the sessionInfo() output:

```
sessionInfo()
R version 4.1.1 (2021-08-10)
Platform: x86_64-apple-darwin17.0 (64-bit)
Running under: macOS High Sierra 10.13.6

Matrix products: default
BLAS:   /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/4.1/Resources/lib/libRlapack.dylib

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

attached base packages:
[1] grid      parallel  stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
 [1] lubridate_1.8.0   forcats_0.5.1     stringr_1.4.0     dplyr_1.0.7       purrr_0.3.4       readr_2.0.2       tidyr_1.1.4       tibble_3.1.5      ggplot2_3.3.5    
[10] tidyverse_1.3.1   lattice_0.20-44   abind_1.4-5       fields_13.3       viridis_0.6.2     viridisLite_0.4.0 spam_2.7-0        dotCall64_1.0-1   INLA_21.02.23    
[19] sp_1.4-5          foreach_1.5.1     Matrix_1.3-4     

loaded via a namespace (and not attached):
 [1] httr_1.4.2         maps_3.4.0         bit64_4.0.5        vroom_1.5.5        jsonlite_1.7.2     splines_4.1.1      modelr_0.1.8       assertthat_0.2.1   cellranger_1.1.0  
[10] yaml_2.2.1         pillar_1.6.4       backports_1.3.0    glue_1.4.2         digest_0.6.28      rvest_1.0.2        colorspace_2.0-2   htmltools_0.5.2    pkgconfig_2.0.3   
[19] broom_0.7.9        haven_2.4.3        scales_1.1.1       tzdb_0.2.0         MatrixModels_0.5-0 generics_0.1.1     ellipsis_0.3.2     withr_2.4.2        cli_3.1.0         
[28] magrittr_2.0.1     crayon_1.4.2       readxl_1.3.1       evaluate_0.14      fs_1.5.0           fansi_0.5.0        xml2_1.3.2         tools_4.1.1        hms_1.1.1         
[37] lifecycle_1.0.1    munsell_0.5.0      reprex_2.0.1       compiler_4.1.1     rlang_0.4.12       iterators_1.0.13   rstudioapi_0.13    rmarkdown_2.11     gtable_0.3.0      
[46] codetools_0.2-18   DBI_1.1.1          R6_2.5.1           splancs_2.01-42    gridExtra_2.3      knitr_1.36         rgdal_1.5-27       fastmap_1.1.0      bit_4.0.4         
[55] utf8_1.2.2         stringi_1.7.5      Rcpp_1.0.7         vctrs_0.3.8        dbplyr_2.1.1       tidyselect_1.1.1   xfun_0.27
```

Helpdesk

unread,
Oct 30, 2021, 4:25:39 PM10/30/21
to milind sharma, R-inla discussion group

you are running on an (very) old version of MacOS. We are currently
compiling for

kw-16659:~ rueh$ sw_vers
ProductName: Mac OS X
ProductVersion: 10.15.7
BuildVersion: 19H1519


and you have 10.13.

If you upgrade you'll be fine.
> > /Library/Frameworks/R.framework/Versions/4.0/Resources/library/INLA/bi
> > n/mac/64bit/first/libjemalloc.2.dylib (which was built for Mac OS X
> > 10.15)
> >   Expected in: /usr/lib/libSystem.B.dylib"
> >

Helpdesk

unread,
Oct 30, 2021, 4:28:14 PM10/30/21
to milind sharma, R-inla discussion group
this version is still 'old' compared to version 11 & the recent 12


On Sat, 2021-10-30 at 23:25 +0300, Helpdesk wrote:
>
> you are running on an (very) old version of MacOS. We are currently
> compiling for
>
> kw-16659:~ rueh$ sw_vers
> ProductName:    Mac OS X
> ProductVersion: 10.15.7
> BuildVersion:   19H1519
>
>
> and you have 10.13.
>
> If you upgrade you'll be fine.
>
>
>
>
> On Sat, 2021-10-30 at 13:23 -0700, milind sharma wrote:
> >
> > Thanks for the suggestion above. I am currently trying to run an
> > INLA
> > code on MacOS High Sierra and got the same error even after
> > `inla.setOption(mkl=FALSE)`
> >
> > ```
> > dyld: lazy symbol binding failed: Symbol not found:
> > ____chkstk_darwin
> >   Referenced from:
> > /Library/Frameworks/R.framework/Versions/4.1/Resources/library/INLA/
> > bin/
> > mac/64bit/first/libjemalloc.2.dylib (which was built for Mac OS X
> > 10.15)
> >   Expected in: /usr/lib/libSystem.B.dylib
> > ```
> >
> > Here is the sessionInfo() output:
> >
> > ```
> > sessionInfo()
> > R version 4.1.1 (2021-08-10)
> > Platform: x86_64-apple-darwin17.0 (64-bit)
> > Running under: macOS High Sierra 10.13.6
> >
> > Matrix products: default
> > BLAS: 
> >  /System/Library/Frameworks/Accelerate.framework/Versions/A/Framewor
> > ks/v
> > ecLib.framework/Versions/A/libBLAS.dylib
> > LAPACK:
> > /Library/Frameworks/R.framework/Versions/4.1/Resources/lib/libRlapac
> > k.dy
> > lib
> >
> > locale:
> > [1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
> >
> > > /Library/Frameworks/R.framework/Versions/4.0/Resources/library/INL
> > > A/bi

milind sharma

unread,
Oct 30, 2021, 4:34:32 PM10/30/21
to R-inla discussion group
Nevermind, I realized I had INLA version 21.02.23 and just upgraded using inla.upgrade(testing=TRUE). It works now :)

Thanks!

Helpdesk

unread,
Oct 30, 2021, 4:36:07 PM10/30/21
to milind sharma, R-inla discussion group

good to hear!
Reply all
Reply to author
Forward
0 new messages