This is a test version of Biostars. For the public version, visit https://www.biostars.org.
bbduk memory error

Hello everyone,

I've installed bbmap throw sudo apt-get install bbmap and also by downloading the package, untaring it and adding the path to the directory in the .bashrc file. However, when running bbduk.sh --version or a script bbduk.sh -Xmx... (I've tried with -Xmx5g, -Xmx4g, -Xmx1g, -Xmx800m, -Xmx100m and without setting -Xmx on a 8 gb RAM machine) I get the following error:

/usr/bin/bbduk.sh: línea 344: /usr/share/bbmap/calcmem: No existe el archivo o el directorio
/usr/bin/bbduk.sh: línea 345: setEnvironment: orden no encontrada
/usr/bin/bbduk.sh: línea 346: parseXmx: orden no encontrada
/usr/bin/bbduk.sh: línea 350: freeRam: orden no encontrada
java -Xmxm -Xmsm -cp /usr/share/java/bbmap.jar jgi.BBDuk --version
Invalid maximum heap size: -Xmxm
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.

Also, the folder /calcmem does indeed do not exist. Any ideas on how to solve this problem?

Thank you!

bbduk java bbtools memory

1 answer

Either install BBTools with conda, or download BBTools / BBMap from the official SourceForge page, unpack and add the destination folder to the path.

This seems to be a bug of the Debian / Ubuntu BBTools package of your particular operating system version. You should open a bug issue at your distro proper channel. The problem is calcmen.sh is not copied to a directory on the path.

I use Debian (testing) on my laptop, and it seems I am not affected by this bug:

$ bbduk.sh --version
java -ea -Xmx1996m -Xms1996m -cp /usr/share/java/bbmap.jar jgi.BBDuk --version
BBMap version 38.90
For help, please run the shellscript with no parameters, or look in /docs/.

As all scripts seem to be present under /usr/share/bbmap/, you can also try this hackish solution:

export PATH=$PATH:/usr/share/bbmap

I've re-tried download from SourceForge, unpack and add to PATH in .bashrc file (export PATH="/media/Archivos/Programas/BBMap_38.90:$PATH") but still not working. The hackish solution hasn't work either. Also installing from conda gave the following error:

(base) gaston@gaston-nb:~$ conda install -c agbiome bbtools
Collecting package metadata (current_repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
Solving environment: failed with repodata from current_repodata.json, will retry with next repodata source.
Collecting package metadata (repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
Solving environment:
Found conflicts! Looking for incompatible packages.
This can take several minutes.  Press CTRL-C to abort.
failed
UnsatisfiableError:
(base) gaston@gaston-nb:

Any ideas?

I'll try reporting this issue to Ubuntu but I guess that can take a while to solve.

Please use the formatting bar (especially the code option) to present your post better. You can use backticks for inline code (`text` becomes text), or select a chunk of text and use the highlighted button to format it as a code block. If your code has long lines with a single command, break those lines into multiple lines with proper escape sequences so they're easier to read and still run when copy-pasted. I've done it for you this time.
code_formatting

Log in to answer this question.