CmdStan on Linux server - Chain finished unexpectedly with schools example (but not with bernoulli example)

Thanks. You may have missed what I wrote at the end of my reply (past the error message), but looking around the forum I found this post and decided to try the following:

make STAN_THREADS=TRUE STANCFLAGS=–O1 /PATH/TO/MODEL

This makes my model complete succesfully! Does this give you any idea as to what may be going on?