Problem with uploading data


I received raw data from 16s sequencing on Illumina and I have list of folders: " name of sample_run.fastq" and inside of every one of them there are 2 files named: “forward.fastqsanger.gz” and “reversed.fastqsanger.gz”. When i try to upload folders i just get them empty and i cannot upload the inner files because they dont have any sample specific name. How can i solve this without manually renaming every"fastqsanger.gz" file?


Yes, you’ll need to rename the files so that the sample name is included. A shell script is probably your best option to do this in batch. And internet search will show many recipes.

Example search phrase I used with Google: “rename file based on folder name shell”
The first two top hits I found seems like a good place to start but you can review:

Then you can use the Upload → Rule Based to get the data into Galaxy in an organized way. Note that the data needs to have a public URL for this method.

Or, get the data into Galaxy first via regular Upload, then use a tool like Collection Operations → Apply rules or Build list to organize those files once in Galaxy.

For the Galaxy part, please see: Using Galaxy and Managing your Data

Hope that helps!


Thank you for your help, I will look into those scripts. Right now i have only 50 folders but in the future without scripts it could be hard if there were more. Once again thank you for your help.

1 Like