Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

UNIX coding

Name: Anonymous 2009-12-09 11:36

For a series of computer simulations I have to run I need to submit files, via SSH to a UNIX cluster. I have very little knowledge of UNIX coding and have been using templates to write the necessary scripts.

fluent.dat


#!/bin/bash
#PBS -S /bin/bash
# run simple Fluent job in parallel on 1 node

# set default resource requirements for job (2 processors on 1 node for 4 hours)
# - these can be overridden on the qsub command line
#PBS -l nodes=1:ppn=2
#PBS -l walltime=04:00:00

#Change to directory from which job was submitted
cd $PBS_O_WORKDIR

# set number of processors to run on (using list of node names in file $PBS_NODEFILE)
nprocs=`wc -l $PBS_NODEFILE | awk '{ print $1 }'`

# load fluent module so that we find the fluent command
module load fluent

# Run default version of Fluent in 3d mode in parallel over $nprocs processors
# Fluent commands are in file cricket5.jou, output messages go to output_file
fluent 3d -t$nprocs -g -i cricket5.jou > output_file


and

Cricket5.jou



; Read case file
rc cricket.cas

; Initialize the solution
/solve/initialize/initialize-flow

; Calculate 100 iterations
it 100

; Write data file (compressed, iteration number included in file name)
wd cricket-%i.gz

; Calculate another 50 iterations
it 50

; Write another data file
wd cricket-%i.gz

; and another 100 iterations
it 100

; write data files before exiting for potential use in next job
wd cricket-%i.gz

; Exit FLUENT
exityes


When these codes are run I am given error messages such as 'invalid command' for the iterations, ot 'invalid integer' for the number 50.

Is there any glaring errors in the coding that anyone could point out for me? Help would be greatly appreciated.

Name: Anonymous 2009-12-09 12:06

>>4

The previous example code used the same #!/bin/bash and the output was successful. So I don't think that's needed.

Anyone else got any ideas?

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List