From: Ky Wildermuth (
Date: Wed Jun 01 2016 - 21:52:38 CDT


I have a VMD tcl script that works perfectly fine when I run it directly
from the command line on Linux using the following syntax:

*set vmd = /lustre/home/jbklauda/vmd/vmd-1.9.2/exec/vmd*
*$vmd -dispdev text -e defect_tachyon_scav.tcl*

However, when I run the exact same command through a C shell (to pass it to
an HPC cluster) VMD starts up as expected but closes early. Basically, it
loads the molecule successfully and defines some variables (such as number
of frames in the dcd file) but vmd closes before making atom selections. It
closes at the same point every time.

The script is kind of lengthy so I don't want to post the whole thing here,
but this is the line of code where it seems to stop according to the output

*mol modselect 0 0 (resname DOPC or resname DOPS) and name $polar_carbon *

with the variable $polar_carbon defined earlier in the script. Note that
this exact tcl script works fine when I run from the command line directly
- that is what confuses me the most.

The output file from the shell submission ends with this:

*Info) VMD for LINUXAMD64, version 1.9.2 (December 29, 2014)*
*Info) Exiting normally.*

(with 152 being the number of frames in the dcd)
When I run the source script directly from the command line it continues
like this:

*vmd > atomselect0*

That is why I think it is the atom selection that is killing the script.
The *vmd > *is curious to me; what is the significance of this?

After doing a bit of troubleshooting and browsing here in the mailing list,
I've tried a few different syntax methods of calling vmd and the code, I
changed the code a bit, and added quit to the end of the tcl code, but to
no avail.

Does anyone have any experience running vmd source scripts through a Unix
shell? Is there a trick? Any insight on why I am having this problem?

Thank you in advance!

Kyle Wildermuth