Is it possible to use nohup command with mothur?

Dear Sirs/Mesdames

Recently I am trying to treat my data from the Miseq sequencing by following the Mothur Miseq SOP. It went quite fluently until I was in the dist.seqs command. It seems taking a lot of computing power to finish it with a big data (the trim.contigs.fasta is 6.16 GB). Thus, I switched it to a cloud server with more processors to process this step. I linked it with the terminal and setup mothur working environment there. I tested it with another command and it went well. I started to run the dist.seqs command using that cloud system. It’s a linux environment.

However, the terminal revealed “broken pipe” to me several times. Once it happened, the running program was stopped. To prevent the broken pipe happens again, I tried to set up the nohup function by putting a nohup program to the directory where mothur executable file is. Then tried several commands like:

prompt$ nohup ./mothur “#dist.seqs(fasta=file.trim.contigs.good.unique.good.filter.unique.precluster.pick.pick.pick.fasta, cutoff=0.20, processors=20)” &

or

prompt$ nohup mothur “#dist.seqs(fasta=file.trim.contigs.good.unique.good.filter.unique.precluster.pick.pick.pick.fasta, cutoff=0.20, processors=20)” &

and they always gave me the error message like:

-bash: syntax error near unexpected token `(’

It seems that I cannot use ( without get into the mothur environment.

And if I get into mothur’s executable file, and use the command like:

mothur > nohup ./mothur dist.seqs(fasta=file.trim.contigs.good.unique.good.filter.unique.precluster.pick.pick.pick.fasta, cutoff=0.20, processors=20) &

And of course it showed me a list of the commands that I can use, not including nohup.

I am wondering if I can do something for it and don’t let the broken pipe happens again; thus, the program can finish its work without being interrupted.

Thank you for your consideration!

Best Regards,

Chih

I’m not sure what’s going on with nohup - that’s weird, but it looks like it doesn’t parse the string like it should. It will definitely not work from the mothur prompt. You would have to do it from with in the shell environment. A few options…

  1. Put your command into a batch file and then run:
nohup ./mothur batch.file
  1. Use the screen command
  2. Use a pbs scheduler to submit jobs

In our lab we do 2 and 3 where the commands we enter are like 1.

Pat