bioperl-live icon indicating copy to clipboard operation
bioperl-live copied to clipboard

EXCEPTION: Bio::Root::Exception Inappropriate ioctl for device

Open moldach opened this issue 4 years ago • 5 comments

I'm getting an error from bioperl that I don't know how to solve. I assume something with my bioperl is broken as this code works on a colleagues ComputeCanada account.

[moldach@cedar1 SNAKEMAKE]$ /home/moldach/projects/def-mtarailo/common/tools/CooVar/coovar.pl --cores 6 -e /home/moldach/projects/def-mtarailo/common/indexes/WS265_wormbase/c_elegans.PRJNA13758.WS265.annotations.gff3 -r /home/moldach/projects/def-mtarailo/common/indexes/WS265_wormbase/c_elegans.PRJNA13758.WS265.genomic.fa.gz -t calling/varscan/470_sorted_dedupped_snp_varscan.tsv -o /annotation/coovar/470 --circos
\Unknown option: cores
[coovar.pl] Start executing script on Thu Apr 23 11:40:56 2020
[coovar.pl] Operating system: linux x86_64-linux-thread-multi
[coovar.pl] Program directory: /home/moldach/projects/def-mtarailo/common/tools/CooVar
[coovar.pl] Program version: 0.07
[coovar.pl] Command line: /home/moldach/projects/def-mtarailo/common/tools/CooVar/coovar.pl --cores 6 -e /home/moldach/projects/def-mtarailo/common/indexes/WS265_wormbase/c_elegans.PRJNA13758.WS265.annotations.gff3 -r /home/moldach/projects/def-mtarailo/common/indexes/WS265_wormbase/c_elegans.PRJNA13758.WS265.genomic.fa.gz -t calling/varscan/470_sorted_dedupped_snp_varscan.tsv -o /annotation/coovar/470 --circos
[coovar.pl]   REFERENCE: /home/moldach/projects/def-mtarailo/common/indexes/WS265_wormbase/c_elegans.PRJNA13758.WS265.genomic.fa.gz
[coovar.pl]   CODING EXONS: /home/moldach/projects/def-mtarailo/common/indexes/WS265_wormbase/c_elegans.PRJNA13758.WS265.annotations.gff3
[coovar.pl]   GVS_TAB_FORMAT: calling/varscan/470_sorted_dedupped_snp_varscan.tsv
[coovar.pl]   GVS_VCF_FORMAT:
[coovar.pl]   OUTPUT DIRECTORY: /annotation/coovar/470
[coovar.pl]   CIRCOS FLAG: 1
[coovar.pl]   FEATURE SOURCE:
[coovar.pl]   FEATURE TYPE: CDS
[coovar.pl] Indexing FASTA file /home/moldach/projects/def-mtarailo/common/indexes/WS265_wormbase/c_elegans.PRJNA13758.WS265.genomic.fa.gz on Thu Apr 23 11:40:56 2020

------------- EXCEPTION: Bio::Root::Exception -------------
MSG: Could not open index file /home/moldach/projects/def-mtarailo/common/indexes/WS265_wormbase/c_elegans.PRJNA13758.WS265.genomic.fa.gz.index: Inappropriate ioctl for device
STACK: Error::throw
STACK: Bio::Root::Root::throw /home/moldach/perl5/lib/perl5/Bio/Root/Root.pm:449
STACK: Bio::DB::IndexedBase::_open_index /home/moldach/perl5/lib/perl5/Bio/DB/IndexedBase.pm:678
STACK: Bio::DB::IndexedBase::_index_files /home/moldach/perl5/lib/perl5/Bio/DB/IndexedBase.pm:655
STACK: Bio::DB::IndexedBase::index_file /home/moldach/perl5/lib/perl5/Bio/DB/IndexedBase.pm:488
STACK: Bio::DB::IndexedBase::new /home/moldach/perl5/lib/perl5/Bio/DB/IndexedBase.pm:365
STACK: /home/moldach/projects/def-mtarailo/common/tools/CooVar/coovar.pl:97
-----------------------------------------------------------

Any idea what's missing/broken?

moldach avatar Apr 23 '20 18:04 moldach

@moldach Try gunzipping the FASTA file and running it again. I suspect the compression is the issue.

cjfields avatar Aug 06 '20 01:08 cjfields

Hi @cjfields the response was a bit late so this has been taken care of - Coovar runs the same for me and my colleagues. However, in the interim we've discovered an error which is occurring preventing the annotation of insertions and deletions.

Can't load '/home/moldach/perl5/lib/perl5/x86_64-linux-thread-multi/auto/Set/IntervalTree/IntervalTree.so' for module Set::IntervalTree: libstdc++.so.6:
cannot open shared object file: No such file or directory at /cvmfs/soft.computecanada.ca/nix/var/nix/profiles/16.09/lib/perl5/5.22.2/XSLoader.pm line 70.
^@ at /home/moldach/perl5/lib/perl5/x86_64-linux-thread-multi/Set/IntervalTree.pm line 59.
Compilation failed in require at /home/moldach/projects/def-mtarailo/common/tools/CooVar/scripts/apply-insertions-deletions.pl line 8.
BEGIN failed--compilation aborted at /home/molach/projects/def-mtarailo/common/tools/CooVar/scripts/apply-insertions-deletions.pl line 8.
[coovar.pl] ERROR executing command: perl /home/moldach/projects/def-mtarailo/common/tools/CooVar/scripts/apply-insertions-deletions.pl \
TEST/transcripts/reference_cdna.exons TEST/intermediate-files/target_cdna_snps.exons TEST/intermediate-files/categorized_snp_coords.list TEST/insertions/kept_470_sorted_dedupped_snp_varscan_coovar.tsv.ins
TEST/deletions/kept_470_sorted_dedupped_snp_varscan_coovar.tsv.del TEST/categorized-gvs.gvf \
TEST/intermediate-files/transcripts_snps_applied.gff3.tmp TEST/intermediate-files/splice_junctions.tmp TEST
. at /home/moldach/projects/def-mtarailo/common/tools/CooVar/coovar.pl line 42.

Any idea what the problem is here?

moldach avatar Aug 12 '20 16:08 moldach

not a bioperl issue --> neither module is from BioPerl -- but I would reinstall Set::IntervalTree - looks like somethimng was compiled against different version of perl or libstdc++ ?

Jason Stajich @hyphaltip http://lab.stajich.org

On Wed, Aug 12, 2020 at 9:24 AM Matthew J. Oldach [email protected] wrote:

Hi @cjfields https://github.com/cjfields the response was a bit late so this has been taken care of - Coovar runs the same for me and my colleagues. However, in the interim we've discovered an error which is occurring preventing the annotation of insertions and deletions.

Can't load '/home/moldach/perl5/lib/perl5/x86_64-linux-thread-multi/auto/Set/IntervalTree/IntervalTree.so' for module Set::IntervalTree: libstdc++.so.6: cannot open shared object file: No such file or directory at /cvmfs/soft.computecanada.ca/nix/var/nix/profiles/16.09/lib/perl5/5.22.2/XSLoader.pm line 70. ^@ at /home/moldach/perl5/lib/perl5/x86_64-linux-thread-multi/Set/IntervalTree.pm line 59. Compilation failed in require at /home/moldach/projects/def-mtarailo/common/tools/CooVar/scripts/apply-insertions-deletions.pl line 8. BEGIN failed--compilation aborted at /home/molach/projects/def-mtarailo/common/tools/CooVar/scripts/apply-insertions-deletions.pl line 8. [coovar.pl] ERROR executing command: perl /home/moldach/projects/def-mtarailo/common/tools/CooVar/scripts/apply-insertions-deletions.pl
TEST/transcripts/reference_cdna.exons TEST/intermediate-files/target_cdna_snps.exons TEST/intermediate-files/categorized_snp_coords.list TEST/insertions/kept_470_sorted_dedupped_snp_varscan_coovar.tsv.ins TEST/deletions/kept_470_sorted_dedupped_snp_varscan_coovar.tsv.del TEST/categorized-gvs.gvf
TEST/intermediate-files/transcripts_snps_applied.gff3.tmp TEST/intermediate-files/splice_junctions.tmp TEST . at /home/moldach/projects/def-mtarailo/common/tools/CooVar/coovar.pl line 42.

Any idea what the problem is here?

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/bioperl/bioperl-live/issues/340#issuecomment-672977035, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAAL5OYQP3BA2F4H35LUUMDSAK64JANCNFSM4MPKSLBA .

hyphaltip avatar Aug 14 '20 20:08 hyphaltip

Yep I agree with @hyphaltip , maybe try that @moldach ? This can happen if there is a system or perl-specific upgrade (and can also be tricky if you mix this with any PERL5LIB settings).

cjfields avatar Aug 15 '20 18:08 cjfields

Thank you for the suggestion @hyphaltip And @cjfields what you say about mixing with PERL5LIB seems to have been the issue.

Before I had the following in the my .bashrc:

PATH="/home/moldach/perl5/bin${PATH:+:${PATH}}"; export PATH;
PERL5LIB="/home/moldach/perl5/lib/perl5${PERL5LIB:+:${PERL5LIB}}"; export PERL5LIB;
PERL_LOCAL_LIB_ROOT="/home/moldach/perl5${PERL_LOCAL_LIB_ROOT:+:${PERL_LOCAL_LIB_ROOT}}"; export PERL_LOCAL_LIB_ROOT;
PERL_MB_OPT="--install_base \"/home/moldach/perl5\""; export PERL_MB_OPT;
PERL_MM_OPT="INSTALL_BASE=/home/moldach/perl5"; export PERL_MM_OPT;

I needed to unset PERL5LIB and the OPT, install a local copy of perl and use that. I created a script activate_my_perl.sh:

unset PERL5LIB
unset PERL5OPT

ROOTDIR="$HOME/software/perl-5.32.0"

export PATH=$ROOTDIR/bin:$PATH
export MANPATH=$ROOTDIR/man:$MANPATH

Now I run the script and install Set::IntervalTree

[moldach@cedar1 biostars439754]$ source ~/bin/activate_my_perl.sh
[moldach@cedar1 biostars439754]$ cpan Set::IntervalTree

This time I don't get the error seen above for Set::IntervalTree!

I do see the following in the .err file and just wondering if this is a warning to be worried about or not - it repeats many times over:

Use of uninitialized value in concatenation (.) or string at /home/moldach/software/perl-5.32.0/lib/site_perl/5.32.0/Bio/SeqUtils.pm line 376.

moldach avatar Aug 19 '20 04:08 moldach