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

应用压力测试,为什么应用集成的Nacos几乎挂掉? #4143

Closed
liugh1974 opened this issue Nov 5, 2020 · 7 comments
Closed

应用压力测试,为什么应用集成的Nacos几乎挂掉? #4143

liugh1974 opened this issue Nov 5, 2020 · 7 comments
Labels
status/invalid This doesn't seem right

Comments

@liugh1974
Copy link

我有一个基于springboot2的应用,集成了一个集群Nacos (3 nodes), 然后我在做我的应用高压力测试的时候,Nacos 的 WEB 页面就刷不出东西来了,一直显示加载的那个圈圈, 甚至直接页面就是空白。当压力测试完成后,Nacos web页面就恢复正常了。请问是什么原因?

@liugh1974 liugh1974 changed the title 应用压力测试,为什么应用集成的Nacos被几乎挂掉? 应用压力测试,为什么应用集成的Nacos几乎挂掉? Nov 5, 2020
@horizonzy
Copy link
Collaborator

能提供多一点信息吗,如果是压应用的话是不会影响到nacos服务端的。是否是因为应用和nacos在一台机器,系统资源吃紧影响了nacos服务端。

@liugh1974
Copy link
Author

liugh1974 commented Nov 5, 2020

不是同一台机器。Nacos是在单独的三台服务器上,应用服务是单独的四台服务器。当时我看到的时候也觉得很奇怪,但我多次的压力测试的时候,确实每次的都是这个情况。最初是因为要调整应用的日志级别的时候发现这个问题,发现页面都刷不出来。压力测试完成,页面就可以刷出来了。下面是应用上的nacos配置:

spring:
  cloud:
    nacos:
      discovery:
        server-addr: ${nacos.server-address}
        metadata:
          serverName: ${server.server-name}   # 唯一
        namespace: ${nacos.namespace}
      config:
        server-addr: ${nacos.server-address}
        file-extension: yml
        shared-dataids: a.yml,b.yml
        refreshable-dataids: a.yml,b.yml
        namespace: ${nacos.namespace}

@horizonzy
Copy link
Collaborator

看一下你的那台web刷不出来的nacos的access.log呢,看看那段时间有没有什么请求打到服务端。或者你压测的时候,看一下是不是nacos服务端的cpu飙升了,看看nacos服务端的堆栈信息在干什么

@KomachiSion
Copy link
Collaborator

理论上应用流量和nacos的流量是分离的,应该是压测的时候某种问题影响到了nacos。需要您根据环境自行排查。如果有不确定的地方,麻烦将相关信息在issue中暴露出来。

@liugh1974
Copy link
Author

没有access.log 文件。

下面的哪一个文件可以看?看内容 config-client-request.log 和 naming-server.log 有点象。
alipay-jraft.log
config-dump.log
config-notify.log
config-server.log
istio-main.log
nacos_gc.log.0.current
naming-event.log
naming-raft.log
protocol-distro.log
cmdb-main.log
config-fatal.log
config-pull-check.log
config-trace.log
nacos-address.log
nacos.log
naming-performance.log
naming-rt.log
protocol-raft.log
config-client-request.log
config-memory.log
config-pull.log
core-auth.log 、
nacos-cluster.log
naming-distro.log
naming-push.log
naming-server.log
start.out

@KomachiSion
Copy link
Collaborator

都需要看,主要看压测期间哪个日志内容刷新频繁,可能的话最好开启access_log,然后压测时候看一下access_log是不是有很多请求打入到了nacos上,分别是什么API。

@KomachiSion
Copy link
Collaborator

Any more information? If no more response, i will close issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status/invalid This doesn't seem right
Projects
None yet
Development

No branches or pull requests

3 participants