Hi -
I have a large number of bam files that I would like to compress to cram. The bam files are on our computer cluster, and I would like to run cramtools as a job on the cluster. However, the compute nodes of the cluster do not have access to the Internet, which I believe is causing the error below. So I have some questions about cramtools?
Does anyone know a work-around for running cramtools without Internet access? Why does cramtools need to access the Internet? (I am providing the reference fasta file) Is there a manual cramtools?
Thanks,
Joe
Exception in thread "main" java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at net.sf.cram.CramTools.invoke(CramTools.java:93)
at net.sf.cram.CramTools.main(CramTools.java:123)
Caused by: java.lang.RuntimeException: java.net.ConnectException: Connection timed out
at net.sf.cram.ref.ReferenceSource.findBases(ReferenceSource.java:183)
at net.sf.cram.ref.ReferenceSource.getReferenceBases(ReferenceSource.java:127)
at net.sf.cram.Bam2Cram.main(Bam2Cram.java:282)
... 6 more
Caused by: java.net.ConnectException: Connection timed out
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:382)
at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:241)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:228)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:365)
at java.net.Socket.connect(Socket.java:527)
at java.net.Socket.connect(Socket.java:476)
at sun.net.NetworkClient.doConnect(NetworkClient.java:163)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:424)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:538)
at sun.net.www.http.HttpClient.<init>(HttpClient.java:214)
at sun.net.www.http.HttpClient.New(HttpClient.java:300)
at sun.net.www.http.HttpClient.New(HttpClient.java:319)
at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:987)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:923)
at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:841)
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1195)
at java.net.URL.openStream(URL.java:1010)
at net.sf.cram.ref.ReferenceSource.loadFromPath(ReferenceSource.java:249)
at net.sf.cram.ref.ReferenceSource.findBasesByMD5(ReferenceSource.java:283)
at net.sf.cram.ref.ReferenceSource.findBases(ReferenceSource.java:179)
... 8 more
Have you considered just using samtools to convert them to CRAM?
Yes, that worked. Thanks very much. I was not aware samtools had cram as an output option.
What's the command line? Did you try to use a
file://
scheme?I think my command line is standard, and all the files are accessible in the environment: