Access error when installing packages

本文介绍了一个npm安装grunt过程中遇到的权限错误,并详细记录了错误信息。通过调整安装方式为使用cnpm并添加--save-dev参数,成功解决了问题。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

一、环境说明

        操作系统:windows7

        命令操作环境:cygwin


二、错误说明

       在npm install grunt是出现报错:

npm WARN checkPermissions Missing write access to G:\webstorm\movieManageWeb\node_modules\ignore-by-default
npm WARN checkPermissions Missing write access to G:\webstorm\movieManageWeb\node_modules\livereload-js
npm WARN checkPermissions Missing write access to G:\webstorm\movieManageWeb\node_modules\lodash.defaults
npm WARN checkPermissions Missing write access to G:\webstorm\movieManageWeb\node_modules\minimatch
npm WARN checkPermissions Missing write access to G:\webstorm\movieManageWeb\node_modules\globule
npm WARN checkPermissions Missing write access to G:\webstorm\movieManageWeb\node_modules\gaze
npm WARN checkPermissions Missing write access to G:\webstorm\movieManageWeb\node_modules\chokidar
npm WARN checkPermissions Missing write access to G:\webstorm\movieManageWeb\node_modules\ps-tree
npm WARN checkPermissions Missing write access to G:\webstorm\movieManageWeb\node_modules\undefsafe
npm WARN checkPermissions Missing write access to G:\webstorm\movieManageWeb\node_modules\touch
npm WARN checkPermissions Missing write access to G:\webstorm\movieManageWeb\node_modules\faye-websocket
npm WARN checkPermissions Missing write access to G:\webstorm\movieManageWeb\node_modules\tiny-lr
npm WARN checkPermissions Missing write access to G:\webstorm\movieManageWeb\node_modules\nodemon
npm WARN checkPermissions Missing write access to G:\webstorm\movieManageWeb\node_modules\update-notifier
npm WARN checkPermissions Missing write access to G:\webstorm\movieManageWeb\node_modules\glob
npm WARN moviemanageweb@1.0.0 No description
npm WARN moviemanageweb@1.0.0 No repository field.

npm ERR! path G:\webstorm\movieManageWeb\node_modules\ignore-by-default
npm ERR! code ENOENT
npm ERR! errno -4058
npm ERR! syscall access
npm ERR! enoent ENOENT: no such file or directory, access 'G:\webstorm\movieManageWeb\node_modules\ignore-by-default'
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoent


npm ERR! A complete log of this run can be found in:
npm ERR!     d:\Program Files\nodejs\node_cache\_logs\2017-10-19T13_36_58_890Z-debug.log


三、问题解决

后面发现是因为我之前使用的是cnpm install grunt -g

使用的是cnpm在全局下安装的grunt。

后面又使用npm在当前文件目录下安装grunt,就出现了文件权限的问题。

所以我改成使用:cnpm install grunt --save-dev

问题就解决了。

cnpm是使用淘宝镜像安装,具体配置是:

npm install -g cnpm --registry=https://registry.npm.taobao.org
然后就可以使用cnpm安装模块了。

# 安装BiocManager(如未安装) > if (!require("BiocManager", quietly = TRUE)) + install.packages("BiocManager") > # 设置使用Bioconductor 3.14(适配R 4.1.2) > BiocManager::install(version = "3.14") 'getOption("repos")' replaces Bioconductor standard repositories, see 'help("repositories", package = "BiocManager")' for details. Replacement repositories: CRAN: http://mirrors.tuna.tsinghua.edu.cn/CRAN/ Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib: cannot open URL 'http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib: cannot open URL 'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib: cannot open URL 'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib: cannot open URL 'http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib/PACKAGES' Bioconductor version 3.14 (BiocManager 1.30.26), R 4.1.2 (2021-11-01) Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib: cannot open URL 'http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib: cannot open URL 'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib: cannot open URL 'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib: cannot open URL 'http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib/PACKAGES' Old packages: 'backports', 'boot', 'class', 'cli', 'cluster', 'codetools', 'dplyr', 'farver', 'foreign', 'ggrepel', 'glue', 'KernSmooth', 'lattice', 'lme4', 'mgcv', 'minqa', 'nlme', 'nloptr', 'nnet', 'purrr', 'quantreg', 'rbibutils', 'Rcpp', 'RcppEigen', 'rlang', 'rpart', 'SparseM', 'spatial', 'stringi', 'survival', 'tibble', 'tidyr', 'tidyselect', 'utf8', 'vctrs' Update all/some/none? [a/s/n]: n > # 设置清华镜像加速 > options(repos = c(CRAN = "https://mirrors.tuna.tsinghua.edu.cn/CRAN/")) > # 安装基础依赖(必须) > install.packages(c("Matrix", "lattice", "survival", "mgcv")) Error in install.packages : Updating loaded packages Restarting R session... > install.packages(c("Matrix", "lattice", "survival", "mgcv")) WARNING: Rtools is required to build R packages but is not currently installed. Please download and install the appropriate version of Rtools before proceeding: https://cran.rstudio.com/bin/windows/Rtools/ Warning in install.packages : package ‘Matrix’ is not available for this version of R A version of this package for your version of R might be available elsewhere, see the ideas at https://cran.r-project.org/doc/manuals/r-patched/R-admin.html#Installing-packages 有二进制版本的,但源代码版本是后来的: binary source needs_compilation lattice 0.21-8 0.22-7 TRUE survival 3.5-5 3.8-3 TRUE mgcv 1.8-42 1.9-3 TRUE Binaries will be installed 试开URL’https://mirrors.tuna.tsinghua.edu.cn/CRAN/bin/windows/contrib/4.1/lattice_0.21-8.zip' Content type 'application/zip' length 1375422 bytes (1.3 MB) downloaded 1.3 MB 试开URL’https://mirrors.tuna.tsinghua.edu.cn/CRAN/bin/windows/contrib/4.1/survival_3.5-5.zip' Content type 'application/zip' length 6701861 bytes (6.4 MB) downloaded 6.4 MB 试开URL’https://mirrors.tuna.tsinghua.edu.cn/CRAN/bin/windows/contrib/4.1/mgcv_1.8-42.zip' Content type 'application/zip' length 3578468 bytes (3.4 MB) downloaded 3.4 MB package ‘lattice’ successfully unpacked and MD5 sums checked package ‘survival’ successfully unpacked and MD5 sums checked package ‘mgcv’ successfully unpacked and MD5 sums checked The downloaded binary packages are in C:\Users\Administrator\AppData\Local\Temp\Rtmp4ety9S\downloaded_packages > # 安装Bioconductor依赖 > BiocManager::install(c("Biobase", "GenomeInfoDbData", "AnnotationDbi")) 'getOption("repos")' replaces Bioconductor standard repositories, see 'help("repositories", package = "BiocManager")' for details. Replacement repositories: CRAN: https://mirrors.tuna.tsinghua.edu.cn/CRAN/ Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib/PACKAGES' Bioconductor version 3.14 (BiocManager 1.30.26), R 4.1.2 (2021-11-01) Installing package(s) 'GenomeInfoDbData', 'AnnotationDbi' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/bin/windows/contrib/4.1: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/bin/windows/contrib/4.1/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/bin/windows/contrib/4.1: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/bin/windows/contrib/4.1/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/bin/windows/contrib/4.1: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/bin/windows/contrib/4.1/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/bin/windows/contrib/4.1: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/bin/windows/contrib/4.1/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib/PACKAGES' Old packages: 'backports', 'boot', 'class', 'cli', 'cluster', 'codetools', 'dplyr', 'farver', 'foreign', 'ggrepel', 'glue', 'KernSmooth', 'lattice', 'lme4', 'mgcv', 'minqa', 'nlme', 'nloptr', 'nnet', 'purrr', 'quantreg', 'rbibutils', 'Rcpp', 'RcppEigen', 'rlang', 'rpart', 'SparseM', 'spatial', 'stringi', 'survival', 'tibble', 'tidyr', 'tidyselect', 'utf8', 'vctrs' Update all/some/none? [a/s/n]: n Warning messages: 1: package(s) not installed when version(s) same as or greater than current; use `force = TRUE` to re-install: 'Biobase' 2: packages ‘GenomeInfoDbData’, ‘AnnotationDbi’ are not available for Bioconductor version '3.14' Versions of these packages for your version of R might be available elsewhere, see the ideas at https://cran.r-project.org/doc/manuals/r-patched/R-admin.html#Installing-packages > force = TRUE > library(sva)# 载入需要的程辑包:mgcv 载入需要的程辑包:nlme This is mgcv 1.8-42. For overview type 'help("mgcv-package")'. 载入需要的程辑包:genefilter Error: package or namespace load failed for ‘genefilter’ in inDL(x, as.logical(local), as.logical(now), ...): 无法载入共享目标对象‘F:/R/R-4.1.2/R-4.1.2/library/Biobase/libs/x64/Biobase.dll’:: LoadLibrary failure: 鎵句笉鍒版寚瀹氱殑绋嬪簭銆 错误: 无法载入程辑包‘genefilter’ 此外: Warning messages: 1: 程辑包‘sva’是用R版本4.5.0 来建造的 2: 程辑包‘mgcv’是用R版本4.1.3 来建造的 3: 程辑包‘genefilter’是用R版本4.5.0 来建造的 > library(ggplot2) > library(pRRophetic)# Error in library(pRRophetic) : 不存在叫‘pRRophetic’这个名字的程辑包 > library(genefilter)# 错误: package or namespace load failed for ‘genefilter’ in inDL(x, as.logical(local), as.logical(now), ...): 无法载入共享目标对象‘F:/R/R-4.1.2/R-4.1.2/library/Biobase/libs/x64/Biobase.dll’:: LoadLibrary failure: 鎵句笉鍒版寚瀹氱殑绋嬪簭銆 此外: Warning message: 程辑包‘genefilter’是用R版本4.5.0 来建造的 > # 安装genefilter 1.76.0(兼容版本) > BiocManager::install("genefilter@1.76.0") 'getOption("repos")' replaces Bioconductor standard repositories, see 'help("repositories", package = "BiocManager")' for details. Replacement repositories: CRAN: https://mirrors.tuna.tsinghua.edu.cn/CRAN/ Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib/PACKAGES' Bioconductor version 3.14 (BiocManager 1.30.26), R 4.1.2 (2021-11-01) Installing package(s) 'genefilter@1.76.0' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/bin/windows/contrib/4.1: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/bin/windows/contrib/4.1/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/bin/windows/contrib/4.1: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/bin/windows/contrib/4.1/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/bin/windows/contrib/4.1: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/bin/windows/contrib/4.1/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/bin/windows/contrib/4.1: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/bin/windows/contrib/4.1/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib/PACKAGES' Old packages: 'backports', 'boot', 'class', 'cli', 'cluster', 'codetools', 'dplyr', 'farver', 'foreign', 'ggrepel', 'glue', 'KernSmooth', 'lattice', 'lme4', 'mgcv', 'minqa', 'nlme', 'nloptr', 'nnet', 'purrr', 'quantreg', 'rbibutils', 'Rcpp', 'RcppEigen', 'rlang', 'rpart', 'SparseM', 'spatial', 'stringi', 'survival', 'tibble', 'tidyr', 'tidyselect', 'utf8', 'vctrs' Update all/some/none? [a/s/n]: n Warning message: package ‘genefilter@1.76.0’ is not available for Bioconductor version '3.14' A version of this package for your version of R might be available elsewhere, see the ideas at https://cran.r-project.org/doc/manuals/r-patched/R-admin.html#Installing-packages > # 安装sva 3.42.0(兼容版本) > BiocManager::install("sva@3.42.0") 'getOption("repos")' replaces Bioconductor standard repositories, see 'help("repositories", package = "BiocManager")' for details. Replacement repositories: CRAN: https://mirrors.tuna.tsinghua.edu.cn/CRAN/ Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib/PACKAGES' Bioconductor version 3.14 (BiocManager 1.30.26), R 4.1.2 (2021-11-01) Installing package(s) 'sva@3.42.0' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/bin/windows/contrib/4.1: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/bin/windows/contrib/4.1/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/bin/windows/contrib/4.1: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/bin/windows/contrib/4.1/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/bin/windows/contrib/4.1: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/bin/windows/contrib/4.1/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/bin/windows/contrib/4.1: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/bin/windows/contrib/4.1/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib: 无法打开URL'http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib/PACKAGES' Old packages: 'backports', 'boot', 'class', 'cli', 'cluster', 'codetools', 'dplyr', 'farver', 'foreign', 'ggrepel', 'glue', 'KernSmooth', 'lattice', 'lme4', 'mgcv', 'minqa', 'nlme', 'nloptr', 'nnet', 'purrr', 'quantreg', 'rbibutils', 'Rcpp', 'RcppEigen', 'rlang', 'rpart', 'SparseM', 'spatial', 'stringi', 'survival', 'tibble', 'tidyr', 'tidyselect', 'utf8', 'vctrs' Update all/some/none? [a/s/n]: n Warning message: package ‘sva@3.42.0’ is not available for Bioconductor version '3.14' A version of this package for your version of R might be available elsewhere, see the ideas at https://cran.r-project.org/doc/manuals/r-patched/R-admin.html#Installing-packages
最新发布
06-21
> # 设置清华CRAN镜像 > options(repos = c(CRAN = "http://mirrors.tuna.tsinghua.edu.cn/CRAN/")) > # 安装基础依赖(引用[2]方法) > install.packages(c("BiocManager", "GenomeInfoDbData")) Error in install.packages : Updating loaded packages > install.packages(c("BiocManager", "GenomeInfoDbData")) WARNING: Rtools is required to build R packages but is not currently installed. Please download and install the appropriate version of Rtools before proceeding: https://cran.rstudio.com/bin/windows/Rtools/ Warning in install.packages : package ‘GenomeInfoDbData’ is not available for this version of R A version of this package for your version of R might be available elsewhere, see the ideas at https://cran.r-project.org/doc/manuals/r-patched/R-admin.html#Installing-packages There is a binary version available but the source version is later: binary source needs_compilation BiocManager 1.30.20 1.30.26 FALSE installing the source package ‘BiocManager’ trying URL 'http://mirrors.tuna.tsinghua.edu.cn/CRAN/src/contrib/BiocManager_1.30.26.tar.gz' Content type 'application/octet-stream' length 594489 bytes (580 KB) downloaded 580 KB * installing *source* package 'BiocManager' ... ** package 'BiocManager' successfully unpacked and MD5 sums checked ** using staged installation ** R ** inst ** byte-compile and prepare package for lazy loading ** help *** installing help indices converting help for package 'BiocManager' finding HTML links ... done BiocManager-package html available html install html repositories html valid html version html ** building package indices ** installing vignettes ** testing if installed package can be loaded from temporary location *** arch - i386 *** arch - x64 ** testing if installed package can be loaded from final location *** arch - i386 *** arch - x64 ** testing if installed package keeps a record of temporary installation path * DONE (BiocManager) Making 'packages.html' ... done The downloaded source packages are in ‘C:\Users\Administrator\AppData\Local\Temp\RtmpyqErlw\downloaded_packages’ > # 通过BiocManager安装生物信息学依赖(引用[4]方法) > if (!require("BiocManager", quietly = TRUE)) + install.packages("BiocManager") Bioconductor version 3.14 (BiocManager 1.30.26), R 4.1.2 (2021-11-01) Bioconductor version '3.14' is out-of-date; the current release version '3.21' is available with R version '4.5'; see https://bioconductor.org/install > # 设置中科大Bioconductor镜像(关键步骤) > options(BioC_mirror = "http://mirrors.ustc.edu.cn/bioc/") > # 安装核心依赖包 > BiocManager::install(c("genefilter", "sva", "Biobase")) 'getOption("repos")' replaces Bioconductor standard repositories, see 'help("repositories", package = "BiocManager")' for details. Replacement repositories: CRAN: http://mirrors.tuna.tsinghua.edu.cn/CRAN/ Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib: cannot open URL 'http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib: cannot open URL 'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib: cannot open URL 'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib: cannot open URL 'http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib/PACKAGES' Bioconductor version 3.14 (BiocManager 1.30.26), R 4.1.2 (2021-11-01) Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib: cannot open URL 'http://mirrors.ustc.edu.cn/bioc//packages/3.14/bioc/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib: cannot open URL 'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/annotation/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib: cannot open URL 'http://mirrors.ustc.edu.cn/bioc//packages/3.14/data/experiment/src/contrib/PACKAGES' Warning: unable to access index for repository http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib: cannot open URL 'http://mirrors.ustc.edu.cn/bioc//packages/3.14/workflows/src/contrib/PACKAGES' Old packages: 'backports', 'boot', 'class', 'cli', 'cluster', 'codetools', 'dplyr', 'farver', 'foreign', 'ggrepel', 'glue', 'KernSmooth', 'lattice', 'lme4', 'mgcv', 'minqa', 'nlme', 'nloptr', 'nnet', 'purrr', 'quantreg', 'rbibutils', 'Rcpp', 'RcppEigen', 'rlang', 'rpart', 'SparseM', 'spatial', 'stringi', 'survival', 'tibble', 'tidyr', 'tidyselect', 'utf8', 'vctrs' Update all/some/none? [a/s/n]: n Warning message: package(s) not installed when version(s) same as or greater than current; use `force = TRUE` to re-install: 'genefilter' 'sva' 'Biobase' > force = TRUE > # 按顺序加载测试 > library(GenomeInfoDbData) # 先前缺失的依赖(引用[1]) Error in library(GenomeInfoDbData) : there is no package called ‘GenomeInfoDbData’ > library(genefilter) # 原问题包 Error: package or namespace load failed for ‘genefilter’ in inDL(x, as.logical(local), as.logical(now), ...): unable to load shared object 'F:/R/R-4.1.2/R-4.1.2/library/Biobase/libs/x64/Biobase.dll': LoadLibrary failure: 鎵句笉鍒版寚瀹氱殑绋嬪簭銆 In addition: Warning message: package ‘genefilter’ was built under R version 4.5.0 > library(sva) # 目标包 Loading required package: genefilter Error: package or namespace load failed for ‘genefilter’ in inDL(x, as.logical(local), as.logical(now), ...): unable to load shared object 'F:/R/R-4.1.2/R-4.1.2/library/Biobase/libs/x64/Biobase.dll': LoadLibrary failure: 鎵句笉鍒版寚瀹氱殑绋嬪簭銆 Error: package ‘genefilter’ could not be loaded In addition: Warning messages: 1: package ‘sva’ was built under R version 4.5.0 2: package ‘genefilter’ was built under R version 4.5.0 > library(Biobase) # sva的依赖(引用[4]) Loading required package: BiocGenerics Loading required package: generics Attaching package: ‘generics’ The following objects are masked from ‘package:base’: as.difftime, as.factor, as.ordered, intersect, is.element, setdiff, setequal, union Attaching package: ‘BiocGenerics’ The following objects are masked from ‘package:stats’: IQR, mad, sd, var, xtabs The following objects are masked from ‘package:base’: anyDuplicated, aperm, append, as.data.frame, basename, cbind, colnames, dirname, do.call, duplicated, eval, evalq, Filter, Find, get, grep, grepl, is.unsorted, lapply, Map, mapply, match, mget, order, paste, pmax, pmax.int, pmin, pmin.int, Position, rank, rbind, Reduce, rownames, sapply, saveRDS, table, tapply, unique, unsplit, which.max, which.min Error: package or namespace load failed for ‘Biobase’ in inDL(x, as.logical(local), as.logical(now), ...): unable to load shared object 'F:/R/R-4.1.2/R-4.1.2/library/Biobase/libs/x64/Biobase.dll': LoadLibrary failure: 鎵句笉鍒版寚瀹氱殑绋嬪簭銆 In addition: Warning messages: 1: package ‘Biobase’ was built under R version 4.5.0 2: package ‘BiocGenerics’ was built under R version 4.5.0 > 我需要下载适配R-4.1.2的sva包和genefilter包
06-20
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值