I would like to ask a question regarding a segmentation fault that I was getting while trying to run my system with the attached input file (gCNT10,10_l2_2by2_methane.lammps) and input script (nve.lammps). LAMMPS runs fine until it reaches the minimization step (as shown in log.lammps, attached), but gives a segmentation fault before completing any steps whatsoever (the input script tells LAMMPS to dump after every step, but I don’t get any output after step 0) with the error shown in error.txt. After a quick Google search, I found that another person had a similar error and had been advised to increase their page and one values as the issue was with having too many neighbors for each atom. I do not believe this is the case in my system for two reasons: One, the current script has a one value of 10000 while the total number of atoms in my input file is only 7800. Unless an atom somehow has more neighbors than there are atoms in the system, the value for one is not the issue. Two, when the attached script did not work, I created a new script (not attached) in which everything was the same but page was increased to 950000 and one was increased to 95000 (two rather high values just to ensure that these values weren’t the cause of the error), and got the same results. Unfortunately, I am unsure how to proceed from this error. Thank you for taking the time to read this e-mail, and I would greatly appreciate any help on this issue.
error.txt (2.96 KB)
gCNT10,10_l2_2by2_methane.lammps (312 KB)
nve.lammps (856 Bytes)
log.lammps (362 Bytes)
your input works fine for me using the current lammps version.
The first line of thermo output in your log file is:
Step Atoms Temp Press PotEng KinEng TotEng
0 7800 300 nan -30104.97 302.42996
A Nan pressure means forces are bad, likely infinite. LAMMPS is not
going to do very well at minimizing with bad forces.
This is typically due to a bad input geometry. Fix that, and the minimization
will likely proceed.
I am also using the current LAMMPS (C++) version, so why would it work for you and not for me?
I noticed this myself, and checked the input geometry. Not a single atom is closer than 1.4 angstroms to any other atom. (I probably should have included this info in the initial e-mail, but I forgot to, sorry). As such, I’m not sure where the infinite force is coming from.
I am also using the current LAMMPS (C++) version, so why would it work for
july 1st 2011?
you and not for me?
there are a number of possible reasons.
- overly aggressive compiler optimization
- slightly different numerics due to different
number of nodes.
Yes, July 1st 2011 version. I got the same error using either 16 processors on 2 nodes or 24 processors on 3 nodes. Do you mind telling me what settings you used? Also, in the future, if I get an error like this, is there a systematic method to figuring out the number of nodes/processors that this will work with, or is it just a guess and check process? Unfortunately, I am not well-enough versed in computer programming to comment on any differences in compiler optimization. I have attached the Makefile I used to build LAMMPS on my local supercomputer cluster (I did not add any extra packages to be installed, I have only installed the 3 default packages). If you could tell me of any issues with this Makefile and/or point me to some resources that show some examples of what you mean by aggressive compiler optimization, that would be very helpful.
Makefile.lcc (831 Bytes)
a quick trial with you input reveals that you have
a _huge_ potential energy due to overlapping atoms.
the minimizer cannot alleviate this kind of massive
deviation from a reasonable physical setup.
you can see this easily when visualizing your system
in e.g. VMD with a VDW representation.
in part you should have noticed this from the warnings
about neighbor list overflows and lost atoms...
making warnings/errors disappear doesn't necessarily
make their cause disappear. they should only be ignored
if there is a good physical reason for it (which is not given
in your case).
As it turns out, you are correct, some atoms were a bit too close to each other. I had used the same script to generate this file as I had to generate other similar files that seemed to run perfectly, so I had initially assumed that the structure itself was not an issue. However, after looking closer at the log files for the other structures (which were still running at the time), I noticed that at step 40 of minimization, the pressure read nan, and it had stopped there. That is, the structure minimized fine until I got to step 40 when it got a pressure of nan, and then, instead of erroring out, continued in what I guess is an infinite loop without outputting any new data. At that point, the simulation had been running for 2 days. I am assuming that this is a bug in LAMMPS. Anyways, after fixing the issue with atoms being too close, all structures simulate correctly now. Thank you for all the help you have provided.