就在今天,SkyWorking發佈了6.2版本。html
SkyWalking是觀察性分析平臺和應用性能管理系統。java
提供分佈式追蹤、服務網格遙測分析、度量聚合和可視化一體化解決方案。
node
SkyWalking 的核心是數據分析和度量結果的存儲平臺,經過 HTTP 或 gRPC 方式向 SkyWalking Collecter 提交分析和度量數據,SkyWalking Collecter 對數據進行分析和聚合,存儲到 Elasticsearch、MySQL、TiDB 等其一便可,最後咱們能夠經過 SkyWalking UI 的可視化界面對最終的結果進行查看。mysql
Skywalking 支持從多個來源和多種格式收集數據:多種語言的 Skywalking Agent 、Zipkin v1/v2 、Istio 勘測、Envoy 度量等數據格式。linux
2019 年 4 月 24 日(北美時間),Apache 軟件基金會宣佈,Apache SkyWalking 畢業,成爲 Apache 軟件基金會頂級項目。ios
Skyworking體驗地址: linkgithub
span#error
in application toolkit.import
check.ID is null
query(s).systemctl stop firewalld systemctl disable firewalld sed -i 's#^SELINUX=.*#SELINUX=disabled#g' /etc/sysconfig/selinux setenforce 0
# 查看當前服務器最大打開進程數和文件句柄數 [root@test-01 ~]#ulimit -a|egrep 'open files|max user' open files (-n) 1024 max user processes (-u) 7191 # 修改/etc/systemd/system.conf文件中的相關參數,與CentOS6修改的方式略有不一樣 [root@test-01 ~]#sed -i '/^#DefaultLimitNOFILE=/aDefaultLimitNOFILE=65535' /etc/systemd/system.conf [root@test-01 ~]#sed -i '/^#DefaultLimitNPROC=/aDefaultLimitNPROC=65535' /etc/systemd/system.conf [root@test-01 ~]#sed -i 's#nproc 4096#nproc 65535#' /etc/security/limits.d/20-nproc.conf # 須要重啓才能生效 [root@test-01 ~]#reboot
[root@test-01 ~]# yum install java-1.8.0-openjdk [root@test-01 ~]# java -version openjdk version "1.8.0_212" OpenJDK Runtime Environment (build 1.8.0_212-b04) OpenJDK 64-Bit Server VM (build 25.212-b04, mixed mode)
mkdir -p /data/elasticsearch/logs # 下載rpm安裝包 wget -P /opt/downloads -c https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-6.8.1.rpm # 安裝 rpm -ivh /opt/downloads/elasticsearch-6.8.1.rpm # 受權 chown -R elasticsearch.elasticsearch /data/elasticsearch
修改配置/etc/elasticsearch/elasticsearch.yml
web
path.data: /data/elasticsearch path.logs: /data/elasticsearch/logs network.host: 0.0.0.0
啓動spring
systemctl start elasticsearch
# 下載安裝包 wget --no-check-certificate --no-cookies --header "Cookie: oraclelicense=accept-securebackup-cookie" -P /opt/downloads https://mirrors.tuna.tsinghua.edu.cn/apache/skywalking/6.2.0/apache-skywalking-apm-6.2.0.tar.gz # 壓縮 tar zxf /opt/downloads/apache-skywalking-apm-6.2.0.tar.gz -C /usr/local mv apache-skywalking-apm-bin skyworking # 啓動 cd /usr/local/skyworking/bin ./startup.sh
確保8080,10800,11800,12800 端口不被佔用,如有衝突,能夠在
webapp/webapp.yml
中修改
打開UI,地址爲http://服務器IP:8080
參考地址:java agent
agent
的路徑config/agent.config
,設置agent.service_name
config/agent.config
,設置 collector.backend_service
,默認鏈接到 127.0.0.1:11800
-jar
前,將 -javaagent:/path/to/skywalking-package/agent/skywalking-agent.jar
添加到表達式agent目錄下的文件和目錄
+-- agent +-- activations apm-toolkit-log4j-1.x-activation.jar apm-toolkit-log4j-2.x-activation.jar apm-toolkit-logback-1.x-activation.jar ... +-- config agent.config +-- plugins apm-dubbo-plugin.jar apm-feign-default-http-9.x.jar apm-httpClient-4.x-plugin.jar ..... skywalking-agent.jar
tomcat/bin/catalina.sh
.CATALINA_OPTS="$CATALINA_OPTS -javaagent:/path/to/skywalking-agent/skywalking-agent.jar"; export CATALINA_OPTS
tomcat/bin/catalina.bat
.set "CATALINA_OPTS=-javaagent:/path/to/skywalking-agent/skywalking-agent.jar"
-javaagent
argument to command line in which you start your app. eg:java -javaagent:/path/to/skywalking-agent/skywalking-agent.jar -jar yourApp.jar
如下爲agent/config/agent.config
的配置屬性列表
property key | Description | Default |
---|---|---|
agent.namespace |
Namespace isolates headers in cross process propagation. The HEADER name will be HeaderName:Namespace . |
Not set |
agent.service_name |
Application(5.x)/Service(6.x) code is showed in sky-walking-ui. Suggestion: set a unique name for each service, service instance nodes share the same code | Your_ApplicationName |
agent.sample_n_per_3_secs |
Negative or zero means off, by default.SAMPLE_N_PER_3_SECS means sampling N TraceSegment in 3 seconds tops. | Not set |
agent.authentication |
Authentication active is based on backend setting, see application.yml for more details.For most scenarios, this needs backend extensions, only basic match auth provided in default implementation. | Not set |
agent.span_limit_per_segment |
The max number of spans in a single segment. Through this config item, skywalking keep your application memory cost estimated. | Not set |
agent.ignore_suffix |
If the operation name of the first span is included in this set, this segment should be ignored. | Not set |
agent.is_open_debugging_class |
If true, skywalking agent will save all instrumented classes files in /debugging folder.Skywalking team may ask for these files in order to resolve compatible problem. |
Not set |
agent.active_v2_header |
Active V2 header in default. | true |
agent.instance_uuid |
Instance uuid is the identity of an instance, skywalking treat same instance uuid as one instance.if empty, skywalking agent will generate an 32-bit uuid. | "" |
agent.cause_exception_depth |
How depth the agent goes, when log all cause exceptions. | 5 |
agent.active_v1_header |
Deactive V1 header in default. | false |
collector.grpc_channel_check_interval |
grpc channel status check interval. | 30 |
collector.app_and_service_register_check_interval |
application and service registry check interval. | 3 |
collector.backend_service |
Collector skywalking trace receiver service addresses. | 127.0.0.1:11800 |
logging.level |
The log level. Default is debug. | DEBUG |
logging.file_name |
Log file name. | skywalking-api.log |
logging.dir |
Log files directory. Default is blank string, means, use "system.out" to output logs. | "" |
logging.max_file_size |
The max size of log file. If the size is bigger than this, archive the current file, and write into a new file. | 300 * 1024 * 1024 |
jvm.buffer_size |
The buffer size of collected JVM info. | 60 * 10 |
buffer.channel_size |
The buffer channel size. | 5 |
buffer.buffer_size |
The buffer size. | 300 |
dictionary.service_code_buffer_size |
The buffer size of application codes and peer | 10 * 10000 |
dictionary.endpoint_name_buffer_size |
The buffer size of endpoint names and peer | 1000 * 10000 |
plugin.mongodb.trace_param |
If true, trace all the parameters in MongoDB access, default is false. Only trace the operation, not include parameters. | false |
plugin.elasticsearch.trace_dsl |
If true, trace all the DSL(Domain Specific Language) in ElasticSearch access, default is false. | false |
plugin.springmvc.use_qualified_name_as_endpoint_name |
If true, the fully qualified method name will be used as the endpoint name instead of the request URL, default is false. | false |
plugin.toolit.use_qualified_name_as_operation_name |
If true, the fully qualified method name will be used as the operation name instead of the given operation name, default is false. | false |
plugin.mysql.trace_sql_parameters |
If set to true, the parameters of the sql (typically java.sql.PreparedStatement ) would be collected. |
false |
plugin.mysql.sql_parameters_max_length |
If set to positive number, the db.sql.parameters would be truncated to this length, otherwise it would be completely saved, which may cause performance problem. |
512 |
plugin.solrj.trace_statement |
If true, trace all the query parameters(include deleteByIds and deleteByQuery) in Solr query request, default is false. | false |
plugin.solrj.trace_ops_params |
If true, trace all the operation parameters in Solr request, default is false. | false |
若須要使用第三方插件,能夠將插件放入 /plugins
路徑下。
插件開發指南