---
title: 运行和验证
description: "1. 使用PuTTY工具，以root用户登录服务器。"
url: https://www.hikunpeng.com/document/detail/zh/kunpenghpcs/hpcindapp/prtg-osc/kunpenglammps_02_0032.html
sourcePath: /source/zh/kunpenghpcs/hpcindapp/prtg-osc/kunpenglammps_02_0032.html
indexId: 12e2e72e7c0b3bab0f586a51e0af62e38a7d65421cb3ea320f837e6b0775861a68
---
# 运行和验证

#### 操作步骤

1. 使用PuTTY工具，以root用户登录服务器。
2. 执行以下命令创建工作目录。

```
mkdir -p
/
path/to/CASE
```


3. 执行以下命令进入工作目录并将算例和二进制文件拷贝到工作目录。

```
cd
/path/to/CASE
cp
/path/to/LAMMPS
/lammps-10Feb21/bench/in.lj ./
cp
/path/to/LAMMPS
/lammps-10Feb21/src/lmp_g++_openmpi ./
```


4. 执行以下命令开始测试。

```
mpirun --allow-run-as-root -np 8 --mca btl ^openib ./lmp_g++_openmpi -sf gpu -in in.lj
```


  回显显示如下内容，表示运行成功。

  需要查看“log.lammps”日志中的“Performance”数值，单位是“timesteps/s”，数值越高性能越优。

```
Performance: 231663.111 tau/day, 536.257 timesteps/s
99.9% CPU use with 8 MPI tasks x no OpenMP threads
MPI task timing breakdown:
Section |  min time  |  avg time  |  max time  |%varavg| %total
---------------------------------------------------------------
Pair    | 0.061975   | 0.18125    | 0.27592    |  15.7 | 47.70
Neigh   | 1.06e-06   | 2.1069e-06 | 3.64e-06   |   0.0 |  0.00
Comm    | 0.09717    | 0.19305    | 0.3114     |  15.1 | 50.81
Output  | 5.789e-05  | 0.0014428  | 0.0028119  |   2.2 |  0.38
Modify  | 0.0033437  | 0.0034793  | 0.0035951  |   0.1 |  0.92
Other   |            | 0.0007299  |            |       |  0.19
```
