Comments (6)
请提供您的soar -print-config
输出
from soar.
请提供您的
soar -print-config
输出
online-dsn:
addr: ""
schema: information_schema
user: ""
password: '********'
charset: utf8mb4
disable: true
test-dsn:
addr: ""
schema: information_schema
user: ""
password: '********'
charset: utf8mb4
disable: true
allow-online-as-test: false
drop-test-temporary: true
only-syntax-check: false
sampling-statistic-target: 100
sampling: false
profiling: false
trace: false
explain: true
conn-time-out: 3
query-time-out: 30
delimiter: ;
log-level: 3
log-output: /dev/stderr
report-type: markdown
report-css: ""
report-javascript: ""
report-title: SQL优化分析报告
markdown-extensions: 94
markdown-html-flags: 0
ignore-rules:
- COL.011
rewrite-rules:
- delimiter
- orderbynull
- groupbyconst
- dmlorderby
- having
- star2columns
- insertcolumns
- distinctstar
blacklist: ""
max-join-table-count: 5
max-group-by-cols-count: 5
max-distinct-count: 5
max-index-cols-count: 5
max-total-rows: 9999999
max-query-cost: 9999
spaghetti-query-length: 2048
allow-drop-index: false
max-in-count: 10
max-index-bytes-percolumn: 767
max-index-bytes: 3072
table-allow-charsets:
- utf8
- utf8mb4
table-allow-engines:
- innodb
max-index-count: 10
max-column-count: 40
index-prefix: idx_
unique-key-prefix: uk_
max-subquery-depth: 5
max-varchar-length: 1024
explain-sql-report-type: pretty
explain-type: extended
explain-format: traditional
explain-warn-select-type:
- ""
explain-warn-access-type:
- ALL
explain-max-keys: 3
explain-min-keys: 0
explain-max-rows: 10000
explain-warn-extra:
- Using temporary
- Using filesort
explain-max-filtered: 100
explain-warn-scalability:
- O(n)
show-warnings: false
show-last-query-cost: false
query: ""
list-heuristic-rules: false
list-rewrite-rules: false
list-test-sqls: false
list-report-types: false
verbose: false
dry-run: true
max-pretty-sql-length: 1024
from soar.
一般指定了数据库但是没有 EXPLAIN 和 INDEX 优化信息往往是数据库连接异常所致。可以修改一下 logout 和 loglevel,看一下日志里的信息。
from soar.
从提供的配置文件看,您未创建配置文件,命令行参数也未指定-online-dsn, -test-dsn,所以-print-config的输出中online-dsn和test-dsn输出的都为空。
另外提示一下,如果用户名或密码中有特殊字符需要通过配置文件配置,命令行中不支持存在特殊字符的账号和密码。
from soar.
从提供的配置文件看,您未创建配置文件,命令行参数也未指定-online-dsn, -test-dsn,所以-print-config的输出中online-dsn和test-dsn输出的都为空。
另外提示一下,如果用户名或密码中有特殊字符需要通过配置文件配置,命令行中不支持存在特殊字符的账号和密码。
指定了-test-dsn的时候也不会去连接数据库给出建议
online-dsn:
addr: ""
schema: information_schema
user: ""
password: '********'
charset: utf8mb4
disable: true
test-dsn:
addr: 192.168.10.10:3306
schema: puzzle
user: root
password: '********'
charset: utf8mb4
disable: false
allow-online-as-test: false
drop-test-temporary: true
only-syntax-check: false
sampling-statistic-target: 100
sampling: false
profiling: false
trace: false
explain: true
conn-time-out: 3
query-time-out: 30
delimiter: ;
log-level: 3
log-output: /dev/stderr
report-type: text
report-css: ""
report-javascript: ""
report-title: SQL优化分析报告
markdown-extensions: 94
markdown-html-flags: 0
ignore-rules:
- COL.011
rewrite-rules:
- delimiter
- orderbynull
- groupbyconst
- dmlorderby
- having
- star2columns
- insertcolumns
- distinctstar
blacklist: ""
max-join-table-count: 5
max-group-by-cols-count: 5
max-distinct-count: 5
max-index-cols-count: 5
max-total-rows: 9999999
max-query-cost: 9999
spaghetti-query-length: 2048
allow-drop-index: false
max-in-count: 10
max-index-bytes-percolumn: 767
max-index-bytes: 3072
table-allow-charsets:
- utf8
- utf8mb4
table-allow-engines:
- innodb
max-index-count: 10
max-column-count: 40
index-prefix: idx_
unique-key-prefix: uk_
max-subquery-depth: 5
max-varchar-length: 1024
explain-sql-report-type: pretty
explain-type: extended
explain-format: traditional
explain-warn-select-type:
- ""
explain-warn-access-type:
- ALL
explain-max-keys: 3
explain-min-keys: 0
explain-max-rows: 10000
explain-warn-extra:
- Using temporary
- Using filesort
explain-max-filtered: 100
explain-warn-scalability:
- O(n)
show-warnings: false
show-last-query-cost: false
query: SELECT * FROM products WHERE ppid>12
list-heuristic-rules: false
list-rewrite-rules: false
list-test-sqls: false
list-report-types: false
verbose: false
dry-run: true
max-pretty-sql-length: 1024
from soar.
如果您只有一个测试环境可以在配置文件中将online-dsn和test-dsn配置为同一个,且将allow-online-as-test配置为true。
如果还是报错可以将log-level设置为7级,看一下日志中的错误信息。
from soar.
Related Issues (20)
- yaml配置schema带有中划线,报错[mysql.go:95] Error 1064 HOT 1
- SQL评分规则LIT.002是否有点问题 HOT 1
- 发现soar对mysql 5.7.32不输出执行计划 HOT 1
- 文档及交流
- [Bug]在macOs版本12.1和go版本1.17.2下, 无法运行
- 关于☠️ 和scalability的疑问
- windows环境下无法编译
- 语法检查与SQL评估 不支持Mysql point 数据类型 HOT 1
- Can NOT run `make tidb`
- [BUG] compress后语句内容tab被替换为了空格
- Add param to specify the sql audit result to a table in database ,for instance,storage in a mysql table for convenience batch get result?
- 有支持oracle的规划和想法吗?
- mac os 报错segmentation fault
- 可以输入指纹SQL来进行评分么?
- 增加论文WeTune提出的rewrite rule
- Vulnerability of dependency "golang.org/x/net" HOT 1
- soar 无法使用,日志如下,请帮忙看下是否是配置问题,谢谢
- 后面是否会支持 ARM 架构的?
- 规则column-not-allow-type解析后的报告展示错误
- make编译失败了。
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from soar.