报错内容:LAMMPS (23 Jun 2022 - Update 4)
Reading restart file ...
restart file = 12 Dec 2018, LAMMPS = 23 Jun 2022
WARNING: Old restart file format revision. Switching to compatibility mode. (../read_restart.cpp:613)
WARNING: Restart file used different # of processors: 64 vs. 4 (../read_restart.cpp:658)
WARNING: Restart file used different newton pair setting, using input script value (../read_restart.cpp:685)
restoring atom style full from restart
orthogonal box = (19.934261 19.927718 19.876779) to (80.082311 80.075768 80.024829)
1 by 2 by 2 MPI processor grid
restoring pair style hybrid from restart
ERROR: Unrecognized pair style '' (../force.cpp:279)
Last command: read_restart restart.equil
解决方法:lammps的版本不兼容restart文件
报错2:ERROR on proc 0: Potential file does not match AIREBO/REBO style variant: # AIREBO : # Cite as S. J. Stuart, A. B. Tutein, J. A. Harrison,
(../pair_airebo.cpp:3386)
Last command: pair_coeff * * airebo CH.airebo NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL C
解决方法:用了新的lammps跑旧的代码,去githup下载一个新的就可以
报错三:mpirun -np 4 lmp_mpi -in **_**_ev.in1 >out.log CPU可以运行
但是
mpirun -np 4 lmp_mpi -sf gpu -pk gpu 1 -in litfsi_pdadma_ev.in1 >out.log
不可以运行
报错:Cuda driver error 4 in call at file 'geryon/nvd_timer.h' in line 99.
ERROR: Must not use GPU neighbor lists with hybrid pair style (../fix_gpu.cpp:283)
解决方法:提交命令加入neigh no
mpirun -np 4 lmp_mpi -sf gpu -pk gpu 1 neigh no -in litfsi_pdadma_ev.in1 >out.log
成功运行
运行成功后测试一下运行速度:跑10000步,16120 atoms
mpirun -np 1 lmp_mpi -sf gpu -pk gpu 1 neigh no -in litfsi_pdadma_ev.in1 >out.log
CPU:1核;GPU:1个(40%利用率)运行时间:0:05:48
nohup mpirun -np 2 lmp_mpi -sf gpu -pk gpu 1 neigh no -in litfsi_pdadma_ev.in1 >out1.log &
CPU:2核;GPU:1个(39%利用率)运行时间: 0:03:23
nohup mpirun -np 4 lmp_mpi -sf gpu -pk gpu 1 neigh no -in litfsi_pdadma_ev.in1 >out1.log &
CPU:4核;GPU:1个(37%利用率)运行时间: 0:02:09
nohup mpirun -np 6 lmp_mpi -sf gpu -pk gpu 1 neigh no -in litfsi_pdadma_ev.in1 >out1.log &
CPU:6核;GPU:1个(87%利用率)运行时间: 0:01:41
nohup mpirun -np 8 lmp_mpi -sf gpu -pk gpu 1 neigh no -in litfsi_pdadma_ev.in1 >out1.log &
CPU:8核;GPU:1个(80%利用率)运行时间: 0:01:47
nohup mpirun -np 12 lmp_mpi -sf gpu -pk gpu 1 neigh no -in litfsi_pdadma_ev.in1 >out1.log &
CPU:12核;GPU:1个(80%利用率)运行时间: 0:01:49
综上所测试结果:6个CPU结合1GPU的搭配使得lammps运行速度达到最大