EBI-Metagenomics / emg-viral-pipeline

VIRify: detection of phages and eukaryotic viruses from metagenomic and metatranscriptomic assemblies
Apache License 2.0
128 stars 16 forks source link

Trouble to run the example execution - Error executing process > `detect:pprmeta (1)` #126

Open krluka opened 5 months ago

krluka commented 5 months ago

Dear,

When I try to run the example execution with -profile local,singularity I get the following error message:

ERROR:

ERROR ~ Error executing process > 'detect:pprmeta (1)'

Caused by:
  Process `detect:pprmeta (1)` terminated with an error exit status (255)

Command executed:

  [ -d "pprmeta" ] && cp pprmeta/* .
  ./PPR_Meta assembly_renamed_filt1500bp.fasta assembly_pprmeta.csv

Command exit status:
  255

Command output:
  (empty)

Command error:
  INFO:    Environment variable SINGULARITYENV_NXF_TASK_WORKDIR is set, but APPTAINERENV_NXF_TASK_WORKDIR is preferred
  Could not access the MATLAB Runtime component cache. Details: fl:filesystem:SystemError; component cache root:; componentname: PPR_Meta

Work dir:
  /scratch/lukak/virify/89/da5d86a7234aabd05dfd7b618633e0

I don't have many experience with singularity/apptainer so any kind of help would be much appreciated.

Best regards,

Luka

mberacochea commented 4 months ago

Hey @krluka

Apologies for a very delayed response.

That looks like a there are issues with permissions on the directory the task is being executed. Do you have write/read/execute permissions on /scratch/lukak/virify/89/da5d86a7234aabd05dfd7b618633e0? I'm not very familiar with the MATLAB runtime, and I have never bumped into this problem.

If you are running this on an HPC cluster, could you contact your support team? They may be able to provide some guidance.

Cheers

krluka commented 4 months ago

Hey @mberacochea

Thank you for your reply.

I checked with local support and it seems that necessary permissions are in place.

Best,

Luka

mberacochea commented 4 months ago

Hey @krluka

Can you share the whole .nextflow.log file for the run please?. I'm not sure what is going one, and that log file may have some clues.

Cheers

krluka commented 4 months ago

Hey @mberacochea

Sure, I'm attaching it to this post.

Best,

Luka

nextflow.log

dbespiatykh commented 3 months ago

Hey @krluka,

I had the same issue on HPC without admin rights, and I was able to fix it by setting up the MCR_CACHE_ROOT=</writable/dir> environment variable with writable directory.

mberacochea commented 3 months ago

@dbespiatykh Can you try @dbespiatykh suggestion?

Thanks @dbespiatykh I will add this to the documentation

krluka commented 3 months ago

Hey @dbespiatykh,

Thank you for the suggestion - I will try that the first chance I get.

@mberacochea I'll post the outcome as soon I have it.

egenomics commented 3 months ago

I have the same error: ERROR ~ Error executing process > 'detect:pprmeta (1)'

Caused by: Process detect:pprmeta (1) terminated with an error exit status (255)

Command executed:

[ -d "pprmeta" ] && cp pprmeta/* . ./PPR_Meta assembly_renamed_filt1500bp.fasta assembly_pprmeta.csv

Command exit status: 255

Command output: (empty)

Command error: Could not access the MATLAB Runtime component cache. Details: fl:filesystem:SystemError; component cache root:; componentname: PPR_Meta

Work dir: /soft/test_viral./work/e1/ba3c3cf6378ba3500b2882c1391883

Tip: you can try to figure out what's wrong by changing to the process work dir and showing the script file named .command.sh

-- Check '.nextflow.log' file for details

In an installation from scratch.

mberacochea commented 3 months ago

Hi @egenomics

Did you try @dbespiatykh suggestion?

I had the same issue on HPC without admin rights, and I was able to fix it by setting up the MCR_CACHE_ROOT=</writable/dir> environment variable with writable directory.

Cheers

egenomics commented 3 months ago

I am in a local machine (testing it). When I use your suggestion about setting upthe MCR_CACHE_ROOT I get a similar error: ERROR ~ Error executing process > 'detect:pprmeta (1)'

Caused by: Process detect:pprmeta (1) terminated with an error exit status (255)

Command executed:

[ -d "pprmeta" ] && cp pprmeta/* . ./PPR_Meta assembly_renamed_filt1500bp.fasta assembly_pprmeta.csv

Command exit status: 255

Command output: (empty)

Command error:

Could not access the MATLAB Runtime component cache. Details: fl:filesystem:SystemError; component cache root:; componentname: PPR_Meta

Work dir: /soft/test_viral./work/ae/9ed47b42f085011346e1ceff79c36e

Tip: when you have fixed the problem you can continue the execution adding the option -resume to the run command line

-- Check '.nextflow.log' file for details

dbespiatykh commented 3 months ago

Hey @egenomics,

Try doing this:

export MCR_CACHE_ROOT=/your/writable/directory

./PPR_Meta_w "$@"

And try running the pipeline again

egenomics commented 3 months ago

Hi, I did it and it works with the test!

thanks

mberacochea commented 3 months ago

Hey @egenomics,

Try doing this:

* 1. Inside the VIRify database directory, locate the `/pprmeta` directory, and rename file `PPR_Meta` to something like `PPR_Meta_w`

* 2. Create file named `PPR_Meta` and paste the following code in it:
export MCR_CACHE_ROOT=/your/writable/directory

./PPR_Meta_w "$@"
* 3. Run `chmod +x PPR_Meta`

And try running the pipeline again

Brilliant, and validated by @egenomics. I'll add this to the README.

Thank you @dbespiatykh

corvinux commented 3 months ago

export MCR_CACHE_ROOT doesn't work on nfs shares. I had to set it on local filesystem.