wget download

NCBI SRA files

Better use prefetch or fastq-dump download, instead of wget !

Many .sra files are compressed against a reference which is not included in the .sra file.

The SRA-tools prefetch or fastq-dump automatically download both the .sra files and the reference sequences required for decompressing. Additionally it gives download success control.

→ Download SRA-files using prefetch

Download using wget

(not recommended)

# get SRA file location on NCBI server (alternatively, search at NCBI website)

srapath SRR649944

http://sra-download.ncbi.nlm.nih.gov/srapub/SRR649944

# download using wget

wget -P Data http://sra-download.ncbi.nlm.nih.gov/srapub/SRR649944

ls Data/

SRR649944

# converting SRA file into fastq

fastq-dump --split-3 Data/SRR649944

ls

SRR649944_1.fastq

SRR649944_2.fastq

Error

many samples will not work using wget, as the compression related reference genome is missing

Error: "name not found while resolving tree within virtual file system module - failed"

Solution: use prefetch or fastq-dump, instead of wget

Note:

fastq-dump --split-3 SRR649944 (only access number without path Data/SRR649944 or ./SRR649944) will force fastq-dump to download the sample directly from NCBI instead of using the local copy.