Open jinjianming opened 1 year ago
We need some information for troubleshooting:
我们需要一些信息来进行故障排除:
- 您是如何配置 Route、Upstream 和其他对象的?
- 你用过K8s的服务发现模块吗?
- APISIX 数据平面的 DNS 解析器是什么?
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: js-design-web
spec:
http:
- name: rule1
match:
hosts:
- cjyoumen.com
paths:
- /*
backends:
- serviceName: js-design-nginx
servicePort: 80
dns_resolver:
- coredns.kube-system.svc.cluster.local
dns_resolver_valid: 30
resolver_timeout: 5
2023/02/27 09:53:22 [info] 50#50: *377 [lua] resolver.lua:88: parse_domain(): dns resolver domain: apisix-control-plane-control-plane to `10.233.46.87`, context: ngx.timer
root@node01:/home/apisix/apisix-1.1.0# kubectl get svc -n ingress-apisix|grep 10.233.46.87
apisix-control-plane-control-plane NodePort 10.233.46.87 <none> 9280:34054/TCP 5h53m
@tokers When the upstream does not change, the first startup can work normally. Once the Upstream changes, the data plane will not be able to load the latest address. What is the difference between the first load and the POST path:/watch
, resulting in inaccessible access;
@tokers Hello, do you have any other suggestions for troubleshooting
@tokers 请教您一下在解耦架构下必须使用kubernetes 服务发现或者其他服务发现么?
我尝试在DP模块上配置kubernetes discovery确实可以实现上游地址的更新,但是通过admin 创建的路由和上游地址,无法更新到DP生效;
discovery: kubernetes: {}
我使用docker-compose也有相同的问题,我在这个连接中 https://github.com/apache/apisix/issues/9049 详细描述了如何复现此问题,并在附件中添加了我的部署文件,是否能够支持一下问题所在,万分感谢。
@jinjianming are you able to fix this issue at the end? I encountered the exact same issue, is it possible to force apisix to reload?
This issue has been marked as stale due to 350 days of inactivity. It will be closed in 2 weeks 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.
I see the same issue, the upstream failed to refresh after pod restart
I have added resolveGranularity: service
to resolve
apiVersion: apisix.apache.org/v2
kind: ApisixRoute
metadata:
name: block-explorer
spec:
http:
- name: http
priority: 0
match:
hosts:
- host
paths:
- /*
backends:
- serviceName: <service>
servicePort: <port>
resolveGranularity: service
Yes we loose apisix load balancing, but this is ok for us
Description
Discovery
sync_ Data() res: null
res result is null and the update failedThe requested address is still the old one; can see that the address in the ETCD is 10.233.64.32 and the data-plane is actually forwarded to 10.233.64.29.
I can see from the dashboard that upstream is up to date, and Data-plane cannot automatically refresh the latest address;
Whether to add 'sni' or other configurations
Environment
apisix version
): 3.1.0uname -a
): 4.15.0-202-generic Ubuntu SMP Thu Jan 5 19:19:12 UTC 2023 x86_64 GNU/Linuxopenresty -V
ornginx -V
): nginx version: openresty/1.21.4.1curl http://127.0.0.1:9090/v1/server_info
): {"etcdserver":"3.5.4","etcdcluster":"3.5.0"}luarocks --version
):