易陆发现互联网技术论坛

 找回密码
 开始注册
查看: 2742|回复: 0
收起左侧

oslo_config.cfg.ConfigFileParseError: Failed to parse /etc/glance/glance-api.con

[复制链接]
发表于 2021-3-23 10:57:23 | 显示全部楼层 |阅读模式

马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。

您需要 登录 才可以下载或查看,没有账号?开始注册

x
同步数据库时报错:
) h' k( N& W$ J0 g: T) O/ y1 u# a0 {. l( Z/ d
oslo_config.cfg.ConfigFileParseError: Failed to parse /etc/glance/glance-api.conf: at /etc/glance/glance-api.conf:1, Unexpected continuation line: ' [DEFAULT]'
  ?& }& P- I  H  V2 h
  r: p& G; u5 s' xw完整的信息如下:
* c6 W; S/ s$ e: x# su -s /bin/sh -c "glance-manage db_sync" glance
6 U+ W+ U" s2 M# B  V' HTraceback (most recent call last):
( x7 `; W# q% `5 m$ @  File "/usr/lib/python3.6/site-packages/oslo_config/cfg.py", line 1608, in _parse_file
" T0 \# A( c; i- }, n- d    parser.parse()
) O% {+ S4 U0 Z  File "/usr/lib/python3.6/site-packages/oslo_config/cfg.py", line 1563, in parse. [& L: H* F  ~4 T6 W; A' s, c
    return super(ConfigParser, self).parse(f.readlines())6 u: Z/ |3 b9 t
  File "/usr/lib/python3.6/site-packages/oslo_config/iniparser.py", line 74, in parse# }( ]* w5 g4 j/ @
    self.error_unexpected_continuation(line), ~5 Q. e: l/ i9 I& v  P* t" }0 _
  File "/usr/lib/python3.6/site-packages/oslo_config/iniparser.py", line 120, in error_unexpected_continuation6 f* [$ m5 j- T2 H
    self.lineno, line)
1 q4 G# L+ e7 j+ s. ?0 Roslo_config.cfg.ParseError: at /etc/glance/glance-api.conf:1, Unexpected continuation line: ' [DEFAULT]'
7 g$ A# I" [+ r" F- Y. ~5 x- y% ~3 D! _: ?
During handling of the above exception, another exception occurred:
' j. g9 z% N0 s% s) b+ w+ b
9 X5 N3 H6 m7 t( t/ R$ vTraceback (most recent call last):5 u, O4 G* Y" p0 x6 j& M* K- V
  File "/usr/bin/glance-manage", line 10, in <module>6 R& _  V" |; j4 m3 f/ l
    sys.exit(main())
1 J1 x: ^, b8 h+ M' }6 S' J  File "/usr/lib/python3.6/site-packages/glance/cmd/manage.py", line 555, in main
  m$ y& b- H5 ], N8 _8 }    config.parse_args(default_config_files=cfg_files)9 i* z5 `8 U* w
  File "/usr/lib/python3.6/site-packages/glance/common/config.py", line 718, in parse_args
' U; R$ T& z+ l+ h' C1 P. S! v    default_config_files=default_config_files)9 U7 \, X  v0 t( u
  File "/usr/lib/python3.6/site-packages/oslo_config/cfg.py", line 2136, in __call__
8 ]1 l: ~+ V* s' @7 _    else sys.argv[1:])
0 Q. S$ K/ Q3 t3 B9 I8 v  File "/usr/lib/python3.6/site-packages/oslo_config/cfg.py", line 2901, in _parse_cli_opts& ?! l% D/ R: G' p( \
    return self._parse_config_files()+ V. ?% ^$ @2 y/ g
  File "/usr/lib/python3.6/site-packages/oslo_config/cfg.py", line 2918, in _parse_config_files1 B1 [1 V- }4 u' M# h' J2 h8 ?
    ConfigParser._parse_file(config_file, namespace)
! K! B) m3 S6 z$ A  File "/usr/lib/python3.6/site-packages/oslo_config/cfg.py", line 1610, in _parse_file( K: l6 [2 ?; C, e& E
    raise ConfigFileParseError(pe.filename, str(pe))
$ ]7 g  p% Q. g3 r9 r9 Z7 ^oslo_config.cfg.ConfigFileParseError: Failed to parse /etc/glance/glance-api.conf: at /etc/glance/glance-api.conf:1, Unexpected continuation line: ' [DEFAULT]'! w- X( f: O. R0 I

; b; l: \) @9 N: N9 H4 \' N- n; s
su -s /bin/sh -c "glance-manage db_sync" glance
8 |; _5 ~' H2 S* b* G8 o# x2 TTraceback (most recent call last):
2 o- Y( i6 t! `' [" z+ O  File "/usr/lib/python3.6/site-packages/oslo_config/cfg.py", line 1608, in _parse_file
+ X' u. w7 j) {, D  M% O    parser.parse()# W( q( `( x1 c% w
  File "/usr/lib/python3.6/site-packages/oslo_config/cfg.py", line 1563, in parse( l1 [! ^$ l3 @( t1 y& v
    return super(ConfigParser, self).parse(f.readlines())9 e4 J, {8 o. u& ?
  File "/usr/lib/python3.6/site-packages/oslo_config/iniparser.py", line 74, in parse
$ X+ E% o* f5 v    self.error_unexpected_continuation(line)
* _- c9 ]. y) W5 h6 f* x! c4 R: O  File "/usr/lib/python3.6/site-packages/oslo_config/iniparser.py", line 120, in error_unexpected_continuation- H. g# ~, t+ {# c3 G& t
    self.lineno, line)) K1 T7 F4 f! A7 ^( g9 \6 {  d0 i
oslo_config.cfg.ParseError: at /etc/glance/glance-api.conf:1, Unexpected continuation line: ' [DEFAULT]'
: V& C; x% E" P* O0 w7 z: i2 `5 w$ z4 u7 l1 t7 ?, X
During handling of the above exception, another exception occurred:$ t1 ~' R; @+ f1 n0 V
( ~3 k0 ]. A$ q" N" T2 p$ Q1 o# Y
Traceback (most recent call last):) c  o, f3 \6 T6 h
  File "/usr/bin/glance-manage", line 10, in <module>7 R6 u) g7 {# |4 u2 @# U
    sys.exit(main())
$ A; X3 g; e* l& d5 M  File "/usr/lib/python3.6/site-packages/glance/cmd/manage.py", line 555, in main
% r- J$ S$ x: f& ]( K  z    config.parse_args(default_config_files=cfg_files)
- I2 q! S5 r4 f/ C3 Y3 L1 U2 E' I. X# R  File "/usr/lib/python3.6/site-packages/glance/common/config.py", line 718, in parse_args$ e9 G  J2 B( z/ J" I
    default_config_files=default_config_files)
5 J8 U6 O# J. G  File "/usr/lib/python3.6/site-packages/oslo_config/cfg.py", line 2136, in __call__% f) I; }; ]) v" _4 t6 ^. l: Y3 J, ]
    else sys.argv[1:])9 ?) i# x) w! B/ i1 X
  File "/usr/lib/python3.6/site-packages/oslo_config/cfg.py", line 2901, in _parse_cli_opts- V' j& y5 M% D8 T
    return self._parse_config_files()
6 B0 v: O) i: Y  File "/usr/lib/python3.6/site-packages/oslo_config/cfg.py", line 2918, in _parse_config_files, Y" A# A# M) _, Q8 p+ w+ R
    ConfigParser._parse_file(config_file, namespace)+ b+ P; U/ G% b4 x
  File "/usr/lib/python3.6/site-packages/oslo_config/cfg.py", line 1610, in _parse_file8 r0 s) w/ B4 O5 d% ?
    raise ConfigFileParseError(pe.filename, str(pe)), a9 U* m; p1 ?5 o- ]6 j  ?
oslo_config.cfg.ConfigFileParseError: Failed to parse /etc/glance/glance-api.conf: at /etc/glance/glance-api.conf:1, Unexpected continuation line: ' [DEFAULT]'2 w7 w8 q4 P- c1 y. K- {$ \5 F
( ^( p1 S4 ^1 @( N7 m& B
检查glance-api.conf文件,和glance-register.conf文件; S& O8 F: `, [/ k

# C/ ?, W) i$ I7 t) o6 D* b% [' j[root@controller ~]# vim /etc/glance/glance-api.conf9 M  c) O* `" v+ @/ h. `

( s: v- [4 B$ v( Jvim /etc/glance/glance-registry.conf* l! n! P% |- b. [+ e2 Y% K2 w1 }
) I/ L, ~& z3 S! b2 k7 n6 a0 g+ w- E

# ]  Z/ @- b% o[root@controller ~]# su -s /bin/sh -c "glance-manage db_sync" glance: I" Y# Y$ z/ c7 _/ u
INFO  [alembic.runtime.migration] Context impl MySQLImpl.6 V5 g3 b% S9 r) {
INFO  [alembic.runtime.migration] Will assume non-transactional DDL.
  H0 h. L" J3 F3 x8 F/usr/lib/python3.6/site-packages/pymysql/cursors.py:170: Warning: (1280, "Name 'alembic_version_pkc' ignored for PRIMARY key."). h% E  ~  ]4 F8 @
  result = self._query(query)
7 D. z  |; G; h3 G! {INFO  [alembic.runtime.migration] Running upgrade  -> liberty, liberty initial
. s& D- n3 O4 BINFO  [alembic.runtime.migration] Running upgrade liberty -> mitaka01, add index on created_at and updated_at columns of 'images' table6 v, Z6 x) L+ ?
INFO  [alembic.runtime.migration] Running upgrade mitaka01 -> mitaka02, update metadef os_nova_server1 D. D7 _& U" w8 \/ U9 G3 R: g' ]: [
INFO  [alembic.runtime.migration] Running upgrade mitaka02 -> ocata_expand01, add visibility to images
7 I! O0 _# _: H% CINFO  [alembic.runtime.migration] Running upgrade ocata_expand01 -> pike_expand01, empty expand for symmetry with pike_contract01  L/ D/ d" `% [+ a- I4 _  z& V
INFO  [alembic.runtime.migration] Running upgrade pike_expand01 -> queens_expand01
& I1 V4 p+ M. B! u! t# l5 S% Y1 @3 [INFO  [alembic.runtime.migration] Running upgrade queens_expand01 -> rocky_expand01, add os_hidden column to images table: ?1 h: m6 Q; L" ^$ ^
INFO  [alembic.runtime.migration] Running upgrade rocky_expand01 -> rocky_expand02, add os_hash_algo and os_hash_value columns to images table' ?( B& Q7 X6 O) @1 @3 F+ f
INFO  [alembic.runtime.migration] Running upgrade rocky_expand02 -> train_expand01, empty expand for symmetry with train_contract01& D& [- U. _$ R4 D8 ^
INFO  [alembic.runtime.migration] Running upgrade train_expand01 -> ussuri_expand01, empty expand for symmetry with ussuri_expand01. i- T: t2 U% m: Q
INFO  [alembic.runtime.migration] Context impl MySQLImpl.. b+ ]9 L5 J. j" Y! X7 Y% y
INFO  [alembic.runtime.migration] Will assume non-transactional DDL.! v: d2 d. G' x8 B8 h
Upgraded database to: ussuri_expand01, current revision(s): ussuri_expand01
% z4 [6 R& t" m" }4 K3 uINFO  [alembic.runtime.migration] Context impl MySQLImpl.7 n# g1 T2 j/ y/ A' ]
INFO  [alembic.runtime.migration] Will assume non-transactional DDL.: F4 L; j; P2 e% o/ G) w/ H: Y5 X
INFO  [alembic.runtime.migration] Context impl MySQLImpl.+ D- x, w5 q7 `0 G( a) U( @' F
INFO  [alembic.runtime.migration] Will assume non-transactional DDL.. {9 ^  C4 O5 P
Database migration is up to date. No migration needed.* x& {. A  t7 m" I
INFO  [alembic.runtime.migration] Context impl MySQLImpl.! J  ]# P/ d+ ^* r1 x
INFO  [alembic.runtime.migration] Will assume non-transactional DDL.
" V/ o. n0 d, CINFO  [alembic.runtime.migration] Context impl MySQLImpl.
$ V9 s: a9 h  a- ZINFO  [alembic.runtime.migration] Will assume non-transactional DDL.
+ u/ w; X8 ^  x0 q- j7 ~INFO  [alembic.runtime.migration] Running upgrade mitaka02 -> ocata_contract01, remove is_public from images' y: {8 B) a: `9 v
INFO  [alembic.runtime.migration] Running upgrade ocata_contract01 -> pike_contract01, drop glare artifacts tables
, o7 H* n) x0 v9 K- D$ {2 i' LINFO  [alembic.runtime.migration] Running upgrade pike_contract01 -> queens_contract01# s: E: }" c1 C' Z( w" K( m4 N+ j
INFO  [alembic.runtime.migration] Running upgrade queens_contract01 -> rocky_contract01
$ j6 a# \2 }% n- XINFO  [alembic.runtime.migration] Running upgrade rocky_contract01 -> rocky_contract028 r5 b) f/ ^8 W4 k3 h; `# e, ?" q
INFO  [alembic.runtime.migration] Running upgrade rocky_contract02 -> train_contract01
$ K! u4 w, I/ v- T) sINFO  [alembic.runtime.migration] Running upgrade train_contract01 -> ussuri_contract01) a0 K' \6 D2 W, l( m
INFO  [alembic.runtime.migration] Context impl MySQLImpl.
2 W. a; n7 @+ a$ [3 x2 U+ g2 XINFO  [alembic.runtime.migration] Will assume non-transactional DDL., r4 f  ^' N9 E, p) z0 R& m0 \
Upgraded database to: ussuri_contract01, current revision(s): ussuri_contract01" }  i4 m; c+ V' l' j8 C, [2 h
INFO  [alembic.runtime.migration] Context impl MySQLImpl.
$ A2 Z6 ?, T! y" O0 pINFO  [alembic.runtime.migration] Will assume non-transactional DDL./ p- M3 R/ ^0 [& B8 n
Database is synced successfully.9 E: S* D+ r" p

) l7 x/ I8 h; k3 Q
3 G) T4 O5 ^* x& J, b- u. C8 a7 Q3 ?# x) _) Y! `+ [/ ?2 E( I
* I( s' f3 i# N6 ?3 t8 j
您需要登录后才可以回帖 登录 | 开始注册

本版积分规则

关闭

站长推荐上一条 /4 下一条

北京云银创陇科技有限公司以云计算运维,代码开发

QQ|返回首页|Archiver|小黑屋|易陆发现技术论坛 ( 蜀ICP备2026014127号-1 )点击这里给我发消息

GMT+8, 2026-4-8 21:22 , Processed in 0.050495 second(s), 22 queries .

Powered by Discuz! X3.4 Licensed

© 2012-2025 Discuz! Team.

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