Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bugfix: 关于容器顺序执行的bug #4

Open
googs1025 opened this issue May 9, 2023 · 0 comments
Open

bugfix: 关于容器顺序执行的bug #4

googs1025 opened this issue May 9, 2023 · 0 comments
Labels
bug Something isn't working

Comments

@googs1025
Copy link
Member

以上是容器内log:
当operator容器比mysql容器更早起来后,会先进入调协,此时mysql还没启动完毕,所以会connect: connection refused。

临时方案:部署前需要把原本的crd先删除乾净,避免过早进入调协。

E0509 16:38:40.335837       1 db_init.go:25] create databases error: dial tcp 127.0.0.1:3306: connect: connection refused
I0509 16:38:40.335969       1 init_k8s_config.go:16] run in the cluster
I0509 16:38:40.338067       1 controller.go:92] password: 123456
E0509 16:38:40.338158       1 user.go:17] create user error: dial tcp 127.0.0.1:3306: connect: connection refused
E0509 16:38:40.338234       1 user.go:24] set db privileges error: dial tcp 127.0.0.1:3306: connect: connection refused
I0509 16:38:40.338250       1 controller.go:61] test-db-tabledefault
I0509 16:38:40.338257       1 init_k8s_config.go:16] run in the cluster
CREATE USER IF NOT EXISTS testuser IDENTIFIED BY '123456
';
GRANT ALL PRIVILEGES ON test.* TO 'testuser'@'%';
I0509 16:38:40.339992       1 controller.go:67] [CREATE TABLE IF NOT EXISTS runoob_tbl(
runoob_id INT UNSIGNED AUTO_INCREMENT,
runoob_title VARCHAR(100) NOT NULL,
runoob_author VARCHAR(40) NOT NULL,
submission_date DATE,
PRIMARY KEY ( runoob_id )
)ENGINE=InnoDB DEFAULT CHARSET=utf8;
 CREATE TABLE IF NOT EXISTS runoob_tbl1(
runoob_id INT UNSIGNED AUTO_INCREMENT,
runoob_title VARCHAR(100) NOT NULL,
runoob_author VARCHAR(40) NOT NULL,
submission_date DATE,
PRIMARY KEY ( runoob_id )
)ENGINE=InnoDB DEFAULT CHARSET=utf8;
]
E0509 16:38:40.340072       1 db_init.go:25] create databases error: dial tcp 127.0.0.1:3306: connect: connection refused
I0509 16:38:40.340163       1 init_k8s_config.go:16] run in the cluster
I0509 16:38:40.344155       1 controller.go:92] password: 123456
E0509 16:38:40.344380       1 user.go:17] create user error: dial tcp 127.0.0.1:3306: connect: connection refused
E0509 16:38:40.344444       1 user.go:24] set db privileges error: dial tcp 127.0.0.1:3306: connect: connection refused
I0509 16:38:40.344455       1 controller.go:61] test-db-table-exampledefault
I0509 16:38:40.344461       1 init_k8s_config.go:16] run in the cluster
I0509 16:38:40.346311       1 controller.go:67] [CREATE TABLE IF NOT EXISTS test(

@googs1025 googs1025 added the bug Something isn't working label May 9, 2023
@googs1025 googs1025 self-assigned this May 9, 2023
@googs1025 googs1025 removed their assignment Nov 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant