From: Jim (
Date: Sat Jun 21 2014 - 11:08:51 CDT

I want to start multiple VMD processes in background from within a bash
script, e.g.:

for f in $files; do

     vmd -dispdev text -e script.tcl -args $pdbf $trajf $atomids $f out-$f
> vmdout-$f 2>&1 &


but it does not work. I'm usually getting an error like this (not

Info) Multithreading available, 32 CPUs detected.
Info) Free system memory: 114631MB (88%)
Info) Creating CUDA device pool and initializing hardware...
CUDA error: invalid device symbol, line 62
Info) Detected 1 available CUDA accelerator:
Info) [0] Tesla K20m 13 SM_3.5 @ 0.71 GHz, 4.7GB RAM, OIO, ZCP
ERROR) Tcl startup error:
Info) Dynamically loaded 2 plugins in directory:
Info) /home/jim/mymodules/VMD/1.9.1/lib/vmd/plugins/LINUXAMD64/molfile
ERROR) Could not read the vmd initialization file -
ERROR) source
ERROR) can't find package http 2.4
ERROR) The VMDDIR environment variable is set by the startup
ERROR) script and should point to the top of the VMD hierarchy.
ERROR) VMD will continue with limited functionality.
Info) VMD for LINUXAMD64, version 1.9.1 (February 1, 2012)
Info) Exiting normally.

When I remove the "&", it works (in serial though).
If I run this loop with the "&" directly in the terminal, it also works.

I cannot figure out what is wrong.