Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

unable to run on mac #530

Closed
proukakis opened this issue Sep 28, 2021 · 6 comments
Closed

unable to run on mac #530

proukakis opened this issue Sep 28, 2021 · 6 comments

Comments

@proukakis
Copy link

Hi, it is possible i am doing something very stupid, so i apologise in advance.
I compiled with conda (miniconda3) on a Mac Mojave.
I am trying to run as follows

gridss\

-r /Volumes/Toshiba4Tb/GenomeReferences/hg38.fa
-j /Users/christos/gridss/gridss-2.12.1-gridss-jar-with-dependencies.jar
-o/Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/gridss.vcf
-b /Users/christos/gridss/ENCFF356LFX.bed
/Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/D5-78408_merged.bam
/Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/D5-78409_merged.bam --skipsoftcliprealignment

and i get

--
WARNING: "getopt --test"` failed in this environment.
WARNING: The version of getopt(1) installed on this system might not be compatible with the GRIDSS driver script.
Using working directory "."
Tue Sep 28 12:06:47 BST 2021: Full log file is: ./gridss.full.20210928_120647.Christoss-giant-Mac.local.7821.log
Tue Sep 28 12:06:47 BST 2021: Found /usr/bin/time
/usr/bin/time: illegal option -- -
usage: time [-lp] command.
/usr/bin/time: illegal option -- a
usage: time [-lp] command.
Tue Sep 28 12:06:47 BST 2021: Unexpected /usr/bin/time version. Not logging timing information.
Tue Sep 28 12:06:47 BST 2021: Unable to find gridss jar. Specify using the environment variant GRIDSS_JAR, or the --jar command line parameter.
"gridss_jar=$(find_jar GRIDSS_JAR gridss)" command completed with exit code 66.


The underlying error message can be found in ./gridss.full.20210928_120647.Christoss-giant-Mac.local.7821.log


log file

Tue Sep 28 12:06:47 BST 2021: Full log file is: ./gridss.full.20210928_120647.Christoss-giant-Mac.local.7821.log
Tue Sep 28 12:06:47 BST 2021: Found /usr/bin/time
Tue Sep 28 12:06:47 BST 2021: Unexpected /usr/bin/time version. Not logging timing information.
Tue Sep 28 12:06:47 BST 2021: Unable to find gridss jar. Specify using the environment variant GRIDSS_JAR, or the --jar command line parameter.

so it can't find the .jar, although i thought my command is pointing to it?

Any help welcome!

@d-cameron
Copy link
Member

/usr/bin/time: illegal option -- -
usage: time [-lp] command.
/usr/bin/time: illegal option -- a
usage: time [-lp] command.

I don't have a mac to reproduce your issue but it looks like your /usr/bin/time is not compatable with GNU time. Try installing the time package through conda.

@proukakis
Copy link
Author

THanks- here is what i have tried, which seems to take things forward a bit, but didnt solve it

conda install time didnt seem to help

i installed gnu-time and gnu-getopt through "brew install"

then added them to path which is now

/usr/local/opt/gnu-getopt/bin:/usr/local/opt/gnu-time/libexec/gnubin:/Users/christos/miniconda3/bin:/Users/christos/miniconda3/condabin:/usr/bin:/usr/local/sbin:/usr/local/bin:/usr/local/bin:/usr/local/sbin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/ncbi/blast/bin:/Library/TeX/texbin:/opt/X11/bin

then used again

gridss\

-r /Volumes/Toshiba4Tb/GenomeReferences/hg38.fa
-j /Users/christos/gridss/gridss-2.12.1-gridss-jar-with-dependencies.jar
-o/Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/gridss.vcf
-b /Users/christos/gridss/ENCFF356LFX.bed
/Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/D5-78408_merged.bam
/Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/D5-78409_merged.bam
Using working directory "."
Wed Sep 29 11:21:23 BST 2021: Full log file is: ./gridss.full.20210929_112123.Christoss-giant-Mac.local.17274.log
Wed Sep 29 11:21:23 BST 2021: Found /usr/bin/time
/usr/bin/time: illegal option -- -
usage: time [-lp] command.
/usr/bin/time: illegal option -- a
usage: time [-lp] command.
Wed Sep 29 11:21:23 BST 2021: Unexpected /usr/bin/time version. Not logging timing information.
Wed Sep 29 11:21:23 BST 2021: Using GRIDSS jar /Users/christos/gridss/gridss-2.12.1-gridss-jar-with-dependencies.jar
Wed Sep 29 11:21:23 BST 2021: Using reference genome "/Volumes/Toshiba4Tb/GenomeReferences/hg38.fa"
Wed Sep 29 11:21:23 BST 2021: Using output VCF /Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/gridss.vcf
Wed Sep 29 11:21:23 BST 2021: Using assembly bam /Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/gridss.vcf.assembly.bam
Wed Sep 29 11:21:23 BST 2021: Using 8 worker threads.
Wed Sep 29 11:21:23 BST 2021: Using blacklist /Users/christos/gridss/ENCFF356LFX.bed
Wed Sep 29 11:21:23 BST 2021: Using JVM maximum heap size of 30g for assembly and variant calling.
Wed Sep 29 11:21:23 BST 2021: Using input file /Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/D5-78408_merged.bam
Wed Sep 29 11:21:23 BST 2021: Using input file /Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/D5-78409_merged.bam
Wed Sep 29 11:21:23 BST 2021: Found /Users/christos/miniconda3/bin/Rscript
Wed Sep 29 11:21:23 BST 2021: Found /Users/christos/miniconda3/bin/samtools
Wed Sep 29 11:21:23 BST 2021: Found /Users/christos/miniconda3/bin/java
Wed Sep 29 11:21:23 BST 2021: Found /Users/christos/miniconda3/bin/bwa
Wed Sep 29 11:21:23 BST 2021: samtools version: 1.13+htslib-1.13
Wed Sep 29 11:21:23 BST 2021: R version: R scripting front-end version 4.1.1 (2021-08-10)
Wed Sep 29 11:21:23 BST 2021: bwa Version: 0.7.17-r1188
Wed Sep 29 11:21:23 BST 2021: time version: /usr/bin/time: illegal option -- -
usage: time [-lp] command.
Wed Sep 29 11:21:23 BST 2021: bash version: GNU bash, version 3.2.57(1)-release (x86_64-apple-darwin18)
Wed Sep 29 11:21:24 BST 2021: java version: openjdk version "11.0.9.1" 2020-11-04 LTS OpenJDK Runtime Environment Zulu11.43+55-CA (build 11.0.9.1+1-LTS) OpenJDK 64-Bit Server VM Zulu11.43+55-CA (build 11.0.9.1+1-LTS, mixed mode)
/Users/christos/miniconda3/share/gridss-2.11.1-1/gridss.sh: line 482: ulimit: open files: cannot modify limit: Invalid argument
"ulimit -n $(ulimit -Hn)" command completed with exit code 1.


The underlying error message can be found in ./gridss.full.20210929_112123.Christoss-giant-Mac.local.17274.log


here is the log

Wed Sep 29 11:21:23 BST 2021: Full log file is: ./gridss.full.20210929_112123.Christoss-giant-Mac.local.17274.log
Wed Sep 29 11:21:23 BST 2021: Found /usr/bin/time
Wed Sep 29 11:21:23 BST 2021: Unexpected /usr/bin/time version. Not logging timing information.
Wed Sep 29 11:21:23 BST 2021: Using GRIDSS jar /Users/christos/gridss/gridss-2.12.1-gridss-jar-with-dependencies.jar
Wed Sep 29 11:21:23 BST 2021: Using reference genome "/Volumes/Toshiba4Tb/GenomeReferences/hg38.fa"
Wed Sep 29 11:21:23 BST 2021: Using output VCF /Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/gridss.vcf
Wed Sep 29 11:21:23 BST 2021: Using assembly bam /Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/gridss.vcf.assembly.bam
Wed Sep 29 11:21:23 BST 2021: Using 8 worker threads.
Wed Sep 29 11:21:23 BST 2021: Using blacklist /Users/christos/gridss/ENCFF356LFX.bed
Wed Sep 29 11:21:23 BST 2021: Using JVM maximum heap size of 30g for assembly and variant calling.
Wed Sep 29 11:21:23 BST 2021: Using input file /Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/D5-78408_merged.bam
Wed Sep 29 11:21:23 BST 2021: Using input file /Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/D5-78409_merged.bam
Wed Sep 29 11:21:23 BST 2021: Found /Users/christos/miniconda3/bin/Rscript
Wed Sep 29 11:21:23 BST 2021: Found /Users/christos/miniconda3/bin/samtools
Wed Sep 29 11:21:23 BST 2021: Found /Users/christos/miniconda3/bin/java
Wed Sep 29 11:21:23 BST 2021: Found /Users/christos/miniconda3/bin/bwa
Wed Sep 29 11:21:23 BST 2021: samtools version: 1.13+htslib-1.13
Wed Sep 29 11:21:23 BST 2021: R version: R scripting front-end version 4.1.1 (2021-08-10)
Wed Sep 29 11:21:23 BST 2021: bwa Version: 0.7.17-r1188
Wed Sep 29 11:21:23 BST 2021: time version: /usr/bin/time: illegal option -- -
usage: time [-lp] command.
Wed Sep 29 11:21:23 BST 2021: bash version: GNU bash, version 3.2.57(1)-release (x86_64-apple-darwin18)
Wed Sep 29 11:21:24 BST 2021: java version: openjdk version "11.0.9.1" 2020-11-04 LTS OpenJDK Runtime Environment Zulu11.43+55-CA (build 11.0.9.1+1-LTS) OpenJDK 64-Bit Server VM Zulu11.43+55-CA (build 11.0.9.1+1-LTS, mixed mode)

I realise the gnu-time is actually called gtime

Christoss-giant-Mac:~ christos$ gtime --version
time (GNU Time) 1.9
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later https://gnu.org/licenses/gpl.html.

so i wonder if the gridss script needs to be edited to look for gtime rather than time?

Let me know if you think this makes sense

thanks again
christos

@proukakis
Copy link
Author

FWIW, i had run v1.5 using java -jar command

when i try now using the same command structure

java -jar gridss-2.12.1-gridss-jar-with-dependencies.jar O=/Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/gridss.vcf ASSEMBLY=/Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/D5-78408_gridss.bam I=/Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/D5-78408_merged.bam REFERENCE_SEQUENCE=/Volumes/Toshiba4Tb/GenomeReferences/hg38.fa

i get
Error: Could not find or load main class >gridss.CallVariants
Caused by: java.lang.ClassNotFoundException: >gridss.CallVariants

not sure if this easier to solve?

@d-cameron
Copy link
Member

Rereading the error message I see:

Wed Sep 29 11:21:23 BST 2021: Unexpected /usr/bin/time version. Not logging timing information.

Which means my time arg checking is actually working

Wed Sep 29 11:21:23 BST 2021: time version: /usr/bin/time: illegal option -- -

But I'm still trying to get the time version even when I'm not actually using time. Not a fatal error, just a spurious error message. Now fixed in dev

/Users/christos/miniconda3/share/gridss-2.11.1-1/gridss.sh: line 482: ulimit: open files: cannot modify limit: Invalid argument
"ulimit -n $(ulimit -Hn)" command completed with exit code 1.

This is the root cause: you are unable to set the your file handle ulimit (maybe different args on macOS?) I've fixed this issue (in dev) by ignoring the result of the ulimit. Your current ulimit might already be sufficient so there's no reason to die this early.

If you want to test this yourself, edit your gridss (e.g. vim $(which gridss)) and change the ulimit line to:
ulimit -n $(ulimit -Hn) || true

@proukakis
Copy link
Author

thanks- there is a problem in mac apparently- i have tried setting the max open files to 1000000, and editing gridss, but still no luck

Using working directory "."
Fri Oct 1 11:25:29 BST 2021: Full log file is: ./gridss.full.20211001_112529.Christoss-giant-Mac.local.43823.log
Fri Oct 1 11:25:29 BST 2021: Found /usr/bin/time
/usr/bin/time: illegal option -- -
usage: time [-lp] command.
/usr/bin/time: illegal option -- a
usage: time [-lp] command.
Fri Oct 1 11:25:29 BST 2021: Unexpected /usr/bin/time version. Not logging timing information.
Fri Oct 1 11:25:29 BST 2021: Using GRIDSS jar /Users/christos/gridss/gridss-2.12.1-gridss-jar-with-dependencies.jar
Fri Oct 1 11:25:29 BST 2021: Using reference genome "/Volumes/Toshiba4Tb/GenomeReferences/hg38.fa"
Fri Oct 1 11:25:29 BST 2021: Using output VCF /Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/gridss.vcf
Fri Oct 1 11:25:29 BST 2021: Using assembly bam /Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/gridss.vcf.assembly.bam
Fri Oct 1 11:25:29 BST 2021: Using 8 worker threads.
Fri Oct 1 11:25:29 BST 2021: Using blacklist /Users/christos/gridss/ENCFF356LFX.bed.gz
Fri Oct 1 11:25:29 BST 2021: Using JVM maximum heap size of 30g for assembly and variant calling.
Fri Oct 1 11:25:29 BST 2021: Using input file /Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/D5-78408_merged.bam
Fri Oct 1 11:25:29 BST 2021: Using input file /Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/D5-78409_merged.bam
Fri Oct 1 11:25:29 BST 2021: Found /Users/christos/miniconda3/bin/Rscript
Fri Oct 1 11:25:29 BST 2021: Found /Users/christos/miniconda3/bin/samtools
Fri Oct 1 11:25:29 BST 2021: Found /Users/christos/miniconda3/bin/java
Fri Oct 1 11:25:29 BST 2021: Found /Users/christos/miniconda3/bin/bwa
Fri Oct 1 11:25:29 BST 2021: samtools version: 1.13+htslib-1.13
Fri Oct 1 11:25:29 BST 2021: R version: R scripting front-end version 4.1.1 (2021-08-10)
Fri Oct 1 11:25:29 BST 2021: bwa Version: 0.7.17-r1188
Fri Oct 1 11:25:29 BST 2021: time version: /usr/bin/time: illegal option -- -
usage: time [-lp] command.
Fri Oct 1 11:25:29 BST 2021: bash version: GNU bash, version 3.2.57(1)-release (x86_64-apple-darwin18)
Fri Oct 1 11:25:29 BST 2021: java version: openjdk version "11.0.9.1" 2020-11-04 LTS OpenJDK Runtime Environment Zulu11.43+55-CA (build 11.0.9.1+1-LTS) OpenJDK 64-Bit Server VM Zulu11.43+55-CA (build 11.0.9.1+1-LTS, mixed mode)
/Users/christos/miniconda3/share/gridss-2.11.1-1/gridss.sh: line 482: ulimit: open files: cannot modify limit: Invalid argument
"ulimit -n $(ulimit -Hn)" command completed with exit code 1.


The underlying error message can be found in ./gridss.full.20211001_112529.Christoss-giant-Mac.local.43823.log


Log file

Fri Oct 1 11:25:29 BST 2021: Full log file is: ./gridss.full.20211001_112529.Christoss-giant-Mac.local.43823.log
Fri Oct 1 11:25:29 BST 2021: Found /usr/bin/time
Fri Oct 1 11:25:29 BST 2021: Unexpected /usr/bin/time version. Not logging timing information.
Fri Oct 1 11:25:29 BST 2021: Using GRIDSS jar /Users/christos/gridss/gridss-2.12.1-gridss-jar-with-dependencies.jar
Fri Oct 1 11:25:29 BST 2021: Using reference genome "/Volumes/Toshiba4Tb/GenomeReferences/hg38.fa"
Fri Oct 1 11:25:29 BST 2021: Using output VCF /Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/gridss.vcf
Fri Oct 1 11:25:29 BST 2021: Using assembly bam /Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/gridss.vcf.assembly.bam
Fri Oct 1 11:25:29 BST 2021: Using 8 worker threads.
Fri Oct 1 11:25:29 BST 2021: Using blacklist /Users/christos/gridss/ENCFF356LFX.bed.gz
Fri Oct 1 11:25:29 BST 2021: Using JVM maximum heap size of 30g for assembly and variant calling.
Fri Oct 1 11:25:29 BST 2021: Using input file /Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/D5-78408_merged.bam
Fri Oct 1 11:25:29 BST 2021: Using input file /Volumes/LaCie_rugged/P70_06/IlluminaWGS_P70_06/D5-78409_merged.bam
Fri Oct 1 11:25:29 BST 2021: Found /Users/christos/miniconda3/bin/Rscript
Fri Oct 1 11:25:29 BST 2021: Found /Users/christos/miniconda3/bin/samtools
Fri Oct 1 11:25:29 BST 2021: Found /Users/christos/miniconda3/bin/java
Fri Oct 1 11:25:29 BST 2021: Found /Users/christos/miniconda3/bin/bwa
Fri Oct 1 11:25:29 BST 2021: samtools version: 1.13+htslib-1.13
Fri Oct 1 11:25:29 BST 2021: R version: R scripting front-end version 4.1.1 (2021-08-10)
Fri Oct 1 11:25:29 BST 2021: bwa Version: 0.7.17-r1188
Fri Oct 1 11:25:29 BST 2021: time version: /usr/bin/time: illegal option -- -
usage: time [-lp] command.
Fri Oct 1 11:25:29 BST 2021: bash version: GNU bash, version 3.2.57(1)-release (x86_64-apple-darwin18)
Fri Oct 1 11:25:29 BST 2021: java version: openjdk version "11.0.9.1" 2020-11-04 LTS OpenJDK Runtime Environment Zulu11.43+55-CA (build 11.0.9.1+1-LTS) OpenJDK 64-Bit Server VM Zulu11.43+55-CA (build 11.0.9.1+1-LTS, mixed mode)

here is my edited script, does it look correct?

ulimit -n $(ulimit -Hn) || true # Reduce likelihood of running out of open file handles
unset DISPLAY # Prevents errors attempting to connecting to an X server when starting the R plotting device
write_status "Max file handles: $(ulimit -n)" 1>&2

d-cameron pushed a commit that referenced this issue Nov 15, 2021
@d-cameron
Copy link
Member

d-cameron commented Nov 15, 2021

/Users/christos/miniconda3/share/gridss-2.11.1-1/gridss.sh: line 482: ulimit: open files: cannot modify limit: Invalid argument

Looks like the reason your change failed was that you changed the gridss v2.12.1 file, but was running gridss.sh v2.11.1. Note that 2.12 changed the name of the executable from gridss.sh to gridss.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants