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

cdc cli process hangs if the options were wrong #784

Closed
weekface opened this issue Jul 22, 2020 · 2 comments
Closed

cdc cli process hangs if the options were wrong #784

weekface opened this issue Jul 22, 2020 · 2 comments
Labels
area/ticdc Issues or PRs related to TiCDC. help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. type/bug The issue is confirmed as a bug.
Milestone

Comments

@weekface
Copy link

Bug Report

Please answer these questions before submitting your issue. Thanks!

  1. What did you do? If possible, provide a recipe for reproducing the error.

I use cdc cli changefeed list command with TLS enabled, but without --key options, then the command hangs, i can't use ctr+c to stop it.

/ # ps
PID   USER     TIME  COMMAND
    1 root      0:03 /cdc server --addr=0.0.0.0:8301 --advertise-addr=demo-ticdc-0.demo-ticdc-peer.default.svc:8301 --gc-ttl=86400 --log-file=/dev/stderr --log-level=info --ca=/var
   65 root      0:00 sh
   83 root      0:00 ps
/ #
/ #
/ #
/ # /cdc cli changefeed list --pd=https://demo-pd:2379 --ca=/var/lib/cluster-client-tls/ca.crt --cert=/var/lib/cluster-client-tls/tls.crt --log-level=debug
[2020/07/22 02:52:23.043 +00:00] [INFO] [util.go:86] ["init log"] [file=] [level=info]
^C[2020/07/22 02:52:31.018 +00:00] [INFO] [util.go:98] ["got signal to exit"] [signal=interrupt]
^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C
^Z[1]+  Stopped                    /cdc cli changefeed list --pd=https://demo-pd:2379 --ca=/var/lib/cluster-client-tls/ca.crt --cert=/var/lib/cluster-client-tls/tls.crt --log-level=debug
/ # ps
PID   USER     TIME  COMMAND
    1 root      0:03 /cdc server --addr=0.0.0.0:8301 --advertise-addr=demo-ticdc-0.demo-ticdc-peer.default.svc:8301 --gc-ttl=86400 --log-file=/dev/stderr --log-level=info --ca=/var
   65 root      0:00 sh
   84 root      0:00 /cdc cli changefeed list --pd=https://demo-pd:2379 --ca=/var/lib/cluster-client-tls/ca.crt --cert=/var/lib/cluster-client-tls/tls.crt --log-level=debug
   95 root      0:00 ps
  1. What did you expect to see?

  2. What did you see instead?

  3. Versions of the cluster

    • Upstream TiDB cluster version (execute SELECT tidb_version(); in a MySQL client):

      (paste TiDB cluster version here)
      
    • TiCDC version (execute cdc version):

      (paste TiCDC version here)
      
@weekface weekface added the type/bug The issue is confirmed as a bug. label Jul 22, 2020
@amyangfei amyangfei added the help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. label Jul 22, 2020
@amyangfei amyangfei added this to the v4.0.4 milestone Jul 22, 2020
@amyangfei
Copy link
Contributor

amyangfei commented Jul 23, 2020

https://github.com/pingcap/ticdc/blob/97364a39d60368d1d353e826a11d33fa3cfe8a1d/cmd/client.go#L140
This line is added in pingcap/ticdc#764, the bug should have been fixed.

I test in my local environment, the hang disappears after #764.

Would you please test again in your test environment to see whether the bug is fixed with the nightly version? @weekface

@weekface
Copy link
Author

Fixed by #764, thank you. @amyangfei

@AkiraXie AkiraXie added the area/ticdc Issues or PRs related to TiCDC. label Mar 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/ticdc Issues or PRs related to TiCDC. help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. type/bug The issue is confirmed as a bug.
Projects
None yet
Development

No branches or pull requests

3 participants