EXITING: because of fatal INPUT file error: could not open read file
0
0
Entering edit mode
3.9 years ago
merfer0206 • 0

When I try and map my fastq files in STAR, I get the error:

EXITING: because of fatal INPUT file error: could not open read file: Day-30-R3_S3_L008_R1_001.fastq.gz
SOLUTION: check that this file exists and has read permision

However, I have checked that both the name and the directory of this file is correct, so I do not see the issue? Could anyone help out? Many thanks!

STAR --runThreadN 4 --genomeDir /Users/mfaleeva/Desktop/Day30 --readFilesCommand gunzip -c --readFilesIn Day-30-R1_S1_L008_R1_001.fastq.gz,Day-30-R2_S2_L008_R1_001.fastq.gz,Day-30-R3_S3_L008_R1_001.fastq.gz Day-30-R1_S1_L008_R2_001.fastq.gz,Day-30-R2_S2_L008_R2_001.fastq.gz,Day-30-R3_S3_L008_R2_001.fastq.gz --outSAMattrRGline ID:Day30_R1 , ID:Day30_R2 , ID:Day30_R3
mapping genome fastq STAR • 11k views
ADD COMMENT
0
Entering edit mode

Can you anyway do ls -l of those files where you execute the STAR command and post the output of that command here? thx

ADD REPLY
0
Entering edit mode
(base) Marias-MBP:genome_index mfaleeva$ ls -l
total 8
-rw-r--r--   1 mfaleeva  staff     0 11 Jan 19:16 Aligned.out.sam
-rw-r--r--   1 mfaleeva  staff  2612 11 Jan 19:16 Log.out
-rw-r--r--   1 mfaleeva  staff     0 11 Jan 19:16 Log.progress.out
drwx------   5 mfaleeva  staff   160 11 Jan 19:16 _STARtmp
drwx------  18 mfaleeva  staff   576 10 Jan 01:12 genome_index
ADD REPLY
0
Entering edit mode

If you executed STAR in this directory then there are no data files here. You need to likely be in one directory up (or where ever the data files are).

ADD REPLY
0
Entering edit mode

Sorry for stupid question, but if the STAR command didnt run because of the error, why would the files be there anyway?

ADD REPLY
1
Entering edit mode

EXITING: because of fatal INPUT file error: could not open read file: Day-30-R3_S3_L008_R1_001.fastq.gz

STAR command did not run because the program was not able to open your data file as noted in the error you posted in original question. So the file name may be correct but that file is not present in the directory where you ran the command. You need to provide full/relative path to the location where that file is /path_to/Day-30-R3_S3_L008_R1_001.fastq.gz or go into the directory where the data files are and then re-execute the command.

ADD REPLY
1
Entering edit mode

I think that GenoMax got the issue. To answer your questions, the generated files are mostly log files (in which you will probably find the error messages again and the command you issued). The file Aligned.out.sam, which is the first result you should obtain, is indeed empty (see the 0 on the fifth column of your output), and it is empty because STAR could not locate the read file. Try to follow GenoMax's advice and either run star from the folder in which you have the file Day-30-R3_S3_L008_R1_001.fastq.gz or (preferred) run STAR from an empty folder but provide the full path to file name.

ADD REPLY
0
Entering edit mode

Hi, I'm having the exact same issue. I'm in the directory with my .fq files and I believe that my paths all point to the appropriate directory, yet I get the same error.

EXITING because of fatal input ERROR: could not open readFilesIn=/Users/toddugine/Desktop/STAR/Trimmed_filtered/Ant_mChol_R1_trimmed.fq,

This is the first file in a list of 22 .fq files.

I ran ls -l and got the following

Todds-MacBook-Pro:Trimmed_filtered toddugine$ ls -l
total 215580632
-rw-r--r--  1 toddugine  staff  3935476179 Mar  1 21:45 Ant_mChol_R1_trimmed.fq
-rw-r--r--  1 toddugine  staff  1847680192 Mar  1 21:51 Ant_mChol_R1a_trimmed.fq
-rw-r--r--  1 toddugine  staff  5234473032 Mar  1 22:11 Ant_mChol_R2_trimmed.fq
-rw-r--r--@ 1 toddugine  staff  5215296554 Mar  4 20:46 Ant_mChol_R3_trimmed.fq
-rw-r--r--@ 1 toddugine  staff  1105012768 Mar  1 22:19 Ant_mChol_R3_trimmed.fq.gz
-rw-r--r--@ 1 toddugine  staff  4694193192 Mar  4 20:46 Ant_pChol_R1_trimmed.fq
-rw-r--r--@ 1 toddugine  staff   994574197 Mar  2 20:11 Ant_pChol_R1_trimmed.fq.gz
-rw-r--r--@ 1 toddugine  staff  4670513896 Mar  4 20:49 Ant_pChol_R2_trimmed.fq
-rw-r--r--@ 1 toddugine  staff   987856093 Mar  2 20:20 Ant_pChol_R2_trimmed.fq.gz
-rw-r--r--@ 1 toddugine  staff  5533461094 Mar  4 20:51 Ant_pChol_R3_trimmed.fq
-rw-r--r--@ 1 toddugine  staff  1171635233 Mar  2 20:56 Ant_pChol_R3_trimmed.fq.gz
-rw-r--r--@ 1 toddugine  staff  5652628432 Mar  4 20:49 Heads_mChol_R1_trimmed.fq
-rw-r--r--@ 1 toddugine  staff  1183395546 Mar  2 23:09 Heads_mChol_R1_trimmed.fq.gz
-rw-r--r--@ 1 toddugine  staff  5202407200 Mar  4 20:50 Heads_mChol_R2_trimmed.fq
-rw-r--r--@ 1 toddugine  staff  1076915744 Mar  2 23:37 Heads_mChol_R2_trimmed.fq.gz
-rw-r--r--@ 1 toddugine  staff  5137658014 Mar  4 20:50 Heads_mChol_R3_trimmed.fq
-rw-r--r--@ 1 toddugine  staff  1089881729 Mar  2 23:17 Heads_mChol_R3_trimmed.fq.gz
-rw-r--r--@ 1 toddugine  staff  4845920954 Mar  4 20:52 Heads_pChol_R1_trimmed.fq
-rw-r--r--@ 1 toddugine  staff  1020567346 Mar  2 23:44 Heads_pChol_R1_trimmed.fq.gz
-rw-r--r--  1 toddugine  staff  4236637254 Mar  2 23:24 Heads_pChol_R2_trimmed.fq
-rw-r--r--  1 toddugine  staff   721047474 Mar  2 23:46 Heads_pChol_R2a_trimmed.fq
-rw-r--r--@ 1 toddugine  staff  3570799692 Mar  4 20:52 Heads_pChol_R3_trimmed.fq
-rw-r--r--@ 1 toddugine  staff   751459303 Mar  2 23:29 Heads_pChol_R3_trimmed.fq.gz
-rw-r--r--@ 1 toddugine  staff  1748388084 Mar  4 20:52 Heads_pChol_R3a_trimmed.fq
-rw-r--r--@ 1 toddugine  staff   364778210 Mar  2 23:48 Heads_pChol_R3a_trimmed.fq.gz
-rw-r--r--@ 1 toddugine  staff        8568 Mar  4 21:22 Log.out
-rw-r--r--  1 toddugine  staff           0 Mar  4 21:22 Log.progress.out
-rw-r--r--@ 1 toddugine  staff  4956590784 Mar  4 20:52 Palp_mChol_R1_trimmed.fq
-rw-r--r--@ 1 toddugine  staff  1027197814 Mar  2 21:34 Palp_mChol_R1_trimmed.fq.gz
-rw-r--r--@ 1 toddugine  staff  5535240795 Mar  4 20:52 Palp_mChol_R2_trimmed.fq
-rw-r--r--@ 1 toddugine  staff  1160189979 Mar  2 22:23 Palp_mChol_R2_trimmed.fq.gz
-rw-r--r--@ 1 toddugine  staff  5222981874 Mar  4 20:53 Palp_mChol_R3_trimmed.fq
-rw-r--r--@ 1 toddugine  staff  1112683302 Mar  2 22:06 Palp_mChol_R3_trimmed.fq.gz
-rw-r--r--@ 1 toddugine  staff  5142643378 Mar  4 20:53 Palp_pChol_R1_trimmed.fq
-rw-r--r--@ 1 toddugine  staff  1085806152 Mar  2 21:43 Palp_pChol_R1_trimmed.fq.gz
-rw-r--r--@ 1 toddugine  staff  1805970752 Mar  4 20:53 Palp_pChol_R1a_trimmed.fq
-rw-r--r--@ 1 toddugine  staff   370584407 Mar  2 22:25 Palp_pChol_R1a_trimmed.fq.gz
-rw-r--r--@ 1 toddugine  staff  5036289162 Mar  4 20:53 Palp_pChol_R2_trimmed.fq
-rw-r--r--@ 1 toddugine  staff  1062455600 Mar  2 22:14 Palp_pChol_R2_trimmed.fq.gz
-rw-r--r--@ 1 toddugine  staff  3886929865 Mar  4 20:53 Palp_pChol_R3_trimmed.fq
-rw-r--r--@ 1 toddugine  staff   804115385 Mar  2 21:49 Palp_pChol_R3_trimmed.fq.gz

Thoughts?

ADD REPLY
0
Entering edit mode

Can you post your full command line?

ADD REPLY
0
Entering edit mode
Todds-MacBook-Pro:Trimmed_filtered toddugine$ STAR --runThreadN 4 --genomeDir ./genome_indicies --sjdbGTFfile /Users/toddugine/Desktop/STAR/alt_bam/GCF_907165205.1_icCocSept1.1_genomic.gtf --sjdbOverhang 100 --readFilesIn /Users/toddugine/Desktop/STAR/Trimmed_filtered/Ant_mChol_R1_trimmed.fq, /Users/toddugine/Desktop/STAR/Trimmed_filtered/Heads_pChol_R2_trimmed.fq, /Users/toddugine/Desktop/STAR/Trimmed_filtered/Ant_mChol_R1a_trimmed.fq, /Users/toddugine/Desktop/STAR/Trimmed_filtered/Heads_pChol_R2a_trimmed.fq, /Users/toddugine/Desktop/STAR/Trimmed_filtered/Ant_mChol_R2_trimmed.fq, /Users/toddugine/Desktop/STAR/Trimmed_filtered/Heads_pChol_R3_trimmed.fq, /Users/toddugine/Desktop/STAR/Trimmed_filtered/Ant_mChol_R3_trimmed.fq, /Users/toddugine/Desktop/STAR/Trimmed_filtered/Heads_pChol_R3a_trimmed.fq, /Users/toddugine/Desktop/STAR/Trimmed_filtered/Ant_pChol_R1_trimmed.fq, /Users/toddugine/Desktop/STAR/Trimmed_filtered/Palp_mChol_R1_trimmed.fq, /Users/toddugine/Desktop/STAR/Trimmed_filtered/Ant_pChol_R2_trimmed.fq, /Users/toddugine/Desktop/STAR/Trimmed_filtered/Palp_mChol_R2_trimmed.fq, /Users/toddugine/Desktop/STAR/Trimmed_filtered/Ant_pChol_R3_trimmed.fq, /Users/toddugine/Desktop/STAR/Trimmed_filtered/Palp_mChol_R3_trimmed.fq, /Users/toddugine/Desktop/STAR/Trimmed_filtered/Heads_mChol_R1_trimmed.fq, /Users/toddugine/Desktop/STAR/Trimmed_filtered/Palp_pChol_R1_trimmed.fq, /Users/toddugine/Desktop/STAR/Trimmed_filtered/Heads_mChol_R2_trimmed.fq, /Users/toddugine/Desktop/STAR/Trimmed_filtered/Palp_pChol_R1a_trimmed.fq, /Users/toddugine/Desktop/STAR/Trimmed_filtered/Heads_mChol_R3_trimmed.fq, /Users/toddugine/Desktop/STAR/Trimmed_filtered/Palp_pChol_R2_trimmed.fq, /Users/toddugine/Desktop/STAR/Trimmed_filtered/Heads_pChol_R1_trimmed.fq, /Users/toddugine/Desktop/STAR/Trimmed_filtered/Palp_pChol_R3_trimmed.fq --outSAMtype BAM SortedByCoordinate Unsorted
ADD REPLY
0
Entering edit mode

Is this a multiline input and single line input for fastqs? In addition, there are multiple samples and for each sample, there seem to be R1 and R2. Check if your input is correct for multiple samples and for paired reads.

ADD REPLY
0
Entering edit mode

It is not a question of efficiency. You need to follow directions required for specifying the files. You can't have spaces around the commas separating file names. STAR manual specifies the following:

Multiple samples can be mapped in one job. For single-end reads use a comma separated list (no spaces around commas), e.g. --readFilesIn sample1.fq,sample2.fq,sample3.fq.For paired-end reads, use comma separated list for read1 /space/ comma separated list for read2, e.g.: --readFilesIn sample1read1.fq,sample2read1.fq,sample3read1.fq sample1read2.fq,sample2read2.fq,sample3read2.fq.

ADD REPLY
0
Entering edit mode

These are single-end reads, not paired-end. And the R1, R2 etc are replicates for each treatment/ condition. I though reading them all in at once would be more efficient. Also, it’s balking at taking in the very first set of data. Maybe I’ll try just one sample and see if I can get that to work.

ADD REPLY
0
Entering edit mode

R1, R2 etc are replicates for each treatment/ condition

R1/R2 in file names have a specific meaning for paired-end Illumina data. They represent two reads from two ends of a set of fragments. STAR will expect that to be the case and I wonder if that is confusing it since you have single-end data.

If R1/R2 in names represent replicates in your case then try renaming the files so they say something like rep1 instead of R1.

ADD REPLY
0
Entering edit mode

Also, I removed all of the commas ',' and reran the whole script with all the replicates and I don't get the error below anymore. I think it was expecting there to be a comma at the end of the file name.

EXITING because of fatal input ERROR: could not open readFilesIn=/Users/toddugine/Desktop/STAR/Trimmed_filtered/Ant_mChol_R1_trimmed.fq,

However, now I get "Segmentation fault: 11", and it doesn't run.

ADD REPLY
0
Entering edit mode

what's the genome size and how did you generate indices?

ADD REPLY
0
Entering edit mode

400MB, and I used STAR to generate the indices/suffix arrays.

Todds-MacBook-Pro:ncbi-genomes-2021-08-24 toddugine$ STAR --runThreadN 4 --runMode genomeGenerate --genomeSAindexNbases 13 --genomeDir ./genome_indicies_2 --genomeFastaFiles GCA_907165205.1_icCocSept1.1_genomic.fna STAR --runThreadN 4 --runMode genomeGenerate --genomeSAindexNbases 13 --genomeDir ./genome_indicies_2 --genomeFastaFiles GCA_907165205.1_icCocSept1.1_genomic.fna STAR version: 2.7.10a
compiled: :/Users/travis/build/alexdobin/travis-tests/STARcompile/source Mar 03 20:48:53 ..... started STAR run Mar 03 20:48:53 ... starting to generate Genome files Mar 03 20:49:01 ... starting to sort Suffix Array. This may take a long time... Mar 03 20:49:03 ... sorting Suffix Array chunks and saving them to disk... Mar 03 20:53:25 ... loading chunks from disk, packing SA... Mar 03 20:53:35 ... finished generating suffix array Mar 03 20:53:35 ... generating Suffix Array index Mar 03 20:54:23 ... completed Suffix Array index Mar 03 20:54:23 ... writing Genome to disk ... Mar 03 20:54:23 ... writing Suffix Array to disk ... Mar 03 20:54:25 ... writing SAindex to disk Mar 03 20:54:26 ..... finished successfully

ADD REPLY
0
Entering edit mode

Let's see. I added the comma back between each file, removed the space, and ran the code WITH the R1, R2, R3, b/c I hadn't seen this message yet.

It ran and completed.

Is it safe to assume that b/c I entered it as single-end (comma separated, no space) that my Aligned.sortedByCoord.out.bam is okay? or do I need to rerun?

Todds-MacBook-Pro:Trimmed_filtered toddugine$ STAR --runThreadN 4 --genomeDir /Users/toddugine/Desktop/C7_Hi_C_assembly/ncbi-genomes-2021-08-24/genome_indicies --readFilesIn /Users/toddugine/Desktop/STAR/Trimmed_filtered/Ant_mChol_R1_trimmed.fq,/Users/toddugine/Desktop/STAR/Trimmed_filtered/Ant_mChol_R1a_trimmed.fq,/Users/toddugine/Desktop/STAR/Trimmed_filtered/Ant_mChol_R2_trimmed.fq,/Users/toddugine/Desktop/STAR/Trimmed_filtered/Ant_mChol_R3_trimmed.fq,/Users/toddugine/Desktop/STAR/Trimmed_filtered/Ant_pChol_R1_trimmed.fq,/Users/toddugine/Desktop/STAR/Trimmed_filtered/Palp_mChol_R1_trimmed.fq,/Users/toddugine/Desktop/STAR/Trimmed_filtered/Ant_pChol_R2_trimmed.fq,/Users/toddugine/Desktop/STAR/Trimmed_filtered/Palp_mChol_R2_trimmed.fq,/Users/toddugine/Desktop/STAR/Trimmed_filtered/Ant_pChol_R3_trimmed.fq,/Users/toddugine/Desktop/STAR/Trimmed_filtered/Palp_mChol_R3_trimmed.fq,/Users/toddugine/Desktop/STAR/Trimmed_filtered/Palp_pChol_R1_trimmed.fq,/Users/toddugine/Desktop/STAR/Trimmed_filtered/Palp_pChol_R1a_trimmed.fq,/Users/toddugine/Desktop/STAR/Trimmed_filtered/Palp_pChol_R2_trimmed.fq,/Users/toddugine/Desktop/STAR/Trimmed_filtered/Palp_pChol_R3_trimmed.fq --outSAMtype BAM SortedByCoordinate Unsorted

ADD REPLY

Login before adding your answer.

Traffic: 1829 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