计算化学公社

 找回密码 Forget password
 注册 Register
Views: 4918|回复 Reply: 5
打印 Print 上一主题 Last thread 下一主题 Next thread

[CP2K] 求助cp2k8.2通过测试却无法运行的奇怪情况

[复制链接 Copy URL]

17

帖子

0

威望

133

eV
积分
150

Level 3 能力者

跳转到指定楼层 Go to specific reply
楼主
各位老师,我最近在用toolchain方法安装cp2k8.2,gcc主要方法参考了刘老师的方案,即使用devtoolset-9的gcc9.3.1进行编译,采纳版本使用了sob老师在安装cp2k8.1时的方案,即version=“ssmp psmp".
编译到安装的过程除了最初警告没监测到MPI之外,一切顺利,直到测试的时候,两个版本出现了截然不同的结果
对于ssmp版本的测试,make -j 256 ARCH=local VERSION=ssmp test,测试结果是全过:
--------------------------------- Summary --------------------------------
Number of FAILED  tests 0
Number of WRONG   tests 0
Number of CORRECT tests 3392
Total number of   tests 3392
GREPME 0 0 3392 0 3392 X

Summary: correct: 3392 / 3392; 5min
Status: OK

然而psmp却是截然不同的状态:
--------------------------------- Summary --------------------------------
Number of FAILED  tests 2840
Number of WRONG   tests 0
Number of CORRECT tests 3
Total number of   tests 2843
GREPME 2840 0 3 0 2843 X

Summary: correct: 3 / 2843; failed: 2840; 10min
Status: FAILED
我琢磨着干脆就用ssmp版本,所以先export $OMP_NUM_THREADS=60,
再cp2k.ssmp CH3-BP-MO_DIAG.inp |tee out(某个cp2k的测试inp),然后出现了非常奇特的现象,top显示只有一个核在运转(在test时明明都在运转):
   PID USER      PR  NI    VIRT    RES    SHR S  %CPU %MEM     TIME+ COMMAND  

258704 yliu      20   0   33.9g  19.3g  24000 R  6092  7.7  13:12.05 cp2k.ssmp                              
  6083 yliu      20   0   19.9g 207412  58868 S  24.4  0.1 128:40.82 gnome-shell                           
  5106 root      20   0  630924 123052  46208 S   5.9  0.0  24:21.46 X                                      
76590 yliu      20   0 2872668 139412  84620 S   5.9  0.1  15:49.04 Web Content                           
15852 yliu      20   0 4024572 316820  84832 S   3.6  0.1 110:44.56 firefox                                
  6986 yliu      20   0  851100  30568  10328 S   1.3  0.0   4:27.31 gnome-terminal-                        
  3815 root      20   0   22120   1356    784 S   1.0  0.0  14:28.41 irqbalance                             
189856 yliu      20   0  164360   4664   1592 R   1.0  0.0  13:39.15 top                                    
16168 yliu      20   0 3682432 435620  52408 S   0.7  0.2 115:58.89 Web Content                           
252767 root      20   0       0      0      0 S   0.7  0.0   0:08.99 kworker/5:1                           
     1 root      20   0  194628   5160   3108 S   0.3  0.0   2:34.32 systemd                                
     9 root      20   0       0      0      0 S   0.3  0.0  15:50.26 rcu_sched                              
   615 root      rt   0       0      0      0 S   0.3  0.0   0:11.83 migration/121                          
  1362 root      20   0       0      0      0 S   0.3  0.0   3:37.06 kworker/32:1                           
  1508 root      20   0       0      0      0 S   0.3  0.0   2:21.50 kworker/180:1                          
  1556 root      20   0       0      0      0 S   0.3  0.0   0:22.84 kworker/228:1                          
  1574 root      20   0       0      0      0 S   0.3  0.0   1:11.55 kworker/246:1                          
  3841 dbus      20   0   71180   3716   1524 S   0.3  0.0   0:25.89 dbus-daemon                           
  6391 yliu      20   0  430304   4676   1856 S   0.3  0.0   2:06.05 ibus-daemon                           
  6571 yliu      20   0  438936   2292   1756 S   0.3  0.0   0:34.04 gsd-housekeepin                        
12954 root      20   0       0      0      0 S   0.3  0.0   0:00.94 kworker/121:2                          
27270 root      20   0       0      0      0 R   0.3  0.0   0:05.95 kworker/10:2                           
28872 root      20   0       0      0      0 S   0.3  0.0   0:00.54 kworker/210:2                          
29130 root      20   0       0      0      0 S   0.3  0.0   0:04.05 kworker/87:1                           
42559 root      20   0       0      0      0 S   0.3  0.0   0:02.56 kworker/147:2                          
47602 root      20   0       0      0      0 S   0.3  0.0   0:00.55 kworker/162:1                          
75322 root      20   0       0      0      0 S   0.3  0.0   0:02.61 kworker/181:2                          
79661 yliu      20   0 3037024 107840  48936 S   0.3  0.0  18:55.64 Web Content                           
84265 root      20   0       0      0      0 S   0.3  0.0   0:08.27 kworker/51:2                           
90291 root      20   0       0      0      0 S   0.3  0.0   0:04.09 kworker/152:2                          
98228 root      20   0       0      0      0 S   0.3  0.0   0:01.54 kworker/15:2                           
103145 root      20   0       0      0      0 S   0.3  0.0   0:00.37 kworker/97:0                           
115799 root      20   0       0      0      0 S   0.3  0.0   1:00.94 kworker/123:2                          
117407 root      20   0       0      0      0 S   0.3  0.0   0:01.42 kworker/98:1

如果算一个大一点的体系,用PBS系统,给定核数(这里为60),依然只有一个核跑,而且会出错:
   PID USER      PR  NI    VIRT    RES    SHR S  %CPU %MEM     TIME+ COMMAND                                
259821 yliu      20   0   21.5g   4.4g  18544 R  99.7  1.8   0:48.94 cp2k.ssmp                              
  6083 yliu      20   0   19.9g 210484  60152 S  29.4  0.1 130:18.48 gnome-shell                           
  6684 yliu      39  19  711800  16172   3492 R  25.7  0.0 197:25.88 tracker-extract                        
  5106 root      20   0  630924 135168  52420 S   5.9  0.1  24:37.97 X                                      
76590 yliu      20   0 2872668 139316  84780 S   5.3  0.1  16:12.04 Web Content                           
15852 yliu      20   0 4024572 329528  84836 S   4.6  0.1 111:05.85 firefox                                
  6986 yliu      20   0  851100  30628  10328 S   2.0  0.0   4:29.05 gnome-terminal-                        
189856 yliu      20   0  164360   4664   1592 R   1.3  0.0  13:42.41 top                                    
16168 yliu      20   0 3682432 436860  52408 S   0.7  0.2 116:01.78 Web Content                           
79661 yliu      20   0 3037024 107840  48936 S   0.7  0.0  18:56.96 Web Content                           
  3839 root      20   0   90604    912    912 S   0.3  0.0   0:38.38 rngd                                   
  6690 yliu      20   0  679684  52020   3544 S   0.3  0.0  31:29.14 tracker-store                          
117434 root      20   0       0      0      0 S   0.3  0.0   0:04.58 kworker/93:0                           
152967 yliu      20   0 2910608 162084  48040 S   0.3  0.1  13:33.31 Web Content                           
     1 root      20   0  194628   5160   3108 S   0.0  0.0   2:34.42 systemd                                
     2 root      20   0       0      0      0 S   0.0  0.0   0:09.54 kthreadd                              
     3 root      20   0       0      0      0 S   0.0  0.0   0:00.17 kworker/0:0                           
     4 root       0 -20       0      0      0 S   0.0  0.0   0:00.00 kworker/0:0H                           
     5 root      20   0       0      0      0 S   0.0  0.0   0:15.94 kworker/u512:0                        
     6 root      20   0       0      0      0 S   0.0  0.0   0:02.24 ksoftirqd/0              
出错部分记录(err.log)
#3  0x1d45f90 in collocate_one_grid_level._omp_fn.0
        at /home/yliu/bin/cp2k-8.2/src/grid/ref/grid_ref_task_list.c:385
#3  0x1d45f90 in collocate_one_grid_level._omp_fn.0
        at /home/yliu/bin/cp2k-8.2/src/grid/ref/grid_ref_task_list.c:385
#3  0x1d45f90 in collocate_one_grid_level._omp_fn.0
        at /home/yliu/bin/cp2k-8.2/src/grid/ref/grid_ref_task_list.c:385
#0  0x2aed838a1dfd in ???
#4  0x2aed84015404 in ???
#5  0x2aed7b964ea4 in ???
#6  0x2aed847759fc in ???
#7  0xffffffffffffffff in ???
#1  0x2aed838a1013 in ???
#2  0x2aed846ad3ff in ???
#1  0x2aed838a1013 in ???
#1  0x2aed838a1013 in ???
#2  0x2aed846ad3ff in ???
#2  0x2aed846ad3ff in ???
#1  0x2aed838a1013 in ???
#2  0x2aed846ad3ff in ???
#1  0x2aed838a1013 in ???
#2  0x2aed846ad3ff in ???
完整版err.log已上传。
请各位老师不吝赐教,谢谢大家!

out

10.51 KB, 下载次数 Times of downloads: 1

输出文件

cp2k82sub

662 Bytes, 下载次数 Times of downloads: 2

提交脚本

CH3-BP-MO_DIAG.inp

1.62 KB, 下载次数 Times of downloads: 1

err.log

13.29 KB, 下载次数 Times of downloads: 1

2425

帖子

1

威望

6196

eV
积分
8641

Level 6 (一方通行)

2#
发表于 Post on 2021-9-10 12:48:33 | 只看该作者 Only view this author
cp2k 8.x开始,
默认配置只有一个版本.
使用官方的模式编译策略, 没有psmp版本.

另,
258704 yliu      20   0   33.9g  19.3g  24000 R  6092  7.7  13:12.05 cp2k.ssmp  
这就是60核心运行呀.


至于PBS调度之后, 可能是参数写错了.
High-Performance Computing for You
为您专属定制的高性能计算解决方案

更多讯息,请访问:
https://labitc.top
http://tophpc.top:8080
电邮: ask@hpc4you.top

17

帖子

0

威望

133

eV
积分
150

Level 3 能力者

3#
 楼主 Author| 发表于 Post on 2021-9-10 21:57:18 | 只看该作者 Only view this author
abin 发表于 2021-9-10 12:48
cp2k 8.x开始,
默认配置只有一个版本.
使用官方的模式编译策略, 没有psmp版本.

非常感谢abin老师的回复!

虽然我很惊讶为什么cp2k8.x系列只有ssmp版本...不过至少不用纠结psmp完全FAIL的问题了

确实如abin老师所言,我又用比较小的体系测试了一下ssmp版本,发现还是可以运行的,也存在并行计算,只不过多数情况只有一个核在跑,太大的体系就直接以Program received signal SIGSEGV: Segmentation fault - invalid memory reference.报错了,不过在PBS脚本上靠提升内存可以部分解决。不知道这是不是ssmp的局限性...因为并行度比较差,感觉效率被7.1版本的cp2k.popt远远甩开了将近5-6倍

明天用您的方法试一下cp2k8.2psmp...这东西太难搞了

2425

帖子

1

威望

6196

eV
积分
8641

Level 6 (一方通行)

4#
发表于 Post on 2021-9-11 09:07:11 | 只看该作者 Only view this author
learnerNONE 发表于 2021-9-10 21:57
非常感谢abin老师的回复!

虽然我很惊讶为什么cp2k8.x系列只有ssmp版本...不过至少不用纠结psmp完全FA ...

源码搞不定的话,
可以试试这个方案, https://www.bilibili.com/video/BV1244y117pG/

直接使用官方源码, 默认无法得到psmp.
如果想要, 需要修改相关设定.

ssmp版本, 如果想顺利运行, 记得修改stack size之类.
搜索OMP stack size 差不多就能找到.

其他信息, 看我签名.
High-Performance Computing for You
为您专属定制的高性能计算解决方案

更多讯息,请访问:
https://labitc.top
http://tophpc.top:8080
电邮: ask@hpc4you.top

496

帖子

11

威望

4275

eV
积分
4991

Level 6 (一方通行)

5#
发表于 Post on 2021-9-11 16:19:00 | 只看该作者 Only view this author
abin 发表于 2021-9-10 12:48
cp2k 8.x开始,
默认配置只有一个版本.
使用官方的模式编译策略, 没有psmp版本.

请教一下老师有什么修改toolchain的方法使得编译出的cp2k.8.2含有popt版?
自由发挥,野蛮生长

2425

帖子

1

威望

6196

eV
积分
8641

Level 6 (一方通行)

6#
发表于 Post on 2021-9-11 17:57:10 | 只看该作者 Only view this author
丁越 发表于 2021-9-11 16:19
请教一下老师有什么修改toolchain的方法使得编译出的cp2k.8.2含有popt版?

8.x 无此版本。

如不信,去看看release note。
High-Performance Computing for You
为您专属定制的高性能计算解决方案

更多讯息,请访问:
https://labitc.top
http://tophpc.top:8080
电邮: ask@hpc4you.top

本版积分规则 Credits rule

手机版 Mobile version|北京科音自然科学研究中心 Beijing Kein Research Center for Natural Sciences|京公网安备 11010502035419号|计算化学公社 — 北京科音旗下高水平计算化学交流论坛 ( 京ICP备14038949号-1 )|网站地图

GMT+8, 2026-2-19 00:11 , Processed in 0.191663 second(s), 23 queries , Gzip On.

快速回复 返回顶部 返回列表 Return to list