BiocInstaller’ is not available (for R version 3.2.2)
2
0
Entering edit mode
@anikumarmurugan-8671
Last seen 9.3 years ago
United States

I have tried to install BiocInstaller on R . Getting the  below message:

> source("http://bioconductor.org/biocLite.R")
Installing package into ‘/usr/local/lib/R/site-library’
(as ‘lib’ is unspecified)
Warning: unable to access index for repository http://bioconductor.org/packages/3.1/bioc/src/contrib
'biocLite.R' failed to install 'BiocInstaller', use
  'install.packages("BiocInstaller",
  repos="http://www.bioconductor.org/packages/3.1/bioc")'
Warning message:
package ‘BiocInstaller’ is not available (for R version 3.2.2)
>

tried with this step also : (install.packages("BiocInstaller", repos="http://www.bioconductor.org/packages/3.1/bioc")'

No luck.

Could please provide the fix for this issue.

 

biocinstaller • 13k views
ADD COMMENT
0
Entering edit mode

Can you see this link in a web browser?

http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES

I can. If you cannot, then the problem is with your network access or policies.

You might also try doing

curl http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES

on the machine where R is running, because maybe it has different network settings.

 

ADD REPLY
0
Entering edit mode

I can able to see the link on browser

ADD REPLY
0
Entering edit mode

The warnging about 'unable to access index for repository' comes when R tries to download the file Dan mentions. So does

url = "http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES"
download.file(url, tempfile())

I guess this will fail, too. The help page ?download.file lists several different values for the 'method' argument. Try each

download.file(url, tempfile(), method="internal")

etc. If one works, then try to set that method as the default

options(download.file.method="libcurl")  ## if libcurl worked

Verify that download.file() now works with no 'method' argument, and try source("http://bioconductor.org/biocLite.R") again. Please let us know if this works.

ADD REPLY
0
Entering edit mode

It do work! Thanks a lot~

ADD REPLY
0
Entering edit mode
@anikumarmurugan-8671
Last seen 9.3 years ago
United States

The below link i'm able to open on my windows browser,

But the problem is when i tried to downloading on Ubuntu14.04 machine

I have tried with:  download.file(url, tempfile()) 

Getting below 404 error issue:

> download.file(url = "http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES", tempfile())
trying URL 'http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES'
Error in download.file(url = "http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES",  :
  cannot open URL 'http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES'
In addition: Warning message:
In download.file(url = "http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES",  :
  cannot open: HTTP status was '404 Not Found'

 

ADD COMMENT
0
Entering edit mode

Did you try the different 'method' arguments to download.file, as suggested in my previous comment? Please add the output of sessionInfo() to your original question.

ADD REPLY
0
Entering edit mode

Session info:

> sessionInfo()
R version 3.2.2 (2015-08-14)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 14.04.2 LTS

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

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

ADD REPLY
0
Entering edit mode

I tried with all the method "arguments". For the below.,

1> options(download.file.method="curl")

> download.file(url = "http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES", tempfile(), method="curl")

  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current

                                 Dload  Upload   Total   Spent    Left  Speed

100   318  100   318    0     0   123k      0 --:--:-- --:--:-- --:--:--  155k

> download.file()

Error in download.file() :

  argument "destfile" is missing, with no default

 

2> options(download.file.method="wget")

> download.file(url = "http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES", tempfile(), method="wget")

--2015-08-23 19:35:17--  http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES

Resolving bioconductor.org bioconductor.org)... 192.168.1.21

Connecting to bioconductor.org bioconductor.org)|192.168.1.21|:80... connected.

HTTP request sent, awaiting response... 404 Not Found

2015-08-23 19:35:17 ERROR 404: Not Found.

 

Warning message:

In download.file(url = "http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES",  :

  download had nonzero exit status

3> options(download.file.method="libcurl")

> download.file(url = "http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES", tempfile(), method="libcurl")

trying URL 'http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES'

Content type 'text/html; charset=iso-8859-1' length 318 bytes

==================================================

downloaded 318 bytes

 

> download.file()

Error in download.file() :

  argument "destfile" is missing, with no default

> source("http://bioconductor.org/biocLite.R")

Installing package into ‘/usr/local/lib/R/site-library’

(as ‘lib’ is unspecified)

Error: Line starting '<!DOCTYPE HTML PUBLI ...' is malformed!

 

> options(download.file.method="auto")

> download.file(url = "http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES", tempfile(), method="auto")

trying URL 'http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES'

Error in download.file(url = "http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES",  :

  cannot open URL 'http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES'

In addition: Warning message:

In download.file(url = "http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES",  :

  cannot open: HTTP status was '404 Not Found'

ADD REPLY
0
Entering edit mode

It looks like method="libcurl" works, but actually the file is 271 KB, and only 318 bytes were downloaded, so it is failing too! As a shot in the dark, in a new R session, what is the output of

url = "https://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES"
download.file(url, tempfile())
download.file(url, tempfile(), method="libcurl")

?

ADD REPLY
0
Entering edit mode

It might be helpful to actually see what is downloaded. So try: 

url="https://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES"
t = tempfile()
download.file(url, tempfile())
readLines(t)
download.file(url, tempfile(), method="libcurl")
readLines(t)
ADD REPLY
0
Entering edit mode

>download.file(url = https://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES, tempfile())
trying URL 'https://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES'

downloaded 0 bytes

Error in download.file(url = "https://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES",  :

Couldn't connect to server

>

ADD REPLY
0
Entering edit mode

>readLines(t)

Error in readLines(t) : 'con' is not a connection

ADD REPLY
0
Entering edit mode

What about when download.file does download something, with method='libcurl' like in your earlier response ?!

url="https://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES"
t = tempfile()
download.file(url, t, method="libcurl")
readLines(t)

Post the complete output, so there is no guessing involved.

ADD REPLY
0
Entering edit mode

I tried with https, Getting could not connect to the server:

Https output:

>download.file(url = https://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES, t, method="libcurl")
trying URL 'https://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES'

downloaded 0 bytes

Error in download.file(url = "https://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES",  :

Couldn't connect to server

 

In http output:

options(download.file.method="libcurl")

> download.file(url = "http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES", tempfile(), method="libcurl")

trying URL 'http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES'

Content type 'text/html; charset=iso-8859-1' length 318 bytes

==================================================

downloaded 318 bytes

>readLines(t)

[1] "<!DOCTYPE HTML PUBLIC \"-//IETF//DTD HTML 2.0//EN\">"

[2] "<html><head>"

[3] "<title>404 Not Found</title>"

[4] "</head><body>"

[5] "<h1>Not Found</h1>"

[6] "<p> The requested URL /packages/3.1/bioc/src/contrib/PACKAGES was not found on this server.</p>"

[7] "<hr>"

[8] "<address>Apache/2.2.22 (Ubuntu) Server at bioconductor.org Port 80</address>"

[9] "</body></html>"

 

 

ADD REPLY
0
Entering edit mode

Is this bio conductor version 3.1 will support with R version 3.2.2?

ADD REPLY
0
Entering edit mode

Yes, Bioconductor version 3.1 is supported on R version 3.2.2. As you saw on your windows box, the url resolves to a file describing each package -- visiting http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES in my web browser gives me a file that starts

Package: a4
Version: 1.16.0
Depends: a4Base, a4Preproc, a4Classif, a4Core, a4Reporting
Suggests: MLP, nlcv, ALL, Cairo
License: GPL-3
MD5sum: 1bd22944d9e6d7bb2f6c742dcf7e340f
NeedsCompilation: no

Package: a4Base

So the file is there and publicly accessible. When you replied in part above

> download.file(url = "http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES", tempfile(), method="libcurl")
trying URL 'http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES'
Content type 'text/html; charset=iso-8859-1' length 318 bytes
==================================================
downloaded 318 bytes

>readLines(t)

Note that you have used 'tempfile()' as the second argument to download.file(), but you should have used 't'. The next line, readLines(t) would have read in what had been downloaded -- I think it probably is reading in the result from a previous attempt, but then I'm guessing. Also, the lack of a space between '>' and 'readlines(t)' makes me think that you have edited this response, rather than cutting and pasting from your R session exactly. This can also cause confusion. And in my suggestion I had used https but should have used http. So if you could please do exactly

url="http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES"
t = tempfile()
download.file(url, t, method="libcurl")
readLines(t)

then we are sure to be understanding one another. This is what I get:

> url="http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES"
> t = tempfile()
> download.file(url, t, method="libcurl")
trying URL 'http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES'
Content type 'unknown' length 278286 bytes (271 KB)
==================================================
downloaded 271 KB

> readLines(t)
 [1] "Package: a4"                                                            
 [2] "Version: 1.16.0"                                                        
 [3] "Depends: a4Base, a4Preproc, a4Classif, a4Core, a4Reporting"             
 [4] "Suggests: MLP, nlcv, ALL, Cairo"                                        
 [5] "License: GPL-3"                                                         
 [6] "MD5sum: 1bd22944d9e6d7bb2f6c742dcf7e340f"                               
 [7] "NeedsCompilation: no"                                                   
 [8] ""                                                                       
 [9] "Package: a4Base"                                                  

(and so on)

I believe that for your computer you will see the output that you have already shown us, that the server reports that the file is not found. But we have seen, from my browser and R session and your Windows browser, that the file is available.  You didn't actually show that you could access this file from outside R but on your ubuntu system; you said you could access this file from a browser on your windows machine.

So please say how you know that you can access this file from outside R but on your ubuntu system. One interesting way of showing this might be from the command line in Ubuntu

$ curl -I http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES

which responds

HTTP/1.1 200 OK
Content-Length: 278286
Connection: keep-alive
Date: Sun, 23 Aug 2015 18:17:35 GMT
Server: Apache/2.4.7 (Ubuntu)
Last-Modified: Sun, 23 Aug 2015 16:18:01 GMT
ETag: "43f0e-51dfcd84ae47f"
Accept-Ranges: bytes
Cache-Control: max-age=3600
Age: 346
X-Cache: Hit from cloudfront
Via: 1.1 21122496ee18752e6de67b3dc3b67e94.cloudfront.net (CloudFront)
X-Amz-Cf-Id: Mep8_-Nwq7bqogY8h3nN3b5WiPD2GGTXvTkTzIowhZPgyOL7vRZ3Qg==

and the same command from within R

> system("curl -I http://bioconductor.org/packages/3.1/bioc/src/contrib/PACKAGES")
HTTP/1.1 200 OK
Content-Length: 278286
Connection: keep-alive
Date: Sun, 23 Aug 2015 18:17:35 GMT
Server: Apache/2.4.7 (Ubuntu)
Last-Modified: Sun, 23 Aug 2015 16:18:01 GMT
ETag: "43f0e-51dfcd84ae47f"
Accept-Ranges: bytes
Cache-Control: max-age=3600
Age: 388
X-Cache: Hit from cloudfront
Via: 1.1 27701e3e6b9cb8f3835ec1068649e271.cloudfront.net (CloudFront)
X-Amz-Cf-Id: HWQXGY1QrQwll3nlARYcFUYEQ04AgzzWeX313nJYMYZtEWsKYHfeBw==

 

 

 

ADD REPLY
0
Entering edit mode

Is the ubuntu machine actually configured for internet access? Or is it behind some kind of firewall or proxy? Is it part of a cluster? It might be worth contacting your system administrator at this point. 

ADD REPLY
0
Entering edit mode

Internet connectivity is working fine.And also firewall disabled. Not a part of cluster

ADD REPLY
0
Entering edit mode

Can you demonstrate (share with us) some evidence that the machine has internet connectivity?

What if you choose another Bioconductor mirror with the chooseBioCmirror() function, and then try and install a package; does that work?

 

ADD REPLY

Login before adding your answer.

Traffic: 706 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6