Unconfigured Ad

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts
  • vishal.rossi
    Member
    • Apr 2013
    • 25

    New to BAsh. Encountered an error

    This is the script which I made

    #!/bin/bash -l
    ##PBS Directives
    #PBS -q default
    #PBS -l nodes=1pn=4
    #PBS -l mem=30GB
    #PBS -l walltime=60:00:00
    #PBS -A ccg-ngs
    #PBS -m abe
    #PBS -M .......
    #PBS -o /scratch/ccg-ngs/tmp/v_stdout/${PBS_JOBNAME}.o${PBS_JOBID}
    #PBS -e /scratch/ccg-ngs/tmp/v_stderr/${PBS_JOBNAME}.e${PBS_JOBID}

    #o=$1
    #i=$2
    /projects/ccg-ngs/hthiele0/sw/delly_v0.0.9/delly -o $o $i

    And I submit the job as
    qsub -v o=/scratch/ccg-ngs/tmp/vishal/results/delly/delly2jfidhild.txt,i=/scratch/ccg-ngs/tmp/vishal/results/mrsfast/lag/final.bam /scratch/ccg-ngs/tmp/vishal/results/delly/sample2/delly1.sh



    This doesn't give any output. Even the v_stderr file is empty.
    When I give the path in -o and input instead of $o and $i, the code works.
    What am I doing wrong?
  • dpryan
    Devon Ryan
    • Jul 2011
    • 3478

    #2
    Originally posted by vishal.rossi View Post
    This is the script which I made

    #!/bin/bash -l
    ...
    #o=$1
    #i=$2
    /projects/ccg-ngs/hthiele0/sw/delly_v0.0.9/delly -o $o $i

    And I submit the job as
    qsub -v o=/scratch/ccg-ngs/tmp/vishal/results/delly/delly2jfidhild.txt,i=/scratch/ccg-ngs/tmp/vishal/results/mrsfast/lag/final.bam /scratch/ccg-ngs/tmp/vishal/results/delly/sample2/delly1.sh

    When I give the path in -o and input instead of $o and $i, the code works.
    What am I doing wrong?
    Have you tried not commenting out the "o=$1" and "i=$2" lines? I would assume that those won't be processed by qsub (I use slurm, but assume that qsub is similar enough).

    Comment

    • vishal.rossi
      Member
      • Apr 2013
      • 25

      #3
      Originally posted by dpryan View Post
      Have you tried not commenting out the "o=$1" and "i=$2" lines? I would assume that those won't be processed by qsub (I use slurm, but assume that qsub is similar enough).

      I am sure that #o and #i works and are taken as variables and not comments . But I will try the thing which you suggested and post the result.
      Thank you

      Comment

      • rhinoceros
        Senior Member
        • Apr 2013
        • 372

        #4
        Originally posted by vishal.rossi View Post
        I am sure that #o and #i works and are taken as variables and not comments . But I will try the thing which you suggested and post the result.
        Thank you
        Are you sure? As far as I know, the syntax of passing info to qsub in scripts follows #$ ..

        What does 'qstat -j yourJobID' say?
        savetherhino.org

        Comment

        • vishal.rossi
          Member
          • Apr 2013
          • 25

          #5
          ok people, the problem is solved

          #!/bin/bash -l
          ##PBS Directives
          #PBS -q default
          #PBS -l nodes=1pn=4
          #PBS -l mem=30GB
          #PBS -l walltime=60:00:00
          #PBS -A ccg-ngs
          #PBS -m abe
          #PBS -M .......
          #PBS -o /scratch/ccg-ngs/tmp/v_stdout/${PBS_JOBNAME}.o${PBS_JOBID}
          #PBS -e /scratch/ccg-ngs/tmp/v_stderr/${PBS_JOBNAME}.e${PBS_JOBID}

          out=$output
          inp=$input
          /projects/ccg-ngs/hthiele0/sw/delly_v0.0.9/delly -o $out $inp

          while submitting the job:
          qsub -v output=/scratch/ccg-ngs/tmp/vishal/results/delly/delly2jfidhild.txt,input=/scratch/ccg-ngs/tmp/vishal/results/mrsfast/lag/final.bam /scratch/ccg-ngs/tmp/vishal/results/delly/sample2/delly1.sh

          Comment

          Latest Articles

          Collapse

          ad_right_rmr

          Collapse

          News

          Collapse

          Topics Statistics Last Post
          Started by SEQadmin2, 06-09-2026, 11:58 AM
          0 responses
          30 views
          0 reactions
          Last Post SEQadmin2  
          Started by SEQadmin2, 06-05-2026, 10:09 AM
          0 responses
          37 views
          0 reactions
          Last Post SEQadmin2  
          Started by SEQadmin2, 06-04-2026, 08:59 AM
          0 responses
          42 views
          0 reactions
          Last Post SEQadmin2  
          Started by SEQadmin2, 06-02-2026, 12:03 PM
          0 responses
          64 views
          0 reactions
          Last Post SEQadmin2  
          Working...