kubesphere / ks-installer

Install KubeSphere on existing Kubernetes cluster
https://kubesphere.io
Apache License 2.0
532 stars 746 forks source link

openpitrix-iam-service-deployment无法启动,看起来像是没有初始化数据 #2

Open fish2018 opened 5 years ago

fish2018 commented 5 years ago

[root@test-k8s-master01 ~]# kubectl logs openpitrix-iam-service-deployment-768555b66d-mpps2 -n openpitrix-system 2019-08-12 09:59:24.91467 -INFO- Release OpVersion: [v0.3.5] (grpc_server.go:79) 2019-08-12 09:59:24.9147 -INFO- Git Commit Hash: [9333eae7354fc6634785df7a2fef35e74ed8dce5] (grpc_server.go:79) 2019-08-12 09:59:24.91471 -INFO- Build Time: [2018-11-22 06:37:13] (grpc_server.go:79) 2019-08-12 09:59:24.91471 -INFO- Service [iam-service] start listen at port [9115] (grpc_server.go:81) 2019-08-12 09:59:24.91657 -ERROR- Error 1049: Unknown database 'iam' (event.go:36) 2019-08-12 09:59:24.91661 -ERROR- dbr.select.load.query: map[sql:SELECT user_id, username, password, email, role, description, status, create_time, update_time, status_time FROM user WHERE (email = 'admin@op.com')] (event.go:37) panic: Error 1049: Unknown database 'iam'

goroutine 52 [running]: openpitrix.io/openpitrix/pkg/service/iam.initIAMAccount() /go/src/openpitrix.io/openpitrix/pkg/service/iam/init.go:78 +0xdc3 created by openpitrix.io/openpitrix/pkg/service/iam.Serve /go/src/openpitrix.io/openpitrix/pkg/service/iam/server.go:25 +0x5f

我是先执行kubectl apply -f kubesphere.yaml进行安装,然后发现一些pod无法正常启动,查看日志是因为需要存储,于是创建sc,然后再把这些pvc删除重新创建的

pixiake commented 5 years ago

installer job是否变成complete状态呢?可以重复执行job试下

xcm153 commented 5 years ago

遇到同样问题 没有解决

suyanlong commented 5 years ago

`[kaifa@315732 ~]$ kubectl logs -n openpitrix-system openpitrix-iam-service-deployment-75b57cb65c-rs99d 2019-10-14 02:18:31.82879 -INFO- Release OpVersion: [v0.3.5] (grpc_server.go:79) 2019-10-14 02:18:31.82885 -INFO- Git Commit Hash: [9333eae7354fc6634785df7a2fef35e74ed8dce5] (grpc_server.go:79) 2019-10-14 02:18:31.82888 -INFO- Build Time: [2018-11-22 06:37:13] (grpc_server.go:79) 2019-10-14 02:18:31.8289 -INFO- Service [iam-service] start listen at port [9115] (grpc_server.go:81) 2019-10-14 02:18:31.83475 -ERROR- Error 1049: Unknown database 'iam' (event.go:36) 2019-10-14 02:18:31.83483 -ERROR- dbr.exec.exec: map[sql:insert into user_client (client_id, user_id, client_secret, status, description)\nvalues ('rNRvmMr8HQC3ZsTtcRIRWq8bJ', 'system', '1yroj01H0kuDpNYoww6R1UrtO', 'active', '')\non duplicate key update user_id = 'system', client_secret = '1yroj01H0kuDpNYoww6R1UrtO', status = 'active';] (event.go:37) 2019-10-14 02:18:31.83486 -ERROR- Init default IAM client [rNRvmMr8HQC3ZsTtcRIRWq8bJ] [1yroj01H0kuDpNYoww6R1UrtO] failed (init.go:36) panic: Error 1049: Unknown database 'iam'

goroutine 60 [running]: openpitrix.io/openpitrix/pkg/service/iam.initIAMClient() /go/src/openpitrix.io/openpitrix/pkg/service/iam/init.go:37 +0x639 created by openpitrix.io/openpitrix/pkg/service/iam.Serve /go/src/openpitrix.io/openpitrix/pkg/service/iam/server.go:24 +0x47 [kaifa@315732 ~]$ [kaifa@315732 ~]$ `

同样的问题