bioconductor packages fail R4.0

Hi there,

I have been trying to install a Bioconductor package ("dada2") in this project which I had no problem installing in a previous project that was running in R3.6. The first round of error messages came from not being able to install the dependency "ShortRead" also from Bioconductor which I overcame by installing a tarball directly.
The second problem came with the failed update of 4 CRAN packages, MASS, mgcv, nlme and survival. The full error message was:
ERROR: lazy loading failed for package ‘dada2’
* removing ‘/home/rstudio-user/R/x86_64-pc-linux-gnu-library/4.0/dada2’

The downloaded source packages are in
Installation path not writeable, unable to update packages:
MASS, mgcv, nlme, survival

I installed manually those packages and tried again with the flag update = F
so I tried with
BiocManager::install("dada2", version = "3.11", update = F)
Also with the tarball
In all cases the error is
installing to /home/rstudio-user/R/x86_64-pc-linux-gnu-library/4.0/00LOCK-dada2-1.16/00new/dada2/libs
** R
** data
*** moving datasets to lazyload DB
** inst
** byte-compile and prepare package for lazy loading
ERROR: lazy loading failed for package ‘dada2’

Any suggestions on how to proceed?

If the package requires a system library that isn't pre-installed, it can be expected to fail this way.

There are some R packages that require system libraries. If you’re using a package that uses a system library that is not available in RStudio Cloud, you won’t be able to use that package as currently it’s not possible for users to install these. We recommend posting this on RStudio Community as a request to install the system library and the RStudio Cloud team should be able to help. to fail this way. See this post

Hi @rgallego!

the Killed keyword there to me implied that your project was potentially running out of memory while compiling the package. I've confirmed that to be the case -- I was able to successfully install this package in a new project using only:


after setting my project resources to have 4GB of ram accessible. You may not need 4GB of ram for this to be successful and could try first with 2GB of ram. Please note that at this time, you need a subscription to set the amount of resources required for your project above 1CPU/1GB ram.

1 Like

Thanks Steven - Managed to do so with increasing the RAM to 2GB.

1 Like

Thanks for the hint - Luckily I could solved it by increasing the allocated RAM

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.