User Tools

Site Tools


howto:gaussian

This is an old revision of the document!


Gaussian at CHPC

  • NOTE : You should always run your jobs on directory scratch5

There are two modules of Gaussian 09 at CHPC which can be used. Here is an example on how to access them:

embele@login01:~/scratch5 $ module avail                   ### list available modules
embele@login01:~/scratch5 $ module add gaussian/g09.D01    ### load g09 version D01 (previous) or
embele@login01:~/scratch5 $ module add gaussian/g09.anton  ### load g09 version anton (new, Recommended)

Example PBSPro job script for Single Node Jobs (multiple CPU's)

#! /bin/sh

# (1) These are standard type lines for PBS job specification. Modify them for your own requirements - choice of
# nodes; walltime; your directory on scratch for standard out and error files ; email of job starting,
# ending and errors

#PBS -N molucule.job
#PBS -l select=1:ncpus=12:jobtype=westmere,place=free:group=nodetype
#PBS -l walltime=2:31:00
#PBS -q workq     
#PBS -o /export/home/aslopis/scratch5/Gaussian_Support/C60_4/molecule.out
#PBS -e /export/home/aslopis/scratch5/Gaussian_Support/C60_4/molecule.err
#PBS -m abe
#PBS -M MY_EMAIL_ADDRESS.com
# End of comments (1)  Make changes above.

# (2) This is to clean up temporary files which are left behind if Gaussian crashes. No changes required below.   
cleanup_scratch() {
    echo "Deleting inside signal handler, meaning I either hit the walltime, or deleted the job using qdel"

    cd "$PBS_O_WORKDIR"
    rm -rfv "$GAUSS_SCRDIR"
   echo "---"
   echo "Signal handler ending time:"
   date
   exit 0
}

# Associate function "cleanup_scratch" with the TERM signal (and others), which is usually how jobs get killed.
trap 'cleanup_scratch' SIGTERM SIGHUP SIGINT SIGQUIT SIGFPE SIGKILL SIGALRM

# End of comments (2) No changes required above.


# (3) You can remove this 1st line below after you've run the script once, but is no problem if it remains.  
mkdir  /lustre/SCRATCH5/gau/$USER

# (4) Please leave this line unchanged. Creating a subdirectory with your jobid for Gaussian temporary files 
# which are removed after job.
# Previously everone's Gaussian temporary files were written in /SCRATCH5/gau
mkdir  /lustre/SCRATCH5/gau/$USER/$PBS_JOBID

# (5) Change to your work directory. Specify if explictly if you find issues.
cd $PBS_O_WORKDIR

echo "My job starts here"
date

# (6) Please leave unchanged. This new module specifies the new directory for Gaussian variable GAUSS_SCRDIR 
# for temporary files directory.
source /etc/profile.d/modules.sh
module add gaussian/g09.anton
source /opt/gridware/applications/gaussian/g09/bsd/g09.profile
# (6) Please leave unchanged

# (7) Edit your job input and log file names here.
g09 < molecule.com > molecule.log

# (8) Leave following unchanged.
# Normal exit of script: clean up temporary files - Gaussian should do this anyway, but to be safe.
# Remove the Gaussian scratch directory where temporary files are written. It is   
# /lustre/SCRATCH5/gau/$USER/$PBS_JOBID
# If abnormal termination (walltime or job killed) then function subroutine cleanup_scratch will clear 
# temporary files.

  rm -rfv "$GAUSS_SCRDIR"

  echo "Normal execution ending time:"
  date

Example PBSPro job script for g09.D01

#! /bin/sh
#PBS -N molecule.job
#PBS -l select=1:ncpus=12:jobtype=dell,place=free:group=nodetype
#PBS -l walltime=1:00:00
#PBS -q workq
#PBS -m abe
#PBS -o /export/home/username/scratch/gaussian.out
#PBS -e /export/home/username/scratch/gaussian.err
#PBS -M username@email

cd $PBS_O_WORKDIR
source /etc/profile.d/modules.sh
module add gaussian/g09.D01
source /opt/gridware/applications/gaussian/g09/bsd/g09.profile

g09 < molecule.com > molecule.log

Example of a gaussian input file, note the blank lines within the file:

%nprocshared=12
%nprocl=1
#P HF/6-31G*  IOP(6/33=2,6/41=10,6/42=17) SCF=Tight Pop=MK
       
Title Card Required

0 1
 C                 -3.19550100    0.11344600   -0.18511100
 O                 -3.05859100    0.83554400   -1.15941100
 N                 -2.14200500   -0.25446800    0.60848900
 H                 -2.32841200   -0.78506500    1.44398900
 C                 -0.75900100    0.12341400    0.36048900
 C                  0.14379200   -0.42259800    1.48678900
 C                  0.59047400   -1.84630300    1.03238900
 C                  1.59689900    0.10938400    1.28248900
 C                  0.08697100   -2.05959700   -0.42431100
 C                  2.05278100   -1.31402200    0.82788900
 C                 -0.14011000   -0.59319400   -0.87441100
 C                  1.35866600   -2.48501300   -1.17731100
 C                  1.32989700   -0.05621300   -1.07501100
 C                  1.66721100    0.99508300    0.02128900
 C                  2.20428100   -1.28752400   -0.71551100
 C                  0.60162500    2.08159700    0.02358900
 N                 -0.63668200    1.58111300    0.28218900
 O                  0.86964000    3.24909300   -0.21751100
 H                 -1.43757500    2.10622300   -0.04521100
 O                  2.93691800    1.56466600   -0.15981100
 H                  2.76333000    2.51016900   -0.30861100
 H                 -0.28050600   -0.28619200    2.48278900
 H                  0.43696300   -2.68340100    1.71298900
 H                  2.07960500    0.56667700    2.14378900
 H                 -0.78403700   -2.70728500   -0.52611100
 H                  2.86017500   -1.79913300    1.37408900
 H                 -0.75990800   -0.47138600   -1.76101100
 H                  1.22276500   -2.52601100   -2.26181100
 H                  1.75375300   -3.44771800   -0.83891100
 H                  1.50280200    0.34398500   -2.07391100
 H                  3.22968200   -1.22473700   -1.07621100
 C                 -4.55170800   -0.42883700    0.22928900
 H                 -5.23089700    0.41157200    0.38338900
 H                 -4.52881600   -1.04383700    1.13088900
 H                 -4.94951500   -1.02253200   -0.59631100
       
       
/app/dokuwiki/data/attic/howto/gaussian.1424783978.txt.gz · Last modified: 2021/12/09 16:42 (external edit)