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

ksync not working at all on an EKS cluster; syncthing process stops running #487

Open
aberle opened this issue Jan 27, 2021 · 3 comments
Open

Comments

@aberle
Copy link

aberle commented Jan 27, 2021

Creating a simple spec to watch a directory with a single file starts to run, but then syncthing stops running.

mkdir ksync_test
touch ksync_test/a-file
ksync -n my-namespace create --selector=name=internal-model-service /home/aberle/111/ksync_test /var/www/111/ksync_test

After a while, kysnc watch will just start logging messages that look like:

DEBU[0019] RESTY 2021/01/27 11:29:44 ERROR Get "http://localhost:8384/rest/events?since=30": dial tcp 127.0.0.1:8384: connect: connection refused, Attempt 2 

and nothing works until I restart. I see a defunct syncthing process running when this happens:

$ ps aux | grep syncthing                                                                                                                                                                           
aberle    3692  0.0  0.0      0     0 pts/7    Z+   11:29   0:00 [syncthing] <defunct>

All the matching pods are found, but their STATUS is stuck at starting:

       NAME          LOCAL              REMOTE             STATUS                POD                CONTAINER  
-----------------+------------+-------------------------+----------+------------------------------+------------
  upward-dolphin   ksync_test   /var/www/111/ksync_test             
                                                          starting   internal-model-service-9mqf9              
                                                          starting   internal-model-service-29ts4              
                                                          starting   internal-model-service-8dfxj              
                                                          starting   internal-model-service-lr78h 

If I run ksync watch a few times after a crash it will sometimes work, but then stop working on subsequent restarts of ksync watch. When it "works" I still see syncthing restart several times.

This is running on EKS, K8S version 1.16:

$ kubectl version   
                                                                                                                                                                                
Client Version: version.Info{Major:"1", Minor:"16", GitVersion:"v1.16.13", GitCommit:"39a145ca3413079bcb9c80846488786fed5fe1cb", GitTreeState:"clean", BuildDate:"2020-07-15T16:18:19Z", GoVersion:"go1.13.9", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"16+", GitVersion:"v1.16.15-eks-ad4801", GitCommit:"ad4801fd44fe0f125c8d13f1b1d4827e8884476d", GitTreeState:"clean", BuildDate:"2020-10-20T23:27:12Z", GoVersion:"go1.13.15", Compiler:"gc", Platform:"linux/amd64"}

Here are the logs from ksync watch --log-level debug from one instance of this happening: ksync_watch.log

ksync is very well suited to my development process, so I'd really like to get this working, thanks.

@ntorba
Copy link

ntorba commented May 6, 2021

@aberle Did you ever find a fix for this? I'm seeing the same issue on my EKS cluster

@aberle
Copy link
Author

aberle commented May 19, 2021

@aberle Did you ever find a fix for this? I'm seeing the same issue on my EKS cluster

Sorry, no. I gave up on using ksync since this was not working for me.

@timfallmk
Copy link
Collaborator

The error messages you're seeing are from the local ksync container being unable to connect to the (also local) syncthing instance. Probably a local networking problem (if you running containers in a vm locally, the networking setup here can cause this).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants