zheng1 执行后:
kubectl describe pod openpitrix-isv-db-ctrl-job-kpjhd -n openpitrix-system
Name: openpitrix-isv-db-ctrl-job-kpjhd
Namespace: openpitrix-system
Priority: 0
Node: node3/192.168.23.42
Start Time: Fri, 06 Dec 2019 16:16:55 +0800
Labels: controller-uid=27bf1467-c054-4c63-9eec-e2be16a94536
job-name=openpitrix-isv-db-ctrl-job
Annotations: <none>
Status: Succeeded
IP: 10.233.67.5
Controlled By: Job/openpitrix-isv-db-ctrl-job
Init Containers:
wait-mysql:
Container ID: docker://9e218077b7c3fb87301385518a682455096b47c6781a3a8468d8327388018205
Image: busybox:1.28.4
Image ID: docker-pullable://busybox@sha256:141c253bc4c3fd0a201d32dc1f493bcf3fff003b6df416dea4f41046e0f37d47
Port: <none>
Host Port: <none>
Command:
sh
-c
until nc -z mysql.kubesphere-system.svc 3306; do echo "waiting for mysql"; sleep 2; done;
State: Terminated
Reason: Completed
Exit Code: 0
Started: Fri, 06 Dec 2019 16:17:25 +0800
Finished: Fri, 06 Dec 2019 16:17:25 +0800
Ready: True
Restart Count: 0
Environment: <none>
Mounts:
/var/run/secrets/kubernetes.io/serviceaccount from default-token-tc9gc (ro)
Containers:
openpitrix-isv-db-ctrl:
Container ID: docker://e5f1bb241d1de0db1412d7a705e9204187b95c898f782a9846d5ee1780008de4
Image: openpitrix/openpitrix:flyway-v0.4.5
Image ID: docker-pullable://openpitrix/openpitrix@sha256:d1617b7c2794711eed84fcebc4304ccf0990921f39ee40fb7dc04f2c2749c495
Port: <none>
Host Port: <none>
Command:
/flyway/flyway
-X
-url=jdbc:mysql://mysql.kubesphere-system.svc/isv
-user=root
-validateOnMigrate=false
-locations=filesystem:/flyway/sql/isv
migrate
State: Terminated
Reason: Completed
Exit Code: 0
Started: Fri, 06 Dec 2019 16:25:06 +0800
Finished: Fri, 06 Dec 2019 16:25:08 +0800
Ready: False
Restart Count: 0
Environment:
FLYWAY_PASSWORD: <set to the key 'password.txt' in secret 'mysql-pass'> Optional: false
Mounts:
/var/run/secrets/kubernetes.io/serviceaccount from default-token-tc9gc (ro)
Conditions:
Type Status
Initialized True
Ready False
ContainersReady False
PodScheduled True
Volumes:
default-token-tc9gc:
Type: Secret (a volume populated by a Secret)
SecretName: default-token-tc9gc
Optional: false
QoS Class: BestEffort
Node-Selectors: <none>
Tolerations: node.kubernetes.io/not-ready:NoExecute for 300s
node.kubernetes.io/unreachable:NoExecute for 300s
Events:
Type Reason Age From Message
---- ------ ---- ---- -------
Normal Scheduled 20m default-scheduler Successfully assigned openpitrix-system/openpitrix-isv-db-ctrl-job-kpjhd to node3
Normal Pulling 20m kubelet, node3 Pulling image "busybox:1.28.4"
Normal Pulled 20m kubelet, node3 Successfully pulled image "busybox:1.28.4"
Normal Created 20m kubelet, node3 Created container wait-mysql
Normal Started 20m kubelet, node3 Started container wait-mysql
Warning Failed 19m kubelet, node3 Failed to pull image "openpitrix/openpitrix:flyway-v0.4.5": rpc error: code = Unknown desc = Error response from daemon: Get https://registry-1.docker.io/v2/openpitrix/openpitrix/manifests/flyway-v0.4.5: net/http: TLS handshake timeout
Warning Failed 19m kubelet, node3 Error: ImagePullBackOff
Warning Failed 19m kubelet, node3 Error: ErrImagePull
Normal BackOff 19m kubelet, node3 Back-off pulling image "openpitrix/openpitrix:flyway-v0.4.5"
Normal Pulling 19m (x2 over 20m) kubelet, node3 Pulling image "openpitrix/openpitrix:flyway-v0.4.5"
Normal Pulled 12m kubelet, node3 Successfully pulled image "openpitrix/openpitrix:flyway-v0.4.5"
Normal Created 12m kubelet, node3 Created container openpitrix-isv-db-ctrl
Normal Started 12m kubelet, node3 Started container openpitrix-isv-db-ctrl
kubectl log openpitrix-isv-db-ctrl-job-kpjhd -n openpitrix-system
log is DEPRECATED and will be removed in a future version. Use logs instead.
DEBUG: Loading config file: /flyway/conf/flyway.conf
DEBUG: Unable to load config file: /root/flyway.conf
DEBUG: Unable to load config file: /flyway/flyway.conf
DEBUG: Using configuration:
DEBUG: flyway.jarDirs -> /flyway/jars
DEBUG: flyway.locations -> filesystem:/flyway/sql/isv
DEBUG: flyway.password -> ********
DEBUG: flyway.url -> jdbc:mysql://mysql.kubesphere-system.svc/isv
DEBUG: flyway.user -> root
DEBUG: flyway.validateOnMigrate -> false
DEBUG: Adding location to classpath: /flyway/drivers/derby-10.15.1.3.jar
DEBUG: Adding location to classpath: /flyway/drivers/derbyclient-10.15.1.3.jar
DEBUG: Adding location to classpath: /flyway/drivers/derbyshared-10.15.1.3.jar
DEBUG: Adding location to classpath: /flyway/drivers/derbytools-10.15.1.3.jar
DEBUG: Adding location to classpath: /flyway/drivers/h2-1.4.199.jar
DEBUG: Adding location to classpath: /flyway/drivers/hsqldb-2.5.0.jar
DEBUG: Adding location to classpath: /flyway/drivers/jaybird-jdk18-3.0.6.jar
DEBUG: Adding location to classpath: /flyway/drivers/jna-4.5.2.jar
DEBUG: Adding location to classpath: /flyway/drivers/jna-platform-4.5.2.jar
DEBUG: Adding location to classpath: /flyway/drivers/jtds-1.3.1.jar
DEBUG: Adding location to classpath: /flyway/drivers/mariadb-java-client-2.4.0.jar
DEBUG: Adding location to classpath: /flyway/drivers/mssql-jdbc-7.2.0.jre8.jar
DEBUG: Adding location to classpath: /flyway/drivers/mysql-connector-java-8.0.17.jar
DEBUG: Adding location to classpath: /flyway/drivers/postgresql-42.2.8.jre6.jar
DEBUG: Adding location to classpath: /flyway/drivers/sqlite-jdbc-3.23.1.jar
Flyway Community Edition 6.0.6 by Redgate
DEBUG: Scanning for filesystem resources at '/flyway/sql/isv'
DEBUG: Scanning for resources in path: /flyway/sql/isv (/flyway/sql/isv)
DEBUG: Found filesystem resource: /flyway/sql/isv/V0_1__init.sql
Database: jdbc:mysql://mysql.kubesphere-system.svc/isv (MySQL 8.0)
DEBUG: Driver : MySQL Connector/J mysql-connector-java-8.0.17 (Revision: 16a712ddb3f826a1933ab42b0039f7fb9eebc6ec)
DEBUG: DDL Transactions Supported: false
DEBUG: Schema: isv
DEBUG: Scanning for SQL callbacks ...
DEBUG: Filtering out resource: /flyway/sql/isv/V0_1__init.sql (filename: V0_1__init.sql)
Current version of schema `isv`: 0.1
Schema `isv` is up to date. No migration necessary.
DEBUG: Memory usage: 29 of 119M