lgatto / MSnbase

Base Classes and Functions for Mass Spectrometry and Proteomics
http://lgatto.github.io/MSnbase/
124 stars 50 forks source link

Segmentation fault on install #539

Closed urielrosen closed 9 months ago

urielrosen commented 3 years ago

Hi ,

Trying to install this package and getting this error :

119766 Segmentation fault | R_DEFAULT_PACKAGES= LC_COLLATE=C "${R_HOME}/bin/R" $myArgs --no-echo --args ${args}

any suggestions ?

lgatto commented 3 years ago

No, and unlikely to be able to help without any details.

Closing, but feel free to re-open if you can provide additional information.

urielrosen commented 3 years ago

Hi ,

please tell me which details are relevant in this case ? I will upload whatever you need so we can troubleshoot this .

lgatto commented 3 years ago
  1. command you ran to try to install the package
  2. output of sessionInfo()
  3. detailed error message
urielrosen commented 3 years ago
  1. BiocManager::install("MSnbase")
  2. sessionInfo()
    
    R version 4.0.0 (2020-04-24)
    Platform: x86_64-pc-linux-gnu (64-bit)
    Running under: CentOS Linux 7 (Core)

Matrix products: default BLAS: /usr/lib64/libblas.so.3.4.2 LAPACK: /apps/RH7U2/gnu/R/4.0.0/lib64/R/lib/libRlapack.so

Random number generation: RNG: Mersenne-Twister Normal: Inversion Sample: Rounding

locale: [1] LC_CTYPE=en_US.UTF-8 LC_NUMERIC=C [3] LC_TIME=en_US.UTF-8 LC_COLLATE=en_US.UTF-8 [5] LC_MONETARY=en_US.UTF-8 LC_MESSAGES=en_US.UTF-8 [7] LC_PAPER=en_US.UTF-8 LC_NAME=C [9] LC_ADDRESS=C LC_TELEPHONE=C [11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C

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

loaded via a namespace (and not attached): [1] BiocManager_1.30.10 compiler_4.0.0 tools_4.0.0

3. 

caught segfault address 0x20, cause 'memory not mapped'

Traceback: 1: Module(module, mustStart = TRUE, where = env) 2: doTryCatch(return(expr), name, parentenv, handler) 3: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 4: tryCatchList(expr, classes, parentenv, handlers) 5: tryCatch(Module(module, mustStart = TRUE, where = env), error = function(e) e) 6: loadModule("Ramp", TRUE) 7: fun(libname, pkgname) 8: doTryCatch(return(expr), name, parentenv, handler) 9: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 10: tryCatchList(expr, classes, parentenv, handlers) 11: tryCatch(fun(libname, pkgname), error = identity) 12: runHook(".onLoad", env, package.lib, package) 13: loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]]) 14: namespaceImport(ns, loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]]), from = package) 15: loadNamespace(name) 16: doTryCatch(return(expr), name, parentenv, handler) 17: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 18: tryCatchList(expr, classes, parentenv, handlers) 19: tryCatch(loadNamespace(name), error = function(e) { warning(gettextf("namespace %s is not available and has been replaced\nby .GlobalEnv when processing object %s", sQuote(name)[1L], sQuote(where)), domain = NA, call. = FALSE, immediate. = TRUE) .GlobalEnv}) 20: ..getNamespace(c("MSnbase", "1.21.8"), "itraqdata") 21: load(zfile, envir = tmp_env) 22: utils::data(list = f, package = package, lib.loc = lib.loc, envir = dataEnv, overwrite = TRUE) 23: data2LazyLoadDB(pkg_name, lib, compress = data_compress) 24: doTryCatch(return(expr), name, parentenv, handler) 25: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 26: tryCatchList(expr, classes, parentenv, handlers) 27: tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L) dcall <- deparse(call)[1L] prefix <- paste("Error in", dcall, ": ") LONG <- 75L sm <- str split(conditionMessage(e), "\n")[[1L]] w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") if (is.na(w)) w <- 1 4L + nchar(dcall, type = "b") + nchar(sm[1L], type = "b") if (w > LONG) prefix <- paste0(prefix, "\n ") } e lse prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n") .Internal(seterrmessage(msg[1L])) if (!silent && isTRUE(getOption( "show.error.messages"))) { cat(msg, file = outFile) .Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-er ror", condition = e))}) 28: try(data2LazyLoadDB(pkg_name, lib, compress = data_compress)) 29: do_install_source(pkg_name, instdir, pkg, desc) 30: do_install(pkg) 31: tools:::.install_packages() An irrecoverable exception occurred. R is aborting now ... /apps/RH7U2/gnu/R/4.0.0/lib64/R/bin/INSTALL: line 34: 119765 Done echo 'tools:::.install_packages()' 119766 Segmentation fault | R_DEFAULT_PACKAGES= LC_COLLATE=C "${R_HOME}/bin/R" $myArgs --no-echo --args ${args}

The downloaded source packages are in ‘/tmp/RtmpJH9BQo/downloaded_packages’ Updating HTML index of packages in '.Library' Making 'packages.html' ... done Old packages: 'cytolib', 'dplyr', 'gdtools', 'gert', 'leiden', 'magick', 'misc3d', 'pbdZMQ', 'promises', 'rgdal', 'sf', 'sparseMatrixStats', 'xgboost' Update all/some/none? [a/s/n]: Warning message: In install.packages(...) : installation of package ‘MSnbase’ had non-zero exit status

lgatto commented 3 years ago

Ok, so you are using a recent R, with what I assume is Bioconductor release, i.e version 3.12. This is something you can verify with BiocManager::version().

I can't see anything that helps me understand what is happening. Could you provide the output of BiocManager::install("MSnbase") before the actual error. For example, it's not clear of the error happens on installation, or afterwards, when the package is test-loaded.

urielrosen commented 3 years ago
> BiocManager::install("MSnbase")
Bioconductor version 3.12 (BiocManager 1.30.10), R 4.0.0 (2020-04-24)
Installing package(s) 'MSnbase'
trying URL 'https://bioconductor.org/packages/3.12/bioc/src/contrib/MSnbase_2.16.1.tar.gz'
Content type 'application/x-gzip' length 5833126 bytes (5.6 MB)
==================================================
downloaded 5.6 MB

* installing *source* package ‘MSnbase’ ...
** using staged installation
** libs
g++ -std=gnu++11 -I"/apps/RH7U2/gnu/R/4.0.0/lib64/R/include" -DNDEBUG  -I'/apps/RH7U2/gnu/R/4.0.0/lib64/R/library/Rcpp/include' -I/usr/local/include   -fpic  -g -O2  -c RcppExports.cpp -o RcppExports.o
gcc -std=gnu99 -I"/apps/RH7U2/gnu/R/4.0.0/lib64/R/include" -DNDEBUG  -I'/apps/RH7U2/gnu/R/4.0.0/lib64/R/library/Rcpp/include' -I/usr/local/include   -fpic  -g -O2  -c Spectrum1_class.c -o Spectrum1_class.o
gcc -std=gnu99 -I"/apps/RH7U2/gnu/R/4.0.0/lib64/R/include" -DNDEBUG  -I'/apps/RH7U2/gnu/R/4.0.0/lib64/R/library/Rcpp/include' -I/usr/local/include   -fpic  -g -O2  -c Spectrum2_class.c -o Spectrum2_class.o
g++ -std=gnu++11 -I"/apps/RH7U2/gnu/R/4.0.0/lib64/R/include" -DNDEBUG  -I'/apps/RH7U2/gnu/R/4.0.0/lib64/R/library/Rcpp/include' -I/usr/local/include   -fpic  -g -O2  -c imp_neighbour_avg.cpp -o imp_neighbour_avg.o
gcc -std=gnu99 -I"/apps/RH7U2/gnu/R/4.0.0/lib64/R/include" -DNDEBUG  -I'/apps/RH7U2/gnu/R/4.0.0/lib64/R/library/Rcpp/include' -I/usr/local/include   -fpic  -g -O2  -c utils.c -o utils.o
g++ -std=gnu++11 -shared -L/apps/RH7U2/gnu/R/4.0.0/lib64/R/lib -L/usr/local/lib64 -o MSnbase.so RcppExports.o Spectrum1_class.o Spectrum2_class.o imp_neighbour_avg.o utils.o -L/apps/RH7U2/gnu/R/4.0.0/lib64/R/lib -lR
installing to /apps/RH7U2/gnu/R/4.0.0/lib64/R/library/00LOCK-MSnbase/00new/MSnbase/libs
** R
** data
*** moving datasets to lazyload DB

 *** caught segfault ***
address 0x20, cause 'memory not mapped'

Traceback:
 1: Module(module, mustStart = TRUE, where = env)
 2: doTryCatch(return(expr), name, parentenv, handler)
 3: tryCatchOne(expr, names, parentenv, handlers[[1L]])
 4: tryCatchList(expr, classes, parentenv, handlers)
 5: tryCatch(Module(module, mustStart = TRUE, where = env), error = function(e) e)
 6: loadModule("Ramp", TRUE)
 7: fun(libname, pkgname)
 8: doTryCatch(return(expr), name, parentenv, handler)
 9: tryCatchOne(expr, names, parentenv, handlers[[1L]])
10: tryCatchList(expr, classes, parentenv, handlers)
11: tryCatch(fun(libname, pkgname), error = identity)
12: runHook(".onLoad", env, package.lib, package)
13: loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]])
14: namespaceImport(ns, loadNamespace(i, c(lib.loc, .libPaths()),     versionCheck = vI[[i]]), from = package)
15: loadNamespace(name)
16: doTryCatch(return(expr), name, parentenv, handler)
17: tryCatchOne(expr, names, parentenv, handlers[[1L]])
18: tryCatchList(expr, classes, parentenv, handlers)
19: tryCatch(loadNamespace(name), error = function(e) {    warning(gettextf("namespace %s is not available and has been replaced\nby .GlobalEnv when processing object %s",         sQuote(name)[1L], sQuote(where)), domain = NA, call. = FALSE,         immediate. = TRUE)    .GlobalEnv})
20: ..getNamespace(c("MSnbase", "1.21.8"), "itraqdata")
21: load(zfile, envir = tmp_env)
22: utils::data(list = f, package = package, lib.loc = lib.loc, envir = dataEnv,     overwrite = TRUE)
23: data2LazyLoadDB(pkg_name, lib, compress = data_compress)
24: doTryCatch(return(expr), name, parentenv, handler)
25: tryCatchOne(expr, names, parentenv, handlers[[1L]])
26: tryCatchList(expr, classes, parentenv, handlers)
27: tryCatch(expr, error = function(e) {    call <- conditionCall(e)    if (!is.null(call)) {        if (identical(call[[1L]], quote(doTryCatch)))             call <- sys.call(-4L)        dcall <- deparse(call)[1L]        prefix <- paste("Error in", dcall, ": ")        LONG <- 75L        sm <- strsplit(conditionMessage(e), "\n")[[1L]]        w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w")        if (is.na(w))             w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L],                 type = "b")        if (w > LONG)             prefix <- paste0(prefix, "\n  ")    }    else prefix <- "Error : "    msg <- paste0(prefix, conditionMessage(e), "\n")    .Internal(seterrmessage(msg[1L]))    if (!silent && isTRUE(getOption("show.error.messages"))) {        cat(msg, file = outFile)        .Internal(printDeferredWarnings())    }    invisible(structure(msg, class = "try-error", condition = e))})
28: try(data2LazyLoadDB(pkg_name, lib, compress = data_compress))
29: do_install_source(pkg_name, instdir, pkg, desc)
30: do_install(pkg)
31: tools:::.install_packages()
An irrecoverable exception occurred. R is aborting now ...
/apps/RH7U2/gnu/R/4.0.0/lib64/R/bin/INSTALL: line 34: 119765 Done                    echo 'tools:::.install_packages()'
     119766 Segmentation fault      | R_DEFAULT_PACKAGES= LC_COLLATE=C "${R_HOME}/bin/R" $myArgs --no-echo --args ${args}

The downloaded source packages are in
        ‘/tmp/RtmpJH9BQo/downloaded_packages’
Updating HTML index of packages in '.Library'
Making 'packages.html' ... done
Old packages: 'cytolib', 'dplyr', 'gdtools', 'gert', 'leiden', 'magick',
  'misc3d', 'pbdZMQ', 'promises', 'rgdal', 'sf', 'sparseMatrixStats', 'xgboost'
Update all/some/none? [a/s/n]:
Warning message:
In install.packages(...) :
  installation of package ‘MSnbase’ had non-zero exit status
lgatto commented 3 years ago

Could you try to load mzR with library(mzR) - does that work?

urielrosen commented 3 years ago

Hi ,

I get the same error , what do you think I can do to resolve this ?

library(mzR) Loading required package: Rcpp

caught segfault address 0x20, cause 'memory not mapped'

Traceback: 1: Module(module, mustStart = TRUE, where = env) 2: doTryCatch(return(expr), name, parentenv, handler) 3: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 4: tryCatchList(expr, classes, parentenv, handlers) 5: tryCatch(Module(module, mustStart = TRUE, where = env), error = function(e) e) 6: loadModule("Ramp", TRUE) 7: fun(libname, pkgname) 8: doTryCatch(return(expr), name, parentenv, handler) 9: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 10: tryCatchList(expr, classes, parentenv, handlers) 11: tryCatch(fun(libname, pkgname), error = identity) 12: runHook(".onLoad", env, package.lib, package) 13: loadNamespace(package, lib.loc) 14: doTryCatch(return(expr), name, parentenv, handler) 15: tryCatchOne(expr, names, parentenv, handlers[[1L]]) 16: tryCatchList(expr, classes, parentenv, handlers) 17: tryCatch({ attr(package, "LibPath") <- which.lib.loc ns <- loadNamespace(package, lib.loc) env <- attachNamespace(ns, pos = pos, deps, exclude, include.only)}, error = function(e) { P <- if (!is.null(cc <- conditionCall(e))) paste(" in", deparse(cc)[1L]) else "" msg <- gettextf("package or namespace load failed for %s%s:\n %s", sQuote(package), P, conditionMessage(e)) if (logical.return) message(paste("Error:", msg), domain = NA) else stop(msg, call. = FALSE, domain = NA)}) 18: library(mzR)

Possible actions: 1: abort (with core dump, if enabled) 2: normal R exit 3: exit R without saving workspace 4: exit R saving workspace

Thanks, Uriel.

From: Laurent Gatto notifications@github.com Sent: Monday, February 15, 2021 10:04 PM To: lgatto/MSnbase MSnbase@noreply.github.com Cc: Uriel Rosen uriel.rosen@weizmann.ac.il; Author author@noreply.github.com Subject: Re: [lgatto/MSnbase] Segmentation fault on install (#539)

Could you try to load mzR with library(mzR) - does that work?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/lgatto/MSnbase/issues/539#issuecomment-779425152, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ANSIVRODHLZJIKOVTJKDKKLS7F43XANCNFSM4XTIX45A.

lgatto commented 3 years ago

Ok, the error has nothing to do with MSnbase. Could you try to re-install mzR.

urielrosen commented 3 years ago

Thanks a lot I will try that.

Thanks, Uriel.

From: Laurent Gatto notifications@github.com Sent: Tuesday, February 16, 2021 9:02 AM To: lgatto/MSnbase MSnbase@noreply.github.com Cc: Uriel Rosen uriel.rosen@weizmann.ac.il; Author author@noreply.github.com Subject: Re: [lgatto/MSnbase] Segmentation fault on install (#539)

Ok, the error has nothing to do with MSnbase. Could you try to re-install mzR.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/lgatto/MSnbase/issues/539#issuecomment-779632560, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ANSIVROGH7UICTPEE4HTR5LS7IJ6LANCNFSM4XTIX45A.