- 积分
- 16840
在线时间 小时
最后登录1970-1-1
|
马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。
您需要 登录 才可以下载或查看,没有账号?开始注册
x
TASK [prechecks : include_tasks] *****************************************************************************************************************************************
% v9 z0 f$ A* E3 o& uincluded: /usr/local/share/kolla-ansible/ansible/roles/prechecks/tasks/host_os_checks.yml for compute1, controller, localhost
2 x" Z9 f7 G& e c, O
! [' J+ H+ }- L' X- q& ?TASK [prechecks : Checking host OS distribution] *************************************************************************************************************************
) m, C7 G. ^* P6 _5 Sfatal: [compute1]: FAILED! => {
$ x2 H. e7 N: @% Z. }9 P/ z3 p "assertion": "ansible_facts.distribution in host_os_distributions",5 K" U" V b3 h4 a J; S+ o2 `
"changed": false," Q. y: {4 `- Y8 _: U* J
"evaluated_to": false,( }1 U m8 g9 j$ d' Q% ~; t
"msg": "Host OS distribution openEuler is not supported. Supported distributions are: CentOS, Debian, Rocky, Ubuntu"
/ |4 K4 c, r% |}
( j1 C0 f* k x" g1 Ofatal: [controller]: FAILED! => {
2 K# I. d! M" e$ q "assertion": "ansible_facts.distribution in host_os_distributions",
, x, S. g8 J$ p w: y: o' u5 [ "changed": false,3 ?3 s( L" K }/ p6 |8 g
"evaluated_to": false,
. Z0 V- R2 Q3 O1 ~ "msg": "Host OS distribution openEuler is not supported. Supported distributions are: CentOS, Debian, Rocky, Ubuntu"
) o0 g" ?2 e& E3 O# } q1 k( D}
8 a" X5 ] a! afatal: [localhost]: FAILED! => {" w! _5 v6 r; v
"assertion": "ansible_facts.distribution in host_os_distributions",2 q9 _ N6 M! d( ~
"changed": false,6 P/ c5 y, ^7 w
, F% F% W7 }+ D+ D* ] "evaluated_to": false,
8 P5 Y6 c* w" n$ K4 _- o% K "msg": "Host OS distribution openEuler is not supported. Supported distributions are: CentOS, Debian, Rocky, Ubuntu"% _$ o ]2 Q/ P
}
! w2 S2 a$ Z0 R5 P% B# v! `6 {$ e' r& M0 _' Y, F$ S
PLAY RECAP ***************************************************************************************************************************************************************6 j: X. q2 b0 Q D
compute1 : ok=6 changed=0 unreachable=0 failed=1 skipped=0 rescued=0 ignored=0 6 C% w! Z; \9 ]
controller : ok=6 changed=0 unreachable=0 failed=1 skipped=0 rescued=0 ignored=0 t& C/ A# u3 Y9 Q6 S3 m$ s- {; W
localhost : ok=6 changed=0 unreachable=0 failed=1 skipped=0 rescued=0 ignored=0
3 ~8 u" ]/ {$ @: T/ t5 n2 m; J' s1 P& r+ i) z! Y7 g% P
- R4 t2 e. [9 I, G0 s9 R3 M) ]# s
解决办法:
$ ~( _( |; Q+ B% i8 f }. z ^
# p* _# f* V$ P' e; H8 l vim /usr/local/share/kolla-ansible/ansible/roles/prechecks/tasks/host_os_checks.yml
% _# n7 E! L; T/ V注释掉os检查:
/ v9 q7 x) `1 E' m/ [; {4 S* ?( J7 k! J) ^" B
---
8 x2 k, O8 s8 u#- name: Checking host OS distribution
4 F) S8 _: Y- p/ |5 p6 ^# assert:
8 \3 b; g% A0 z+ ~# that: ansible_facts.distribution in host_os_distributions
3 t7 H6 m7 y1 P+ b; X& w# fail_msg: >-8 C" @1 t, R$ n% v# f' w0 X' H: p
# Host OS distribution {{ ansible_facts.distribution }} is not supported.) C) D/ r+ l' r- c
# Supported distributions are: {{ host_os_distributions.keys() | join(', ') }}
) k- [9 S2 j- `6 r: W#
3 F `2 f& ?% H; T E#- name: Checking host OS release or version$ U2 G( r) c6 T
# assert:
, K. M6 A" A4 B" C9 W5 ^/ {0 {# that:- ^6 ?! l9 ~8 r$ ~- t
# - ansible_facts.distribution_release in host_os_distributions[ansible_facts.distribution] or
! I5 D4 ]: |- `2 ?& I. k0 y# ansible_facts.distribution_version in host_os_distributions[ansible_facts.distribution] or0 t9 r/ B! \* ^1 T0 N
# ansible_facts.distribution_major_version in host_os_distributions[ansible_facts.distribution]8 ~5 P4 z, ]7 |5 q
# fail_msg: >-
5 x, L; ^5 _( _0 l( t4 d# {{ ansible_facts.distribution }} release {{ ansible_facts.distribution_release }}7 _9 o, h/ k" w6 u" B2 u
# version {{ ansible_facts.distribution_version }} is not supported.* y" K. ^( E& U8 t# D) G7 \
# Supported releases are:
3 g! Z8 F4 ]/ A4 z# b4 z" I4 K# {{ host_os_distributions[ansible_facts.distribution] | join(', ') }}' K8 U& A6 ^4 g) M
#
( D* ]) n1 U& I K, D8 R#- name: Checking if CentOS is Stream
9 N7 @" ]- B1 K3 t# become: true
$ Y/ K$ G8 C; ]& w5 \. b# command: grep -q Stream /etc/os-release
/ X8 s2 J) Z+ K( ?8 S# register: stream_status1 d2 p! `6 b7 I; t+ y7 l
# changed_when: false
9 t9 \( W Y. e S" k/ @& B# check_mode: false8 X; J: B' l' U n3 w
# when:
# \2 Z7 z3 q7 j- j, e0 S# - ansible_facts.distribution == 'CentOS'3 o+ \/ Y6 W" M; \, |
#% P+ _/ i, \ m) v$ [6 r
#- name: Fail if not running on CentOS Stream
8 D5 M' B0 y) j# fail:
+ w+ G% J' N7 J' e8 \7 f+ K' K6 ?# msg: CentOS Linux is not supported, you need to run CentOS Stream.7 U$ W# S3 J% x8 ?+ |9 ^
# when:
" F/ E" j& k* |3 K4 _) m' x# - ansible_facts.distribution == 'CentOS'
9 }- l( v; p/ g; Z1 W( Q* e# - stream_status.rc != 0
8 k. q- c8 N3 ^% m2 _! F9 G a% ?/ g* a
' w1 Z3 q" w) r8 m: a( |, o0 q$ X
/ z6 [, R! A. s: z! K+ L, l' G! h8 ^: u2 g6 y5 q1 o$ L1 J
再次执行即可:
/ Q" C" l# v0 J8 {* o2 d
( ], N& \5 q$ Z8 j3 E e- C" H fPLAY RECAP **************************************************************************************************************************************************************
4 `. M6 U) i# R+ t: J, Wcompute1 : ok=70 changed=0 unreachable=0 failed=0 skipped=48 rescued=0 ignored=0 # f& t( D6 @+ p# u6 Z$ Z. ~
controller : ok=102 changed=0 unreachable=0 failed=0 skipped=134 rescued=0 ignored=0
+ S% v" A' y% V9 D* [; M6 Clocalhost : ok=11 changed=0 unreachable=0 failed=0 skipped=12 rescued=0 ignored=0 X5 l- X7 r2 [; g. b
/ z6 M4 x* U3 B/ V, n
. j5 h1 ` m! F8 s6 d3 L1 T
6 R0 @, Q4 `; B1 K0 R
( J6 ]$ X7 r% F* t8 Q9 ]) g0 D9 S6 c3 a, k7 g X
6 ~! p6 U4 o4 L! m# ]
' H0 n7 n- W" [. q
|
|