jly8866 / archer Goto Github PK
View Code? Open in Web Editor NEW基于inception的自动化SQL操作平台,支持SQL执行、LDAP认证、发邮件、OSC、SQL查询、SQL优化建议、权限管理等功能,支持docker镜像
License: Apache License 2.0
基于inception的自动化SQL操作平台,支持SQL执行、LDAP认证、发邮件、OSC、SQL查询、SQL优化建议、权限管理等功能,支持docker镜像
License: Apache License 2.0
目前不少企业在生产环境使用archer系统审核和执行SQL,包括但不限于: 艺龙旅行网、杭州九言、华润集团、宝宝树、pactera、正保远程教育、跟谁学、51信用卡等。
下面大家可以继续补充
我相信大量功能是有水平切分需求的,是否可以考虑添加多选功能,同时在水平切分的实例上面同时执行。。。
我用python3 manage.py createsuperuser 创建的用户怎么看不到工程师提交的审核工单呢
有没有考虑做成docker镜像,这样安装配置会比较方便?
之前我提了几个使用问题,今天测试了最新版,发现如下问题。 申请者发起DDL SQL申请,在这,之前审核人员不能再待执行工单看见工单的问题已经修复,点击执行,会显示如下页面:
然后,刷新页面,已然是这样。 多尝试刷新几次也仍然是这个页面。
期间,我记录了下inception的端口状态,如下:
我进被修改的数据库确认,每次工单应该都执行成功了,但是邮件已然没有收到,可能是因为工单状态没有变为已执行的原因。上述问题稳定复现, 我试了几次, 工单状态如下:
我强烈希望,咱们能先稳稳,起码保证版本功能可以正常使用,然后再开发改动比较大的新功能。 一直期待Pt-osc进度条的新版本,到目前仍然没有一个完整的体验。
inception里应该是支持osc的,但是我这边跑一些更改大表的sql, 如果走osc(在inception的任务列表里可以看到)的话,好多任务会失败,我怀疑是inception执行pt-online-schema-change时加的参数的问题,请问你对于pt-online-schema-change这个工具你怎么控制参数的?
请问一下,您的这个MySQLdb在python3.x下面的安装包名叫什么?MySQL-python 1.2.5这个好像支持python v2.7.x版本。
SQL在线查询部分,如何判断一个SQL是否包含了写操作呢?是通过限制账号的权限限制的吗?
可以同时执行多条sql吗
测试生成8万条回滚语句,查看无分页,也无法将回滚导出成sql文件,建议查看回滚语句设置分页,另有回滚sql导出功能。
我看docker镜像比较早,请问docker镜像是否可以自动更新?
这里的未登录重定向到/login/ 可以通过 django 的 login_required 实现
from django.contrib.auth.decorators import login_required
@login_required
def my_view(request):
不过这个要用的话就需要用上django 自带的一些认证系统, 这里的用户系统可能会需要一些扩充
角色这块可以用外键的方式扩充, 放在一个Profile table里,然后对应的 view可以使用 django的检验修饰器 做
等我搭好了会再提一个pull request
查询中如果有子查询语句,子查询中的字段别名的使用上不支持,错误如下:
inception返回异常:
Incorrect database name ''
Column 't1.min_id' not existed.
Column 't1.max_id' not existed.
以下是模拟的子查询sql语句
SELECT
t2.ID,
t2.USER_ID,
t2.NICKNAME,
t2.BIRTHDAY,
t2.CNAME
FROM
(
SELECT
ID,
MIN(id) AS min_id,
MAX(id) AS max_id
FROM
t_user
) t1
LEFT JOIN t_user t2 ON t1.min_id = t2.id
LEFT JOIN t_user t3 ON t1.max_id = t3.id;
File "/data/zhangcd/.pyenv/versions/archer_3.4.1_env/lib/python3.4/site-packages/django/db/models/manager.py", line 127, in manager_method
return getattr(self.get_queryset(), name)(*args, **kwargs)
File "/data/zhangcd/.pyenv/versions/archer_3.4.1_env/lib/python3.4/site-packages/django/db/models/query.py", line 920, in _insert
return query.get_compiler(using=using).execute_sql(return_id)
File "/data/zhangcd/.pyenv/versions/archer_3.4.1_env/lib/python3.4/site-packages/django/db/models/sql/compiler.py", line 974, in execute_sql
cursor.execute(sql, params)
File "/data/zhangcd/.pyenv/versions/archer_3.4.1_env/lib/python3.4/site-packages/django/db/backends/utils.py", line 79, in execute
return super(CursorDebugWrapper, self).execute(sql, params)
File "/data/zhangcd/.pyenv/versions/archer_3.4.1_env/lib/python3.4/site-packages/django/db/backends/utils.py", line 64, in execute
return self.cursor.execute(sql, params)
File "/data/zhangcd/.pyenv/versions/archer_3.4.1_env/lib/python3.4/site-packages/django/db/utils.py", line 98, in exit
six.reraise(dj_exc_type, dj_exc_value, traceback)
File "/data/zhangcd/.pyenv/versions/archer_3.4.1_env/lib/python3.4/site-packages/django/utils/six.py", line 685, in reraise
raise value.with_traceback(tb)
File "/data/zhangcd/.pyenv/versions/archer_3.4.1_env/lib/python3.4/site-packages/django/db/backends/utils.py", line 64, in execute
return self.cursor.execute(sql, params)
File "/data/zhangcd/.pyenv/versions/archer_3.4.1_env/lib/python3.4/site-packages/django/db/backends/mysql/base.py", line 124, in execute
return self.cursor.execute(query, args)
File "/data/zhangcd/.pyenv/versions/archer_3.4.1_env/lib/python3.4/site-packages/pymysql/cursors.py", line 166, in execute
result = self._query(query)
File "/data/zhangcd/.pyenv/versions/archer_3.4.1_env/lib/python3.4/site-packages/pymysql/cursors.py", line 322, in _query
conn.query(q)
File "/data/zhangcd/.pyenv/versions/archer_3.4.1_env/lib/python3.4/site-packages/pymysql/connections.py", line 856, in query
self._affected_rows = self._read_query_result(unbuffered=unbuffered)
File "/data/zhangcd/.pyenv/versions/archer_3.4.1_env/lib/python3.4/site-packages/pymysql/connections.py", line 1057, in _read_query_result
result.read()
File "/data/zhangcd/.pyenv/versions/archer_3.4.1_env/lib/python3.4/site-packages/pymysql/connections.py", line 1341, in read
first_packet = self.connection._read_packet()
File "/data/zhangcd/.pyenv/versions/archer_3.4.1_env/lib/python3.4/site-packages/pymysql/connections.py", line 1014, in _read_packet
packet.check_error()
File "/data/zhangcd/.pyenv/versions/archer_3.4.1_env/lib/python3.4/site-packages/pymysql/connections.py", line 393, in check_error
err.raise_mysql_exception(self._data)
File "/data/zhangcd/.pyenv/versions/archer_3.4.1_env/lib/python3.4/site-packages/pymysql/err.py", line 107, in raise_mysql_exception
raise errorclass(errno, errval)
django.db.utils.InternalError: (1366, "Incorrect string value: '\xE7\x94\xA8\xE6\x88\xB7...' for column 'name' at row 1")
看着像是编码的问题,请问是怎么回事?
我是docker装的mysql8.0,
初始化数据库报错
return self.connection.mysql_version >= (5, 6, 4) and Database.version_info >= (1, 2, 5)
是不是不支持8.0哦
采取docker部署
docker镜像,参考wiki
inception镜像: https://hub.docker.com/r/hhyo/archer
archer镜像: https://hub.docker.com/r/hhyo/inception
docker镜像制作感谢@小圈圈 提供
其中镜像地址写反了。
工程师-审核者-DBA
Archer使用者,之前版本使用正常,最新版本的clone下来,只把原来的settings.py拷贝过去直接用的,并没有其他修改,遇见几个小问题,我感觉这对正式环境使用影响还是挺大的,没有别的意思,只希望archer越做越好,在这提一下这几个小问题 :
工单结束后,收不到正常结束的邮件啊,这十分的不方便。
SQL执行的时候,有个重新修改的按钮, 点完之后跳到 http://xx.xx.xx.xx/editsql/ ,好像就是导航页,只有发起SQL的人能使用么? 而且还是审核人只能在执行过程中才能看见,这样跳转的意义是让审核人重新再发起一条SQL麽 ? 和http://xx.xx.xx.xx/submitsql/ 感觉没有什么区别啊? 不知道这个按钮的作用。 而且审核人并没有发起的SQL的权限啊,我用审核人只能跳到下面导航页。 我记得咱们这个一个用户不能选定多个角色吧,没法既是工程师又是审核人啊,所以感觉对于审核人根本没啥意义啊,过程中发现问题,并不能提交修改SQL。 不知道是不是我个人理解有问题。
在两台虚拟机上跑脚本,均无法抓取慢日志里的sql记录到数据库,我的目标数据库和archer所在数据库,均有archer用户,并且all privileges;
慢日志中有内容,并且我也会删除last_analysis_time_$hostname这个文件,但还是抓取不到sql,但是很奇怪的抓取到了慢日志中的show语句:SHOW VARIABLES LIKE 'wait_timeout';
还请大神们帮忙看看
我的脚本配置:
#!/bin/bash
DIR="$( cd "$( dirname "$0" )" && pwd )"
cd $DIR
#config monitor database server 收集日志 配置archer数据库的连接地址
monitor_db_host="192.168.1.159"
monitor_db_port=3306
monitor_db_user="archer"
monitor_db_password="111111"
monitor_db_database="archer"
#config mysql server 被监控机
mysql_host="192.168.1.159" # 和archer主库配置保持一致
mysql_port=3306 # 和archer主库配置保持一致
#config slowqury 被监控机慢日志位置
slowquery_file="/data/mysql/slow.log"
pt_query_digest="/usr/local/bin/pt-query-digest"
#config server_id
hostname="${mysql_host}:${mysql_port}" # 用于archer做筛选
#获取上次分析时间,初始化时请删除last_analysis_time_$hostname文件,可分析全部日志数据
if [ -s last_analysis_time_$hostname ]; then
last_analysis_time=cat last_analysis_time_$hostname
else
last_analysis_time='1000-01-01 00:00:00'
fi
#collect mysql slowquery log into monitor database
#RDS需要增加--no-version-check选项
$pt_query_digest
--user=$monitor_db_user --password=$monitor_db_password --port=$monitor_db_port
--review h=$monitor_db_host,D=$monitor_db_database,t=mysql_slow_query_review
--history h=$monitor_db_host,D=$monitor_db_database,t=mysql_slow_query_review_history
--no-report --limit=100% --charset=utf8
--since "$last_analysis_time"
--filter="$event->{Bytes} = length($event->{arg}) and $event->{hostname}="$hostname" and $event->{client}=$event->{ip} "
$slowquery_file > /tmp/analysis_slow_query.log
echo date +"%Y-%m-%d %H:%M:%S"
>last_analysis_time_$hostname
http://mysql-inception.github.io/inception-document/install/
不存在了,现在这个仓库被连接到https://github.com/arkcontrol/arkcontrol了
是否可以更换为https://github.com/XiaoMi/soar 或者开一个新仓库继续维护inception
有人已经fork一个新的inception,地址为:https://github.com/hhyo/inception
目前 https://github.com/jly8866/archer/blob/master/sql/dao.py 的Dao对象只是一堆函数的集合,没有把对象这个功能用上, 我计划直接把master_config或者 slave_config 对象直接传进来当参数, 初始化dao对象, 这样调用的时候就不需要每次都加 username password 这类的信息了
在线查询数据功能,如果查询select * from table 时候报如下错误.
精确定位后发现,是字段数据类型为time时候就会报错.
日志显示入下
[2018-07-31 11:36:51,927][MainThread:140477748217600][task_id:default][exception_logging_middleware.py:10] [ERROR]- Traceback (most recent call l
ast):
File "/data/archer/sql/extend_json_encoder.py", line 52, in default
return convert(obj)
File "/data/venv4archer/lib/python3.6/functools.py", line 803, in wrapper
return dispatch(args[0].class)(*args, **kw)
File "/data/archer/sql/extend_json_encoder.py", line 26, in convert
raise TypeError('can not convert type')
TypeError: can not convert type
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/data/venv4archer/lib/python3.6/site-packages/django/core/handlers/base.py", line 132, in get_response
response = wrapped_callback(request, *callback_args, **callback_kwargs)
File "/data/venv4archer/lib/python3.6/site-packages/django/views/decorators/csrf.py", line 58, in wrapped_view
return view_func(*args, **kwargs)
File "/data/archer/sql/query.py", line 724, in query
return HttpResponse(json.dumps(finalResult, cls=ExtendJSONEncoder, bigint_as_string=True),
File "/data/venv4archer/lib/python3.6/site-packages/simplejson/init.py", line 399, in dumps
**kw).encode(obj)
File "/data/venv4archer/lib/python3.6/site-packages/simplejson/encoder.py", line 286, in encode
chunks = self.iterencode(o, _one_shot=True)
File "/data/venv4archer/lib/python3.6/site-packages/simplejson/encoder.py", line 368, in iterencode
return _iterencode(o, 0)
File "/data/archer/sql/extend_json_encoder.py", line 54, in default
return super(ExtendJSONEncoder, self).default(obj)
File "/data/venv4archer/lib/python3.6/site-packages/simplejson/encoder.py", line 263, in default
o.class.name)
TypeError: Object of type timedelta is not JSON serializable
SQL在线查询中的查询结果显示的表格,用的什么插件
主库配置OK,在主库会话管理中成功读到数据 ,在提交工单时,点击SQL检测,总是提示
status:1
msg: (203, "Can't connect to MySQL server on '127.0.0.1' ([Errno 111] Connection refused)")
场景:提交SQL到测试环境执行,然后上线的时候,可以直接在原来的单申请上线,然后执行到正式环境,不用重新提工单
我看原来inception是支持这样的操作
环境:
python:3.4
django:1.8
mysql : 5.4.42
self.server_version = '5.6.24-72.2-log'
python3 manage.py migrate
python3 manage.py makemigrations
Traceback (most recent call last):
File "manage.py", line 10, in
execute_from_command_line(sys.argv)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/core/management/init.py", line 354, in execute_from_command_line
utility.execute()
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/core/management/init.py", line 346, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/core/management/base.py", line 394, in run_from_argv
self.execute(*args, **cmd_options)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/core/management/base.py", line 445, in execute
output = self.handle(*args, **options)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/core/management/commands/makemigrations.py", line 63, in handle
loader = MigrationLoader(None, ignore_no_migrations=True)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/migrations/loader.py", line 47, in init
self.build_graph()
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/migrations/loader.py", line 321, in build_graph
_reraise_missing_dependency(migration, parent, e)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/migrations/loader.py", line 291, in _reraise_missing_dependency
raise exc
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/migrations/loader.py", line 317, in build_graph
self.graph.add_dependency(migration, key, parent)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/migrations/graph.py", line 116, in add_dependency
parent
django.db.migrations.graph.NodeNotFoundError: Migration sql.0001_initial dependencies reference nonexistent parent node ('auth', '0007_alter_validators_add_error_messages')
[inception@vm_yw_20160927h archer-master]$ python3 manage.py makemigrations sql
Traceback (most recent call last):
File "manage.py", line 10, in
execute_from_command_line(sys.argv)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/core/management/init.py", line 354, in execute_from_command_line
utility.execute()
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/core/management/init.py", line 346, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/core/management/base.py", line 394, in run_from_argv
self.execute(*args, **cmd_options)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/core/management/base.py", line 445, in execute
output = self.handle(*args, **options)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/core/management/commands/makemigrations.py", line 63, in handle
loader = MigrationLoader(None, ignore_no_migrations=True)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/migrations/loader.py", line 47, in init
self.build_graph()
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/migrations/loader.py", line 321, in build_graph
_reraise_missing_dependency(migration, parent, e)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/migrations/loader.py", line 291, in _reraise_missing_dependency
raise exc
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/migrations/loader.py", line 317, in build_graph
self.graph.add_dependency(migration, key, parent)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/migrations/graph.py", line 116, in add_dependency
parent
django.db.migrations.graph.NodeNotFoundError: Migration sql.0001_initial dependencies reference nonexistent parent node ('auth', '0007_alter_validators_add_error_messages')
[inception@vm_yw_20160927h archer-master]$ python3 manage.py migrate
Traceback (most recent call last):
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/backends/utils.py", line 62, in execute
return self.cursor.execute(sql)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/backends/mysql/base.py", line 124, in execute
return self.cursor.execute(query, args)
File "/usr/local/python36/lib/python3.4/site-packages/pymysql/cursors.py", line 166, in execute
result = self._query(query)
File "/usr/local/python36/lib/python3.4/site-packages/pymysql/cursors.py", line 322, in _query
conn.query(q)
File "/usr/local/python36/lib/python3.4/site-packages/pymysql/connections.py", line 852, in query
self._affected_rows = self._read_query_result(unbuffered=unbuffered)
File "/usr/local/python36/lib/python3.4/site-packages/pymysql/connections.py", line 1053, in _read_query_result
result.read()
File "/usr/local/python36/lib/python3.4/site-packages/pymysql/connections.py", line 1337, in read
first_packet = self.connection._read_packet()
File "/usr/local/python36/lib/python3.4/site-packages/pymysql/connections.py", line 1010, in _read_packet
packet.check_error()
File "/usr/local/python36/lib/python3.4/site-packages/pymysql/connections.py", line 393, in check_error
err.raise_mysql_exception(self._data)
File "/usr/local/python36/lib/python3.4/site-packages/pymysql/err.py", line 107, in raise_mysql_exception
raise errorclass(errno, errval)
pymysql.err.ProgrammingError: (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '(6) NOT NULL)' at line 1")
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "manage.py", line 10, in
execute_from_command_line(sys.argv)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/core/management/init.py", line 354, in execute_from_command_line
utility.execute()
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/core/management/init.py", line 346, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/core/management/base.py", line 394, in run_from_argv
self.execute(*args, **cmd_options)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/core/management/base.py", line 445, in execute
output = self.handle(*args, **options)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/core/management/commands/migrate.py", line 93, in handle
executor = MigrationExecutor(connection, self.migration_progress_callback)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/migrations/executor.py", line 19, in init
self.loader = MigrationLoader(self.connection)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/migrations/loader.py", line 47, in init
self.build_graph()
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/migrations/loader.py", line 191, in build_graph
self.applied_migrations = recorder.applied_migrations()
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/migrations/recorder.py", line 59, in applied_migrations
self.ensure_schema()
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/migrations/recorder.py", line 53, in ensure_schema
editor.create_model(self.Migration)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/backends/base/schema.py", line 286, in create_model
self.execute(sql, params or None)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/backends/base/schema.py", line 111, in execute
cursor.execute(sql, params)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/backends/utils.py", line 79, in execute
return super(CursorDebugWrapper, self).execute(sql, params)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/backends/utils.py", line 64, in execute
return self.cursor.execute(sql, params)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/utils.py", line 98, in exit
six.reraise(dj_exc_type, dj_exc_value, traceback)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/utils/six.py", line 685, in reraise
raise value.with_traceback(tb)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/backends/utils.py", line 62, in execute
return self.cursor.execute(sql)
File "/usr/local/python36/lib/python3.4/site-packages/Django-1.8.17-py3.4.egg/django/db/backends/mysql/base.py", line 124, in execute
return self.cursor.execute(query, args)
File "/usr/local/python36/lib/python3.4/site-packages/pymysql/cursors.py", line 166, in execute
result = self._query(query)
File "/usr/local/python36/lib/python3.4/site-packages/pymysql/cursors.py", line 322, in _query
conn.query(q)
File "/usr/local/python36/lib/python3.4/site-packages/pymysql/connections.py", line 852, in query
self._affected_rows = self._read_query_result(unbuffered=unbuffered)
File "/usr/local/python36/lib/python3.4/site-packages/pymysql/connections.py", line 1053, in _read_query_result
result.read()
File "/usr/local/python36/lib/python3.4/site-packages/pymysql/connections.py", line 1337, in read
first_packet = self.connection._read_packet()
File "/usr/local/python36/lib/python3.4/site-packages/pymysql/connections.py", line 1010, in _read_packet
packet.check_error()
File "/usr/local/python36/lib/python3.4/site-packages/pymysql/connections.py", line 393, in check_error
err.raise_mysql_exception(self._data)
File "/usr/local/python36/lib/python3.4/site-packages/pymysql/err.py", line 107, in raise_mysql_exception
raise errorclass(errno, errval)
django.db.utils.ProgrammingError: (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '(6) NOT NULL)' at line 1")
尝试了很久,一直报这个错误
安装部署archer之后一切正常,重启之后在web界面配置主机一直报403,查看各个地方的权限都没解决,希望告知原因
[22/Jan/2018 16:50:30] "GET /admin/sql/master_config/ HTTP/1.1" 403 22
DoesNotExist at /cancel/
users matching query does not exist.
Request Method: POST
Request URL: http://192.168.31.128:9123/cancel/
Django Version: 1.8.17
Exception Type: DoesNotExist
Exception Value:
users matching query does not exist.
Exception Location: /usr/local/python/python3/lib/python3.4/site-packages/django/db/models/query.py in get, line 334
Python Executable: /usr/bin/python
Python Version: 3.4.6
Python Path:
['/opt/archer-master',
'/usr/local/python/python3/lib/python34.zip',
'/usr/local/python/python3/lib/python3.4',
'/usr/local/python/python3/lib/python3.4/plat-linux',
'/usr/local/python/python3/lib/python3.4/lib-dynload',
'/usr/local/python/python3/lib/python3.4/site-packages',
'/usr/local/python/python3/lib/python3.4/site-packages/distribute-0.7.3-py3.4.egg',
'/usr/local/python/python3/lib/python3.4/site-packages/pip-7.1.0-py3.4.egg',
'/usr/local/python/python3/lib/python3.4/site-packages/setuptools-0.6c11-py3.4.egg-info']
Server time: Fri, 30 Jun 2017 00:28:17 +0800
设置脱敏规则和脱敏字段后,查询sql语句中未包含脱敏字段时也进行了脱敏判断。
还有SQL语句如何美化的?
Mysql Error 1146: Table '101_37_23_170_3306_wctest.$$Inception_backup_information$$' doesn't exist
Error: returned listTables more than 1.
这个是什么问题?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.