找回密码
 注册
查看: 896|回复: 4

POOL_PG_NUM_NOT_POWER_OF_TWO 1 pool(s) have non-power-of-two pg_num

[复制链接]

1

主题

0

回帖

12

积分

管理员

积分
12
QQ
发表于 2022-6-1 15:00:07 | 显示全部楼层 |阅读模式
POOL_PG_NUM_NOT_POWER_OF_TWO 1 pool(s) have non-power-of-two pg_num
* L0 z* X$ l1 z' O9 e    pool 'hdd-8T-volumes' pg_num 1998 is not a power of two1 k& P4 X6 X0 X+ B8 `5 l

1

主题

0

回帖

12

积分

管理员

积分
12
QQ
 楼主| 发表于 2022-6-1 15:00:08 | 显示全部楼层
*pgs为64,因为是2副本的配置,所以当有8个osd的时候,每个osd上均分了64/8 2=16个pgs,也就是出现了如上的错误 小于最小配置30个

1

主题

0

回帖

12

积分

管理员

积分
12
QQ
 楼主| 发表于 2022-6-1 15:12:38 | 显示全部楼层
ceph pg dump
, ^' c8 E& |4 ~% vversion 17651703 ]$ L. y$ k* u
stamp 2022-06-01 15:03:44.763524  O. O5 B5 v/ m5 |. F! f
last_osdmap_epoch 0$ ^1 n& x/ i( H6 V& M* z
last_pg_scan 0
5 i2 K0 ~- ^- l% l- b# x/ Z" JPG_STAT OBJECTS MISSING_ON_PRIMARY DEGRADED MISPLACED UNFOUND BYTES      OMAP_BYTES* OMAP_KEYS* LOG  DISK_LOG STATE                         STATE_STAMP                VERSION       REPORTED       UP      UP_PRIMARY ACTING  ACTING_PRIMARY LAST_SCRUB    SCRUB_STAMP                LAST_DEEP_SCRUB DEEP_SCRUB_STAMP           SNAPTRIMQ_LEN
6 v% a& s1 g/ A- q! Y' i4 h11.707      565                  0        0         0       0 2352037888         129          9 3553     3553                  active+clean 2022-06-01 13:50:56.036510  6975'1003301   6979:5303817 [19,30]         19 [19,30]             19   5646'988376 2022-05-31 19:39:44.514733     5641'924297 2022-05-29 01:07:42.814102             0
+ [+ `  m- [/ O11.706      540                  0        0         0       0 2247659538           0          0 3681     3681                  active+clean 2022-06-01 13:50:55.656551   6971'498069   6979:1349902 [23,30]         23 [23,30]             23   5646'490912 2022-06-01 05:10:22.249896     5646'490912 2022-06-01 05:10:22.249896             0
; l$ Z( w7 e3 K8 j) `' V11.705      543                  0        0         0       0 2253346825           0          0 3618     3618                  active+clean 2022-06-01 13:51:02.905785   6975'567441   6979:1089443 [28,19]         28 [28,19]             28   5646'541859 2022-05-31 15:49:53.861271     5646'541859 2022-05-31 15:49:53.861271             0
3 m# z4 w, x9 F7 p8 I11.704      529                  0        0         0       0 2206302208           0          0 3617     3617                  active+clean 2022-06-01 13:50:56.229366  6980'2482736   6980:2502435 [25,26]         25 [25,26]             25  5646'2417945 2022-05-31 20:26:39.154274    5641'2179835 2022-05-29 01:50:34.488740             0 % a7 q8 T+ B* |3 M. B4 j8 A
11.703      535                  0        0         0       0 2226425856           0          0 3275     3275                  active+clean 2022-06-01 13:50:56.495111   6975'640962    6979:837072 [22,15]         22 [22,15]             22   5645'572517 2022-05-31 09:34:20.003323     5641'543726 2022-05-29 22:30:35.200783             0
, s, W' C8 `) C  l7 I" k11.702      530                  0        0         0       0 2213830656           0          0 3042     3042                  active+clean 2022-06-01 13:50:55.244651  6980'2125742   6980:2148550 [26,17]         26 [26,17]             26  5646'2074880 2022-06-01 03:17:32.402047    5641'1799433 2022-05-29 15:56:28.693544             0
, `& f2 z( S, p$ u11.701      537                  0        0         0       0 2236018688           0          0 3034     3034                  active+clean 2022-06-01 13:50:55.649399   6975'433678    6979:493391 [15,30]         15 [15,30]             15   5899'430001 2022-06-01 13:43:33.184527     5631'287651 2022-05-26 10:58:58.467872             0
' S; O! r# q) X2 u4 O7 U" e: Y. ^- h11.700      557                  0        0         0       0 2323128320           0          0 3183     3183                  active+clean 2022-06-01 13:50:56.539878   6980'952801    6980:978009 [19,24]         19 [19,24]             19   5646'925119 2022-06-01 00:12:38.120802     5641'824465 2022-05-29 18:59:31.211162             0
: O4 y- \! o/ p7 Y11.6ff      529                  0        0         0       0 2208663552           0          0 3466     3466                  active+clean 2022-06-01 13:50:55.986988   6973'480985    6979:734557 [24,29]         24 [24,29]             24   5646'462045 2022-05-31 14:11:18.036212     5633'321079 2022-05-26 14:50:55.449167             0 ( j7 S* s  {. x! l8 h
11.6fe      547                  0        0         0       0 2277564416           0          0 3636     3636                  active+clean 2022-06-01 13:50:55.292607   6980'746853    6980:772710 [16,19]         16 [16,19]             16   5646'739069 2022-06-01 06:38:11.261440     5646'739069 2022-06-01 06:38:11.261440             0 3 E% O% X$ t2 e' }0 x6 e
11.6fd      538                  0        0         0       0 2241312768         103          9 4445     4445                  active+clean 2022-06-01 13:51:05.731263  6975'1055040   6980:4159540 [21,28]         21 [21,28]             21  5646'1030455 2022-05-31 13:25:03.642497     5641'981254 2022-05-28 23:32:07.447816             0 ( V! ]' A% Q$ F- `
11.6fc      551                  0        0         0       0 2298370048           0          0 3396     3396                  active+clean 2022-06-01 13:50:54.655918   6980'453209    6980:582916 [29,20]         29 [29,20]             29   5812'449700 2022-06-01 10:00:15.170529     5628'298940 2022-05-26 03:28:00.270068             0 9 `1 ~- [8 \# Z! l
11.6fb      565                  0        0         0       0 2348988416           0          0 3100     3100                  active+clean 2022-06-01 13:50:55.227034   6976'662735    6979:701211 [30,16]         30 [30,16]             30   5646'645776 2022-05-31 17:13:35.999562     5645'624502 2022-05-30 14:07:48.197255             0 ; a9 c. G7 b# |* y6 d- ]
11.6fa      551                  0        0         0       0 2289412096          38          4 3956     3956                  active+clean 2022-06-01 13:50:55.510160  6975'1018477   6980:2458087 [29,16]         29 [29,16]             29  5646'1011235 2022-06-01 07:39:30.769316    5646'1011235 2022-06-01 07:39:30.769316             0 3 q. _1 y8 H& v1 B) G0 p
11.6f9      536                  0        0         0       0 2223634944          38          4 3782     3782                  active+clean 2022-06-01 13:50:56.671297   6980'645514   6980:2230236 [22,18]         22 [22,18]             22   5645'616258 2022-05-31 09:20:04.984695     5623'516864 2022-05-24 23:55:49.505979             0 . ?, M5 e4 N+ W; N
11.6f8      533                  0        0         0       0 2225010697           0          0 3082     3082                  active+clean 2022-06-01 13:50:55.343119  6980'3079623   6980:3494654 [18,31]         18 [18,31]             18  5646'3061334 2022-06-01 08:34:50.685997    5641'2740582 2022-05-28 20:54:58.793261             0
4 z* H* ~: |5 ]$ G7 p6 l0 e11.6f7      562                  0        0         0       0 2348101632           0          0 3767     3767                  active+clean 2022-06-01 13:51:03.432581   6978'823391    6979:851557 [28,19]   
' e# p* h) t& f1 j5 L7 j6 B2 y. B  X5 O+ d4 J7 D* W8 r
sum 1237725 0 0 124332 0 5204815326611 53577 3191 9521026 9521026 - S6 h' ^0 X( B0 o# a, n
OSD_STAT USED    AVAIL   USED_RAW TOTAL   HB_PEERS                                                    PG_SUM PRIMARY_PG_SUM , K' I+ H% d' z
31       485 GiB 6.8 TiB  486 GiB 7.3 TiB   [0,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30]    245            117
1 r& B$ a8 A$ N5 u% c2 |30       463 GiB 6.8 TiB  464 GiB 7.3 TiB    [2,9,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,31]    249            111 6 W5 p7 Q' ^3 G) d  M1 F
29       477 GiB 6.8 TiB  478 GiB 7.3 TiB  [1,6,7,10,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,30]    242            125 , n' a6 T" P) j% B# Y
28       652 GiB 6.6 TiB  654 GiB 7.3 TiB    [7,8,14,15,16,17,18,19,20,21,22,23,24,25,26,27,29,30,31]    315            147 * I- R$ F" A3 I# W# C
27       550 GiB 6.7 TiB  551 GiB 7.3 TiB      [7,14,15,16,17,18,19,20,21,22,23,24,25,26,28,29,30,31]    278            148 5 k. M7 y- t9 r" k3 `: m  R
26       441 GiB 6.8 TiB  442 GiB 7.3 TiB     [10,14,15,16,17,18,19,20,21,22,23,24,25,27,28,29,30,31]    232            109
7 J% }& ^7 D/ e" ~25       473 GiB 6.8 TiB  475 GiB 7.3 TiB         [8,14,15,16,17,18,19,20,21,22,24,26,27,28,29,30,31]    246            134 . H  h4 q% \5 l5 C
24       515 GiB 6.8 TiB  517 GiB 7.3 TiB   [0,11,14,15,16,17,18,19,20,21,22,23,25,26,27,28,29,30,31]    263            138
5 V) a+ x% B$ T. G5 n5 d3 q% P: V; L23       528 GiB 6.8 TiB  529 GiB 7.3 TiB           [14,15,16,17,18,19,20,21,22,24,26,27,28,29,30,31]    268            115
/ ?4 O' L5 G- m! c; B$ r3 D! N22       461 GiB 6.8 TiB  462 GiB 7.3 TiB    [0,6,14,15,16,17,18,19,20,21,23,24,25,26,27,28,29,30,31]    229            101
4 r! n6 ]( m& b/ z9        148 GiB 410 GiB  149 GiB 559 GiB                                 [5,6,7,8,10,11,17,21,23,26]    337            155
0 T4 f: S) o7 i! y$ N8 o: @% {8         42 MiB 446 GiB  1.0 GiB 447 GiB                               [7,9,10,11,16,19,20,25,28,31]      0              0
! W5 N9 ^. {/ |. u* z/ I7         42 MiB 446 GiB  1.0 GiB 447 GiB                                 [3,6,8,9,10,18,22,24,27,30]      0              0
# O. n+ G( N/ f% P6         42 MiB 446 GiB  1.0 GiB 447 GiB                                 [0,4,5,7,14,17,21,23,26,29]      0              0
0 c# t1 H1 w2 n/ ]1 u5         42 MiB 893 GiB  1.0 GiB 894 GiB                                   [0,1,2,3,4,6,11,19,25,28]     46             28 9 I) g$ F8 T. H
4         42 MiB 893 GiB  1.0 GiB 894 GiB                                   [0,1,2,3,5,7,13,18,27,30]     44             20
( L8 m8 A0 U, F( ^7 m0         42 MiB 893 GiB  1.0 GiB 894 GiB                                  [1,2,3,4,5,12,17,21,26,31]     42             21 & q' Y0 ^5 E! u( w7 }/ K, d6 o* D
1         42 MiB 893 GiB  1.0 GiB 894 GiB                                   [0,2,3,4,5,9,11,13,24,30]     33             15
, C! C# _" f1 d4 x( B6 ]2         42 MiB 893 GiB  1.0 GiB 894 GiB                                   [0,1,3,4,5,8,19,25,28,31]     33             16
  a1 V, e+ g  E6 _5 e  G3 c3         42 MiB 893 GiB  1.0 GiB 894 GiB                                   [0,1,2,4,5,8,10,11,23,29]     58             28
# S$ {5 i& }0 o2 u% g7 s, u9 l10       154 GiB 404 GiB  155 GiB 559 GiB                                [4,8,9,11,15,18,22,24,27,30]    352            177   K1 S3 i% r5 \
11       147 GiB 411 GiB  148 GiB 559 GiB                                [3,7,9,10,12,19,20,25,28,31]    335            180 . r2 E: x& A- F9 A& w% o
12       104 GiB 2.1 TiB  105 GiB 2.2 TiB                                [0,2,8,11,13,17,21,23,26,29]    512            259 2 j1 Q5 Z( X. h, M6 ?
13       104 GiB 2.1 TiB  105 GiB 2.2 TiB                              [8,11,12,14,16,18,22,24,27,30]    512            253
+ O6 ]) Y: |' }4 A- W14       526 GiB 6.8 TiB  527 GiB 7.3 TiB [6,9,13,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31]    255            133   G& y, k. m1 L6 w/ j" M
15       477 GiB 6.8 TiB  478 GiB 7.3 TiB     [11,14,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31]    251            124
8 P+ f* r) M, V" J8 k7 K16       479 GiB 6.8 TiB  480 GiB 7.3 TiB      [6,14,15,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31]    259            149 . F2 V1 I+ i5 E$ a; L) I9 I
17       424 GiB 6.9 TiB  426 GiB 7.3 TiB       [7,9,14,15,16,18,20,21,22,23,24,25,26,27,28,29,30,31]    244            119
3 s' H9 L7 a! Z- {18       477 GiB 6.8 TiB  478 GiB 7.3 TiB      [4,14,15,16,17,19,20,21,22,23,24,25,26,27,28,29,30,31]    249            111
( {0 c: `; R5 y6 B: a8 U: {! U1 _19       519 GiB 6.8 TiB  521 GiB 7.3 TiB [3,6,13,14,15,16,17,18,20,21,22,23,24,25,26,27,28,29,30,31]    262            145
# O2 G' P  S9 s! c, C+ w20       563 GiB 6.7 TiB  564 GiB 7.3 TiB     [11,14,15,16,17,18,19,21,22,23,24,25,26,27,28,29,30,31]    276            147
& N0 P6 i3 x$ F5 F6 ?21       542 GiB 6.7 TiB  544 GiB 7.3 TiB   [3,11,14,15,16,17,18,19,20,22,23,24,25,26,27,28,29,30,31]    261            139 ) c" u% A  K! h! B' Q
sum      9.5 TiB 134 TiB  9.5 TiB 144 TiB                                                                                   
9 k: ?% r% `, |$ K" t* H& f8 [( r& ?& ]
* NOTE: Omap statistics are gathered during deep scrub and may be inaccurate soon afterwards depending on utilisation. See http://docs.ceph.com/docs/master ... up/#omap-statistics for further details.

1

主题

0

回帖

12

积分

管理员

积分
12
QQ
 楼主| 发表于 2022-6-1 15:36:28 | 显示全部楼层
If you have more than 50 OSDs, we recommend approximately 50-100 placement groups per OSD to balance out resource usage, data durability and distribution. If you have less than 50 OSDs, choosing among the preselection above is best. For a single pool of objects, you can use the following formula to get a baseline:
# a% r% @4 `& D' c# y" l; W9 V5 k
% N8 S+ |! B7 ^1 \6 e: J( t; G             (OSDs * 100)
4 g) u$ d/ T# MTotal PGs =  ------------
( f+ K$ V, K) B8 p              pool size5 {; D' O: g7 X5 C
Where pool size is either the number of replicas for replicated pools or the K+M sum for erasure coded pools (as returned by ceph osd erasure-code-profile get).

1

主题

0

回帖

12

积分

管理员

积分
12
QQ
 楼主| 发表于 2022-6-9 08:26:25 | 显示全部楼层
解决办法就是设置为1024的倍数。之类的。过了1024就需要设置成1024的倍数,比如 2以后4 ,4过后8 ,8变成16个pg,16 pg到32pg ,32pg到64pg ,64>128 , 128>256, 256>512,  512>1024,  1024>2048
您需要登录后才可以回帖 登录 | 注册

本版积分规则

返回首页|Archiver|手机版|小黑屋|易陆发现技术论坛 ( 蜀ICP备2026014127号-1 )

GMT+8, 2026-6-11 23:02 , Processed in 0.025951 second(s), 22 queries .

Powered by Discuz! X5.0

© 2001-2026 Discuz! Team.

快速回复 返回顶部 返回列表