You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by GitBox <gi...@apache.org> on 2022/09/26 06:53:06 UTC

[GitHub] [apisix-ingress-controller] dc-weizhenhua opened a new issue, #1368: Cant sync apisixroute and apisixupstream to apisix-dashboard

dc-weizhenhua opened a new issue, #1368:
URL: https://github.com/apache/apisix-ingress-controller/issues/1368

   ### Issue description
   
   I'm testing canary release using apisix ingress;So I create apisixroute and apisixupstream yaml-file as follow,but I could not seen route and upstream in apisix-dashboard, and Can't visit backends service。
   
   ```
   [root@k8smaster01 apisix-istio]# kubectl get svc -n istio-demo
   NAME          TYPE        CLUSTER-IP      EXTERNAL-IP   PORT(S)    AGE
   details       ClusterIP   10.98.109.195   <none>        9080/TCP   47h
   helloworld    ClusterIP   10.106.16.33    <none>        5000/TCP   35h
   nginx         ClusterIP   10.96.32.123    <none>        80/TCP     17h
   productpage   ClusterIP   10.107.119.46   <none>        9080/TCP   47h
   ratings       ClusterIP   10.105.243.27   <none>        9080/TCP   47h
   reviews       ClusterIP   10.109.105.63   <none>        9080/TCP   47h
   [root@k8smaster01 apisix-istio]# curl 10.96.32.123
   nginx02
   [root@k8smaster01 apisix-istio]# curl 10.96.32.123
   nginx01
   
   [root@k8smaster01 apisix-istio]# kubectl get all -n apisix-istio 
   NAME                                                  READY   STATUS    RESTARTS      AGE
   pod/apisix-istio-5dd564878b-zjbv8                     2/2     Running   4 (25h ago)   25h
   pod/apisix-istio-etcd-0                               2/2     Running   6 (25h ago)   25h
   pod/apisix-istio-etcd-1                               2/2     Running   5 (25h ago)   25h
   pod/apisix-istio-etcd-2                               2/2     Running   5 (25h ago)   25h
   pod/apisix-istio-ingress-controller-f74f5f74d-9nthf   2/2     Running   0             25h
   
   NAME                                      TYPE        CLUSTER-IP       EXTERNAL-IP   PORT(S)                         AGE
   service/apisix-istio-admin                ClusterIP   10.102.136.214   <none>        9180/TCP                        25h
   service/apisix-istio-etcd                 NodePort    10.105.76.51     <none>        2379:30460/TCP,2380:30563/TCP   25h
   service/apisix-istio-etcd-headless        ClusterIP   None             <none>        2379/TCP,2380/TCP               25h
   service/apisix-istio-gateway              NodePort    10.98.13.144     <none>        80:32667/TCP                    25h
   service/apisix-istio-ingress-controller   ClusterIP   10.97.247.104    <none>        80/TCP                          25h
   
   NAME                                              READY   UP-TO-DATE   AVAILABLE   AGE
   deployment.apps/apisix-istio                      1/1     1            1           25h
   deployment.apps/apisix-istio-ingress-controller   1/1     1            1           25h
   
   NAME                                                        DESIRED   CURRENT   READY   AGE
   replicaset.apps/apisix-istio-5dd564878b                     1         1         1       25h
   replicaset.apps/apisix-istio-ingress-controller-f74f5f74d   1         1         1       25h
   
   NAME                                 READY   AGE
   statefulset.apps/apisix-istio-etcd   3/3     25h
   
   [root@k8smaster01 apisix-istio]# cat apisix-route-nginx.yaml 
   apiVersion: apisix.apache.org/v2beta3
   kind: ApisixRoute
   metadata:
    name: nginx
    namespace: istio-demo
   spec:
    http:
    - name: rule2
   #   authentication:
   #     enable: true
   #     type: basicAuth
      match:
        hosts:
        - nginx.test
        paths:
          - /*
      backends:
      - serviceName: nginx
        servicePort: 80
        subset: v1
        weight: 50
      - serviceName: nginx
        servicePort: 80
        subset: v2
        weight: 50
   
   [root@k8smaster01 apisix-istio]# cat apisix-upstream-nginx.yaml 
   apiVersion: apisix.apache.org/v2beta3
   kind: ApisixUpstream
   metadata:
     name: nginx
     namespace: istio-demo
   spec:
   #  loadbalancer:
     retries: 3
     scheme: http
     subsets:
     - name: v1
       labels:
         version: v1
     - name: v2
       labels:
         version: v2
   ```
   
   **apisix-ngress-controller  pod logs:**
   
   ```
   ...
   2022-09-26T14:20:26+08:00       info    apisix/cluster.go:372   syncing schema  {"cluster": "default"}
   2022-09-26T14:20:26+08:00       error   apisix/plugin.go:46     failed to list plugins' names: Get "http://apisix-istio-admin.apisix-istio.svc.cluster.local:9180/apisix/admin/plugins?all=true": context canceled
   2022-09-26T14:20:26+08:00       error   apisix/cluster.go:392   failed to list plugin names in APISIX: Get "http://apisix-istio-admin.apisix-istio.svc.cluster.local:9180/apisix/admin/plugins?all=true": context canceled
   2022-09-26T14:20:26+08:00       error   apisix/cluster.go:355   failed to sync schema: Get "http://apisix-istio-admin.apisix-istio.svc.cluster.local:9180/apisix/admin/plugins?all=true": context canceled
   2022-09-26T14:20:26+08:00       info    ingress/controller.go:372       controller now is running as a candidate        {"namespace": "apisix-istio", "pod": "apisix-istio-ingress-controller-f74f5f74d-9nthf"}
   I0926 14:20:26.837506       1 leaderelection.go:248] attempting to acquire leader lease apisix-istio/ingress-apisix-leader...
   2022-09-26T14:20:26+08:00       info    ingress/controller.go:320       LeaderElection  {"message": "apisix-istio-ingress-controller-f74f5f74d-9nthf became leader", "event_type": "Normal"}
   I0926 14:20:26.845349       1 leaderelection.go:258] successfully acquired lease apisix-istio/ingress-apisix-leader
   2022-09-26T14:20:26+08:00       info    ingress/controller.go:406       controller tries to leading ... {"namespace": "apisix-istio", "pod": "apisix-istio-ingress-controller-f74f5f74d-9nthf"}
   2022-09-26T14:20:26+08:00       warn    apisix/cluster.go:332   waiting cluster default to ready, it may takes a while
   2022-09-26T14:20:26+08:00       info    apisix/cluster.go:372   syncing schema  {"cluster": "default"}
   2022-09-26T14:20:26+08:00       info    apisix/cluster.go:160   syncing cache   {"cluster": "default"}
   2022-09-26T14:20:26+08:00       error   apisix/upstream.go:122  failed to convert upstream item {"url": "http://apisix-istio-admin.apisix-istio.svc.cluster.local:9180/apisix/admin/upstreams", "upstream_key": "/apisix/upstreams/1058f76f", "error": "unexpected non-empty object"}
   2022-09-26T14:20:26+08:00       error   apisix/cluster.go:215   failed to list upstreams in APISIX: unexpected non-empty object
   2022-09-26T14:20:28+08:00       error   apisix/upstream.go:122  failed to convert upstream item {"url": "http://apisix-istio-admin.apisix-istio.svc.cluster.local:9180/apisix/admin/upstreams", "upstream_key": "/apisix/upstreams/1058f76f", "error": "unexpected non-empty object"}
   2022-09-26T14:20:28+08:00       error   apisix/cluster.go:215   failed to list upstreams in APISIX: unexpected non-empty object
   2022-09-26T14:20:30+08:00       error   apisix/upstream.go:122  failed to convert upstream item {"url": "http://apisix-istio-admin.apisix-istio.svc.cluster.local:9180/apisix/admin/upstreams", "upstream_key": "/apisix/upstreams/1058f76f", "error": "unexpected non-empty object"}
   2022-09-26T14:20:30+08:00       error   apisix/cluster.go:215   failed to list upstreams in APISIX: unexpected non-empty object
   2022-09-26T14:20:32+08:00       error   apisix/upstream.go:122  failed to convert upstream item {"url": "http://apisix-istio-admin.apisix-istio.svc.cluster.local:9180/apisix/admin/upstreams", "upstream_key": "/apisix/upstreams/1058f76f", "error": "unexpected non-empty object"}
   2022-09-26T14:20:32+08:00       error   apisix/cluster.go:215   failed to list upstreams in APISIX: unexpected non-empty object
   2022-09-26T14:20:34+08:00       error   apisix/upstream.go:122  failed to convert upstream item {"url": "http://apisix-istio-admin.apisix-istio.svc.cluster.local:9180/apisix/admin/upstreams", "upstream_key": "/apisix/upstreams/1058f76f", "error": "unexpected non-empty object"}
   2022-09-26T14:20:34+08:00       error   apisix/cluster.go:215   failed to list upstreams in APISIX: unexpected non-empty object
   2022-09-26T14:20:34+08:00       error   apisix/cluster.go:170   failed to sync cache    {"cost_time": "8.094020132s", "cluster": "default"}
   2022-09-26T14:20:34+08:00       error   ingress/controller.go:433
   ^C[root@k8smaster01 apisix-istio]# kubectl logs -f apisix-istio-ingress-controller-f74f5f74d-9nthf -n apisix-istio 
   ```
   **visit error:**
   ![image](https://user-images.githubusercontent.com/69373646/192210299-9f9d1cfe-0d36-4145-85d6-982f894d86c2.png)
   
   Cant sync to dashboard:
   ![image](https://user-images.githubusercontent.com/69373646/192210567-84e7242f-785a-4077-b86c-4e584bda2893.png)
   
   
   
   ### Environment
   
   - your apisix-ingress-controller version (output of apisix-ingress-controller version --long):  dashboard version is v2.13
   ```
   [root@k8smaster01 apisix-istio]# kubectl get po apisix-istio-ingress-controller-f74f5f74d-9nthf -n apisix-istio  -o yaml | grep -i image
       sidecar.istio.io/status: '{"initContainers":["istio-init"],"containers":["istio-proxy"],"volumes":["workload-socket","credential-socket","workload-certs","istio-envoy","istio-data","istio-podinfo","istio-token","istiod-ca-cert"],"imagePullSecrets":null,"revision":"default"}'
       image: apache/apisix-ingress-controller:1.4.1
       imagePullPolicy: IfNotPresent
       image: docker.io/istio/proxyv2:1.15.0
       imagePullPolicy: IfNotPresent
       image: busybox:1.28
       imagePullPolicy: IfNotPresent
       image: docker.io/istio/proxyv2:1.15.0
       imagePullPolicy: IfNotPresent
       image: docker.io/apache/apisix-ingress-controller:1.4.1
       imageID: docker.io/apache/apisix-ingress-controller@sha256:a9b8274e01f0ec8ef9404f9ef21ae4667fc7587cc69bd5e2febf1dce165ff696
       image: docker.io/istio/proxyv2:1.15.0
       imageID: docker.io/istio/proxyv2@sha256:0201788b1550dd95cbf7d7075c939dd581169e715699d8e8f85ed2a5f6b35cd2
       image: docker.io/library/busybox:1.28
       imageID: docker.io/library/busybox@sha256:141c253bc4c3fd0a201d32dc1f493bcf3fff003b6df416dea4f41046e0f37d47
       image: docker.io/istio/proxyv2:1.15.0
       imageID: docker.io/istio/proxyv2@sha256:0201788b1550dd95cbf7d7075c939dd581169e715699d8e8f85ed2a5f6b35cd2
   ```
   
   - your Kubernetes cluster version (output of kubectl version):
   ```
   [root@k8smaster01 apisix-istio]# kubectl version
   WARNING: This version information is deprecated and will be replaced with the output from kubectl version --short.  Use --output=yaml|json to get the full version.
   Client Version: version.Info{Major:"1", Minor:"24", GitVersion:"v1.24.0", GitCommit:"4ce5a8954017644c5420bae81d72b09b735c21f0", GitTreeState:"clean", BuildDate:"2022-05-03T13:46:05Z", GoVersion:"go1.18.1", Compiler:"gc", Platform:"linux/amd64"}
   Kustomize Version: v4.5.4
   Server Version: version.Info{Major:"1", Minor:"24", GitVersion:"v1.24.0", GitCommit:"4ce5a8954017644c5420bae81d72b09b735c21f0", GitTreeState:"clean", BuildDate:"2022-05-03T13:38:19Z", GoVersion:"go1.18.1", Compiler:"gc", Platform:"linux/amd64"}
   ```
   
   - if you run apisix-ingress-controller in Bare-metal environment, also show your OS version (uname -a):
   
   ```
   [root@k8smaster01 apisix-istio]# uname -a
   Linux k8smaster01.example.com 3.10.0-1160.62.1.el7.x86_64 #1 SMP Tue Apr 5 16:57:59 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
   ```
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix-ingress-controller] dc-weizhenhua commented on issue #1368: Cant sync apisixroute and apisixupstream to apisix-dashboard

Posted by GitBox <gi...@apache.org>.
dc-weizhenhua commented on issue #1368:
URL: https://github.com/apache/apisix-ingress-controller/issues/1368#issuecomment-1263122189

   > Did you follow the documentation exactly? The function is proven. Maybe there is some problem in your configuration
   
   Have you seen the description of my problem carefully including environment?  I just follow the documentation every step,and bookinfo apisixroute can sync  to dashboard,but it cant,when I create an new apisixroute and  apisixbackend   with different upstream


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix-ingress-controller] tao12345666333 commented on issue #1368: Cant sync apisixroute and apisixupstream to apisix-dashboard

Posted by GitBox <gi...@apache.org>.
tao12345666333 commented on issue #1368:
URL: https://github.com/apache/apisix-ingress-controller/issues/1368#issuecomment-1260285993

   Hi, For clarity, are you using Istio?
   Injected sidecar for APISIX Ingress?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix-ingress-controller] github-actions[bot] commented on issue #1368: Cant sync apisixroute and apisixupstream to apisix-dashboard

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on issue #1368:
URL: https://github.com/apache/apisix-ingress-controller/issues/1368#issuecomment-1418360124

   This issue has been closed due to lack of activity. If you think that is incorrect, or the issue requires additional review, you can revive the issue at any time.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix-ingress-controller] tao12345666333 commented on issue #1368: Cant sync apisixroute and apisixupstream to apisix-dashboard

Posted by GitBox <gi...@apache.org>.
tao12345666333 commented on issue #1368:
URL: https://github.com/apache/apisix-ingress-controller/issues/1368#issuecomment-1272189783

   I don't fully understand what you actually mean. Can you describe it more clearly?
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix-ingress-controller] dc-weizhenhua commented on issue #1368: Cant sync apisixroute and apisixupstream to apisix-dashboard

Posted by GitBox <gi...@apache.org>.
dc-weizhenhua commented on issue #1368:
URL: https://github.com/apache/apisix-ingress-controller/issues/1368#issuecomment-1261664703

   > 
   
   yes


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix-ingress-controller] tao12345666333 commented on issue #1368: Cant sync apisixroute and apisixupstream to apisix-dashboard

Posted by GitBox <gi...@apache.org>.
tao12345666333 commented on issue #1368:
URL: https://github.com/apache/apisix-ingress-controller/issues/1368#issuecomment-1260286353

   you can refer to this one https://apisix.apache.org/blog/2021/12/17/exposure-istio-with-apisix-ingress/


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix-ingress-controller] tao12345666333 commented on issue #1368: Cant sync apisixroute and apisixupstream to apisix-dashboard

Posted by GitBox <gi...@apache.org>.
tao12345666333 commented on issue #1368:
URL: https://github.com/apache/apisix-ingress-controller/issues/1368#issuecomment-1263019306

   Did you follow the documentation exactly?
   The function is proven. Maybe there is some problem in your configuration


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix-ingress-controller] github-actions[bot] commented on issue #1368: Cant sync apisixroute and apisixupstream to apisix-dashboard

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on issue #1368:
URL: https://github.com/apache/apisix-ingress-controller/issues/1368#issuecomment-1374334779

   This issue has been marked as stale due to 90 days of inactivity. It will be closed in 30 days if no further activity occurs. If this issue is still relevant, please simply write any comment. Even if closed, you can still revive the issue at any time or discuss it on the dev@apisix.apache.org list. Thank you for your contributions.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [apisix-ingress-controller] github-actions[bot] closed issue #1368: Cant sync apisixroute and apisixupstream to apisix-dashboard

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] closed issue #1368: Cant sync apisixroute and apisixupstream to apisix-dashboard
URL: https://github.com/apache/apisix-ingress-controller/issues/1368


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org