Have a look at the discussion on 'login shell’s at BESClient Unix changes environment variables and see whether that helps. The script may depend on some environment variable that isn’t defined on non-login shells.
1 Like