Problem with new ver of lammps

Dear all,
I recently compiled the newest version of the LAMMPS software (28Oct12). It works fine with every system that I have tried so far except the attached data file and input file. It generates the following error message. However, these data and input files work fine with the older versions of LAMMPS. I wonder if you could elaborate on that.

Err Msgs:

LAMMPS (28 Oct 2012)
Scanning data file …
2 = max bonds/atom
6 = max angles/atom
6 = max dihedrals/atom
Reading data file …
orthogonal box = (-29.9385 -29.9365 -29.9345) to (29.9385 29.9365 29.9345)
1 by 1 by 1 MPI processor grid
5100 atoms
4500 bonds
6600 angles
[maginnfe:10432] *** Process received signal ***
[maginnfe:10432] Signal: Segmentation fault (11)
[maginnfe:10432] Signal code: Address not mapped (1)
[maginnfe:10432] Failing at address: (nil)
[maginnfe:10432] [ 0] /lib64/libpthread.so.0 [0x3b13c0ebe0]
[maginnfe:10432] [ 1] ./lmp_linux(_ZN9LAMMPS_NS4Atom14data_dihedralsEiPc+0xe1) [0x488801]
[maginnfe:10432] [ 2] ./lmp_linux(_ZN9LAMMPS_NS8ReadData7commandEiPPc+0x105a) [0x84e8ba]
[maginnfe:10432] [ 3] ./lmp_linux(_ZN9LAMMPS_NS5Input15execute_commandEv+0x11e8) [0x62e6a8]
[maginnfe:10432] [ 4] ./lmp_linux(_ZN9LAMMPS_NS5Input4fileEv+0x2e7) [0x62c217]
[maginnfe:10432] [ 5] ./lmp_linux(main+0x94) [0x644514]
[maginnfe:10432] [ 6] /lib64/libc.so.6(__libc_start_main+0xf4) [0x3b12c1d994]
[maginnfe:10432] [ 7] ./lmp_linux(_ZNSt8ios_base4InitD1Ev+0x41) [0x4735b9]
[maginnfe:10432] *** End of error message ***
Segmentation fault

I don’t know why every other example works fine except this one. Also, this one works fine with older lammps!!!

Best,

Amir

Hello all,

I was about to post the same message… Recently I compiled the new (28Oct) version of LAMMPS and figured out that I have similar problems:

The simulation was running fine with my input and data file for the older version (14Oct)…

However, now the crash (segmentation fault) occurs when I change

pair_style lj/cut/coul/long 12.5 to pair_style buck/coul/long 12.5

the LJ run is ok, the Buckingham run doesn’t start… and to be sure I created all the input and data file anew…

I’m sure that all my parameters are set correctly and that all parameters are defined, however I attach my input scripts and the error message below…

Is it possible that there was some sort of bug introduced during the version update? (I recompiled the executable without any errors several times, but that didn’t help)

Or do I just miss anything?

Best wishes,
Markus

in.CH3OH_LJ (3.5 KB)

in.CH3OH_E6 (3.32 KB)

error.CH3OH_E6 (11.2 KB)

There is no attached data file.

Steve

Hello Steve,

Right, I'm sorry for that...

The data file is the initial file in which some methanol molecules are randomly inserted into the box. To get rid of atomic overlaps I use fix nve/limit together with temp/rescale followed by standard NVT and NPT relaxation, all with the LJ potential... this works fine, but when I use the last frame of this trajectory and switch to the exp-6 potential I get the seg-fault

Btw., it doesn't matter if I use read_restart, read_data (after restart2data) or read_dump to load the last file again, all methods result in the same error.

Max

data.CH3OH (1.81 MB)

frame.200000.dmp (1.6 MB)

This week I just noticed that LAMMPS was crashing (segmentation fault)
when I use a large time-step. (In my case, I was unable to reproduce
the crash when recompiling lammps with debug flags -g -O0.) However I
was able to eliminate this problem when I use a very small time-step
(and/or fix problems with my force-field to eliminate the need for a
small timestep). (Steve, I'll send you a test case after this post.)

Max and Amir:
Can you both try a very small timestep and report back? (Max, I
realize you are already using a very small timestep. Can you reduce
it further? I just tried running your simulation with a small
timestep, and it seemed to help. See below.) Knowing whether it is
timestep related migh help us figure out why lammps is segfaulting.

Thanks

Andrew

P.S.
Max, I tried running "in.CH3OH_E6" file using "data.CH3OH" and
"frame.200000.dmp" on my laptop (using a single core of a i7 Q720
CPU), this way:

     lmp_ubuntu -i in.CH3OH_E6

Andrew,
I do not understand why I should perform these tests when just by adding one empty line to the data file the problem would be resolved. Now it might be interesting to Steve that if you decide to delete that extra empty line from your data file, the simulation still works fine. This was pretty funny to me. I think there is a bug somewhere in the new version. I wonder if you could clarify.

Best,

Amir

My apologies. I forgot that Steve has already fixed your issue.
It sounds like all of our segmentation faults are happening for
different reasons.

Hi Andrew,

Thanks for your suggestions!

Well, I tried to reduce the timestep to 0.01, but I got exactly the same result.
I'm wondering about the 'bad physics', because I thought the system should be ok after running with the Lennard-Jones potential and the switch to the exponential 6 should be no problem... However, to verify this I'm running longer trajectories now, but I really don't see much differences...

what do you mean with 'large energies' for t=0? Basically that's understandable since I just create molecules with bad geometry at random positions and excluding intermolecular interactions, however I remove any atomic overlaps and bad geometries with the described procedure... and I get this for frame.200000.dmp which is used as input for the exp-6 runs (and as I think indicates a stable system?):

   Step Temp Press Volume TotEng PotEng KinEng E_mol E_bond E_angle E_dihed E_pair E_vdwl E_coul E_long
  200000 293.20594 -357.4812 132453.99 9363.6049 -389.26298 9752.8679 7018.7293 3017.6081 3421.2745 579.84676 -7407.9923 -2984.9608 55508.768 -59931.8

So could it be that the loading command doesn't work and that the molecules from step 0 are taken? Because this would definitely explain the 'bad physics' problem...

Max

Hi Andrew,

Thanks for your suggestions!

Well, I tried to reduce the timestep to 0.01, but I got exactly the same
result.
I'm wondering about the 'bad physics', because I thought the system should
be ok after running with the Lennard-Jones potential and the switch to the
exponential 6 should be no problem... However, to verify this I'm running
longer trajectories now, but I really don't see much differences...

what do you mean with 'large energies' for t=0? Basically that's
understandable since I just create molecules with bad geometry at random
positions and excluding intermolecular interactions, however I remove any
atomic overlaps and bad geometries with the described procedure... and I
get this for frame.200000.dmp which is used as input for the exp-6 runs
(and as I think indicates a stable system?):

the more common way to restart such a system would
be to write a restart and then use restart2data and replace
the data file. or just read the restart file and change the
pair style and parameters.

btw: a simpler way to start a system from random positions
is to use a soft potential instead of LJ and use fix adapt to
"grow" the potential. over a part of the trajectory. this way
you have no discontinuities and no worries about dealing
with high potential energy.

axel.

Hello,

Yes, I tried to use just read_restart or read_data (after restart2data) since this is what I usually do… however I’m always ending up with this seg-fault…

But when I think about this, it may indicate that the system is yet not fully equilibrated.

The point is: this is just a small test system (to find optimal settings for the hybrid MPI/openMP production runs) so I didn’t take care of sophisticated strategies to get rid of overlaps… Maybe I should have, sorry…

As I said, at the moment I perform longer equilibration runs, I think tomorrow I can tell you more.

Max

Hi Andrew,

Thanks for your suggestions!

Well, I tried to reduce the timestep to 0.01, but I got exactly the same result.
I'm wondering about the 'bad physics', because I thought the system should be ok after running with the Lennard-Jones potential and the switch to the exponential 6 should be no problem... However, to verify this I'm running longer trajectories now, but I really don't see much differences...

what do you mean with 'large energies' for t=0? Basically that's understandable since I just create molecules with bad geometry at random positions and excluding intermolecular interactions, however I remove any atomic overlaps and bad geometries with the described procedure... and I get this for frame.200000.dmp which is used as input for the exp-6 runs (and as I think indicates a stable system?):

   Step Temp Press Volume TotEng PotEng KinEng E_mol E_bond E_angle E_dihed E_pair E_vdwl E_coul E_long
  200000 293.20594 -357.4812 132453.99 9363.6049 -389.26298 9752.8679 7018.7293 3017.6081 3421.2745 579.84676 -7407.9923 -2984.9608 55508.768 -59931.8

So could it be that the loading command doesn't work and that the molecules from step 0 are taken? Because this would definitely explain the 'bad physics' problem...

Yes. I think there is a physics problem. Probably because you
changed your force-field in a discontinuous way.

(To test this, I ran a simulation using the input script file that you
used to equilibrate the system "in.CH3OH_LJ". However I modified it
so that it also loads "frame.200000.dmp", after reading the original
data file, "data.CH3OH". When I do this, the energies at t=0 are not
large. They are almost identical to the numbers you posted.)

I definitely like Axel's suggestion to "grow" the potential, or at
least change the potential more gradually using multiple steps of
equilibration between.

However because your equilibration procedure is not very expensive (I
can run the 200000 steps of your simulation on my laptop in about 10
hours), instead, why don't you just re-equilibrate it using the
correct potential? (Instead of equilibrating it using one potential,
and changing the potential.)

Alternately, reduce your timestep even further to to something
extremely small like 1e-6, and see if LAMMPS still seg-faults. (Or
zero, if it will let you do that.)

I used topotools/VMD and it seemed like a number of atoms were pretty
close together.

I'm not sure if starting from a DATA file would help (but you can try it).

I don't like segfaults either.
Good luck.

Andrew

Hi Andrew,

Thanks for your suggestions!

Well, I tried to reduce the timestep to 0.01, but I got exactly the same result.
I'm wondering about the 'bad physics', because I thought the system should be ok after running with the Lennard-Jones potential and the switch to the exponential 6 should be no problem... However, to verify this I'm running longer trajectories now, but I really don't see much differences...

what do you mean with 'large energies' for t=0? Basically that's understandable since I just create molecules with bad geometry at random positions and excluding intermolecular interactions, however I remove any atomic overlaps and bad geometries with the described procedure... and I get this for frame.200000.dmp which is used as input for the exp-6 runs (and as I think indicates a stable system?):

   Step Temp Press Volume TotEng PotEng KinEng E_mol E_bond E_angle E_dihed E_pair E_vdwl E_coul E_long
  200000 293.20594 -357.4812 132453.99 9363.6049 -389.26298 9752.8679 7018.7293 3017.6081 3421.2745 579.84676 -7407.9923 -2984.9608 55508.768 -59931.8

So could it be that the loading command doesn't work and that the molecules from step 0 are taken? Because this would definitely explain the 'bad physics' problem...

Yes. I think there is a physics problem. Probably because you
changed your force-field in a discontinuous way.

! oops
Sorry I meant to say "no". I don't see any evidence that there is a
problem with the "read_dump" command. (Sorry for so many
typos/corrections.)