sh: 0: 无法打开

sh: 0: 无法打开

我正在尝试运行这个命令

sh bbmap/bbduk.sh in1=fastq/Brca1Reads_ALL.1.fastq out1=fastq/Brca1Reads_ALL.1.TRIMMED.fastq ref=bbmap/resources/adapters.fa 

在终端上,但我不断收到:

sh: 0: Can't open bbmap/bbduk.sh

我也无法直接用终端打开 bbduk.sh。我试过 chmod,从主文件夹授予权限,但似乎没有任何效果。

我尝试使用 bash,但它给出了no such file or directory。Rannamei -l bbmap/bbduk.sh并给出:

f: bbmap/bbduk.sh
drwxrwxr-x rizwan rizwan bbmap
-rwxrwxr-x rizwan rizwan bbduk.sh

cat 后面的几行是:

#!/bin/bash

usage(){
echo "
Written by Brian Bushnell
Last modified March 24, 2020

Description:  Compares reads to the kmers in a reference dataset, optionally 
allowing an edit distance. Splits the reads into two outputs - those that 
match the reference, and those that don't. Can also trim (remove) the matching 
parts of the reads rather than binning the reads.
Please read bbmap/docs/guides/BBDukGuide.txt for more information.

Usage:  bbduk.sh in=<input file> out=<output file> ref=<contaminant files>

Input may be stdin or a fasta or fastq file, compressed or uncompressed.
If you pipe via stdin/stdout, please include the file type; e.g. for gzipped 
fasta input, set in=stdin.fa.gz

Input parameters:
in=<file>           Main input. in=stdin.fq will pipe from stdin.
in2=<file>          Input for 2nd read of pairs in a different file.
ref=<file,file>     Comma-delimited list of reference files.
                    In addition to filenames, you may also use the keywords:
                    adapters, artifacts, phix, lambda, pjet, mtst, kapa
literal=<seq,seq>   Comma-delimited list of literal reference sequences.
touppercase=f       (tuc) Change all bases upper-case.
interleaved=auto    (int) t/f overrides interleaved autodetection.
qin=auto            Input quality offset: 33 (Sanger), 64, or auto.
reads=-1            If positive, quit after processing X reads or pairs.
copyundefined=f     (cu) Process non-AGCT IUPAC reference bases by making all
                    possible unambiguous copies.  Intended for short motifs
                    or adapter barcodes, as time/memory use is exponential.
samplerate=1        Set lower to only process a fraction of input reads.
samref=<file>       Optional reference fasta for processing sam files.

strace sh bbmap/bbduk.sh 的输出是:

execve("/usr/bin/sh", ["sh", "bbmap/bbduk.sh"], 0x7fff99305048 /* 61 vars */) = 0
brk(NULL)                               = 0x55ca4513d000
arch_prctl(0x3001 /* ARCH_??? */, 0x7fffebb69790) = -1 EINVAL (Invalid argument)
access("/etc/ld.so.preload", R_OK)      = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=72928, ...}) = 0
mmap(NULL, 72928, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f8ae922a000
close(3)                                = 0
openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libc.so.6", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\360q\2\0\0\0\0\0"..., 832) = 832
pread64(3, "\6\0\0\0\4\0\0\0@\0\0\0\0\0\0\0@\0\0\0\0\0\0\0@\0\0\0\0\0\0\0"..., 784, 64) = 784
pread64(3, "\4\0\0\0\20\0\0\0\5\0\0\0GNU\0\2\0\0\300\4\0\0\0\3\0\0\0\0\0\0\0", 32, 848) = 32
pread64(3, "\4\0\0\0\24\0\0\0\3\0\0\0GNU\0cBR\340\305\370\2609W\242\345)q\235A\1"..., 68, 880) = 68
fstat(3, {st_mode=S_IFREG|0755, st_size=2029224, ...}) = 0
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f8ae9228000
pread64(3, "\6\0\0\0\4\0\0\0@\0\0\0\0\0\0\0@\0\0\0\0\0\0\0@\0\0\0\0\0\0\0"..., 784, 64) = 784
pread64(3, "\4\0\0\0\20\0\0\0\5\0\0\0GNU\0\2\0\0\300\4\0\0\0\3\0\0\0\0\0\0\0", 32, 848) = 32
pread64(3, "\4\0\0\0\24\0\0\0\3\0\0\0GNU\0cBR\340\305\370\2609W\242\345)q\235A\1"..., 68, 880) = 68
mmap(NULL, 2036952, PROT_READ, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f8ae9036000
mprotect(0x7f8ae905b000, 1847296, PROT_NONE) = 0
mmap(0x7f8ae905b000, 1540096, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x25000) = 0x7f8ae905b000
mmap(0x7f8ae91d3000, 303104, PROT_READ, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x19d000) = 0x7f8ae91d3000
mmap(0x7f8ae921e000, 24576, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1e7000) = 0x7f8ae921e000
mmap(0x7f8ae9224000, 13528, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f8ae9224000
close(3)                                = 0
arch_prctl(ARCH_SET_FS, 0x7f8ae9229580) = 0
mprotect(0x7f8ae921e000, 12288, PROT_READ) = 0
mprotect(0x55ca4456a000, 8192, PROT_READ) = 0
mprotect(0x7f8ae9269000, 4096, PROT_READ) = 0
munmap(0x7f8ae922a000, 72928)           = 0
getuid()                                = 1000
getgid()                                = 1000
getpid()                                = 11570
rt_sigaction(SIGCHLD, {sa_handler=0x55ca4455fc30, sa_mask=~[RTMIN RT_1], sa_flags=SA_RESTORER, sa_restorer=0x7f8ae907c210}, NULL, 8) = 0
geteuid()                               = 1000
brk(NULL)                               = 0x55ca4513d000
brk(0x55ca4515e000)                     = 0x55ca4515e000
getppid()                               = 11567
stat("/home/rizwan/fastq", {st_mode=S_IFDIR|0775, st_size=4096, ...}) = 0
stat(".", {st_mode=S_IFDIR|0775, st_size=4096, ...}) = 0
openat(AT_FDCWD, "bbmap/bbduk.sh", O_RDONLY) = 3
fcntl(3, F_DUPFD, 10)                   = 10
close(3)                                = 0
fcntl(10, F_SETFD, FD_CLOEXEC)          = 0
geteuid()                               = 1000
getegid()                               = 1000
rt_sigaction(SIGINT, NULL, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=0}, 8) = 0
rt_sigaction(SIGINT, {sa_handler=0x55ca4455fc30, sa_mask=~[RTMIN RT_1], sa_flags=SA_RESTORER, sa_restorer=0x7f8ae907c210}, NULL, 8) = 0
rt_sigaction(SIGQUIT, NULL, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=0}, 8) = 0
rt_sigaction(SIGQUIT, {sa_handler=SIG_DFL, sa_mask=~[RTMIN RT_1], sa_flags=SA_RESTORER, sa_restorer=0x7f8ae907c210}, NULL, 8) = 0
rt_sigaction(SIGTERM, NULL, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=0}, 8) = 0
rt_sigaction(SIGTERM, {sa_handler=SIG_DFL, sa_mask=~[RTMIN RT_1], sa_flags=SA_RESTORER, sa_restorer=0x7f8ae907c210}, NULL, 8) = 0
read(10, "#!/bin/bash\n\nusage(){\necho \"\nWri"..., 8192) = 8192
read(10, "do kmer-based operations on read"..., 8192) = 8192
read(10, "                  at least this "..., 8192) = 3318
openat(AT_FDCWD, "/dev/null", O_WRONLY|O_CREAT|O_TRUNC, 0666) = 3
fcntl(1, F_DUPFD, 10)                   = 11
close(1)                                = 0
fcntl(11, F_SETFD, FD_CLOEXEC)          = 0
dup2(3, 1)                              = 1
close(3)                                = 0
stat("/usr/local/sbin/pushd", 0x7fffebb69420) = -1 ENOENT (No such file or directory)
stat("/usr/local/bin/pushd", 0x7fffebb69420) = -1 ENOENT (No such file or directory)
stat("/usr/sbin/pushd", 0x7fffebb69420) = -1 ENOENT (No such file or directory)
stat("/usr/bin/pushd", 0x7fffebb69420)  = -1 ENOENT (No such file or directory)
stat("/sbin/pushd", 0x7fffebb69420)     = -1 ENOENT (No such file or directory)
stat("/bin/pushd", 0x7fffebb69420)      = -1 ENOENT (No such file or directory)
stat("/usr/games/pushd", 0x7fffebb69420) = -1 ENOENT (No such file or directory)
stat("/usr/local/games/pushd", 0x7fffebb69420) = -1 ENOENT (No such file or directory)
stat("/snap/bin/pushd", 0x7fffebb69420) = -1 ENOENT (No such file or directory)
write(2, "bbmap/bbduk.sh: 321: ", 21bbmap/bbduk.sh: 321: )   = 21
write(2, "pushd: not found", 16pushd: not found)        = 16
write(2, "\n", 1
)                       = 1
dup2(11, 1)                             = 1
close(11)                               = 0
write(2, "bbmap/bbduk.sh: 322: ", 21bbmap/bbduk.sh: 322: )   = 21
write(2, "Bad substitution", 16Bad substitution)        = 16
write(2, "\n", 1
)                       = 1
exit_group(2)                           = ?
+++ exited with 2 +++

相关内容