Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
哥们要飞
TDengine
提交
b8c6d6c0
T
TDengine
项目概览
哥们要飞
/
TDengine
与 Fork 源项目一致
Fork自
taosdata / TDengine
通知
1
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
T
TDengine
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
b8c6d6c0
编写于
5月 08, 2020
作者:
guanshengliang
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
failed to get bandwidth
上级
b50d04ef
变更
17
隐藏空白更改
内联
并排
Showing
17 changed file
with
34 addition
and
49 deletion
+34
-49
src/mnode/inc/mgmtInt.h
src/mnode/inc/mgmtInt.h
+8
-28
src/mnode/src/mgmtAcct.c
src/mnode/src/mgmtAcct.c
+1
-1
src/mnode/src/mgmtBalance.c
src/mnode/src/mgmtBalance.c
+1
-1
src/mnode/src/mgmtDb.c
src/mnode/src/mgmtDb.c
+1
-1
src/mnode/src/mgmtDnode.c
src/mnode/src/mgmtDnode.c
+1
-1
src/mnode/src/mgmtGrant.c
src/mnode/src/mgmtGrant.c
+1
-1
src/mnode/src/mgmtMain.c
src/mnode/src/mgmtMain.c
+1
-1
src/mnode/src/mgmtMnode.c
src/mnode/src/mgmtMnode.c
+1
-1
src/mnode/src/mgmtProfile.c
src/mnode/src/mgmtProfile.c
+1
-1
src/mnode/src/mgmtSdb.c
src/mnode/src/mgmtSdb.c
+1
-1
src/mnode/src/mgmtServer.c
src/mnode/src/mgmtServer.c
+1
-1
src/mnode/src/mgmtShell.c
src/mnode/src/mgmtShell.c
+1
-1
src/mnode/src/mgmtTable.c
src/mnode/src/mgmtTable.c
+1
-1
src/mnode/src/mgmtUser.c
src/mnode/src/mgmtUser.c
+1
-1
src/mnode/src/mgmtVgroup.c
src/mnode/src/mgmtVgroup.c
+1
-1
src/os/linux/src/linuxSysPara.c
src/os/linux/src/linuxSysPara.c
+8
-3
src/plugins/monitor/src/monitorMain.c
src/plugins/monitor/src/monitorMain.c
+4
-4
未找到文件。
src/mnode/inc/mgmt
Log
.h
→
src/mnode/inc/mgmt
Int
.h
浏览文件 @
b8c6d6c0
...
...
@@ -27,39 +27,19 @@ extern int32_t mdebugFlag;
extern
int32_t
sdbDebugFlag
;
// mnode log function
#define mError(...) \
if (mdebugFlag & DEBUG_ERROR) { \
taosPrintLog("ERROR MND ", 255, __VA_ARGS__); \
}
#define mWarn(...) \
if (mdebugFlag & DEBUG_WARN) { \
taosPrintLog("WARN MND ", mdebugFlag, __VA_ARGS__); \
}
#define mTrace(...) \
if (mdebugFlag & DEBUG_TRACE) { \
taosPrintLog("MND ", mdebugFlag, __VA_ARGS__); \
}
#define mPrint(...) \
{ taosPrintLog("MND ", 255, __VA_ARGS__); }
#define mError(...) if (mdebugFlag & DEBUG_ERROR) { taosPrintLog("ERROR MND ", 255, __VA_ARGS__); }
#define mWarn(...) if (mdebugFlag & DEBUG_WARN) { taosPrintLog("WARN MND ", mdebugFlag, __VA_ARGS__); }
#define mTrace(...) if (mdebugFlag & DEBUG_TRACE) { taosPrintLog("MND ", mdebugFlag, __VA_ARGS__); }
#define mPrint(...) { taosPrintLog("MND ", 255, __VA_ARGS__); }
#define mLError(...) monitorSaveLog(2, __VA_ARGS__); mError(__VA_ARGS__)
#define mLWarn(...) monitorSaveLog(1, __VA_ARGS__); mWarn(__VA_ARGS__)
#define mLPrint(...) monitorSaveLog(0, __VA_ARGS__); mPrint(__VA_ARGS__)
#define sdbError(...) \
if (sdbDebugFlag & DEBUG_ERROR) { \
taosPrintLog("ERROR MND-SDB ", 255, __VA_ARGS__); \
}
#define sdbWarn(...) \
if (sdbDebugFlag & DEBUG_WARN) { \
taosPrintLog("WARN MND-SDB ", sdbDebugFlag, __VA_ARGS__); \
}
#define sdbTrace(...) \
if (sdbDebugFlag & DEBUG_TRACE) { \
taosPrintLog("MND-SDB ", sdbDebugFlag, __VA_ARGS__); \
}
#define sdbPrint(...) \
{ taosPrintLog("MND-SDB ", 255, __VA_ARGS__); }
#define sdbError(...) if (sdbDebugFlag & DEBUG_ERROR) { taosPrintLog("ERROR MND-SDB ", 255, __VA_ARGS__); }
#define sdbWarn(...) if (sdbDebugFlag & DEBUG_WARN) { taosPrintLog("WARN MND-SDB ", sdbDebugFlag, __VA_ARGS__); }
#define sdbTrace(...) if (sdbDebugFlag & DEBUG_TRACE) { taosPrintLog("MND-SDB ", sdbDebugFlag, __VA_ARGS__);}
#define sdbPrint(...) { taosPrintLog("MND-SDB ", 255, __VA_ARGS__); }
#define sdbLError(...) monitorSaveLog(2, __VA_ARGS__); sdbError(__VA_ARGS__)
#define sdbLWarn(...) monitorSaveLog(1, __VA_ARGS__); sdbWarn(__VA_ARGS__)
...
...
src/mnode/src/mgmtAcct.c
浏览文件 @
b8c6d6c0
...
...
@@ -20,7 +20,7 @@
#include "tutil.h"
#include "dnode.h"
#include "mgmtDef.h"
#include "mgmt
Log
.h"
#include "mgmt
Int
.h"
#include "mgmtAcct.h"
#include "mgmtDb.h"
#include "mgmtSdb.h"
...
...
src/mnode/src/mgmtBalance.c
浏览文件 @
b8c6d6c0
...
...
@@ -19,7 +19,7 @@
#include "tbalance.h"
#include "tglobal.h"
#include "mgmtDef.h"
#include "mgmt
Log
.h"
#include "mgmt
Int
.h"
#include "mgmtMnode.h"
#include "mgmtDnode.h"
#include "mgmtVgroup.h"
...
...
src/mnode/src/mgmtDb.c
浏览文件 @
b8c6d6c0
...
...
@@ -25,7 +25,7 @@
#include "tbalance.h"
#include "tdataformat.h"
#include "mgmtDef.h"
#include "mgmt
Log
.h"
#include "mgmt
Int
.h"
#include "mgmtAcct.h"
#include "mgmtDb.h"
#include "mgmtDnode.h"
...
...
src/mnode/src/mgmtDnode.c
浏览文件 @
b8c6d6c0
...
...
@@ -27,7 +27,7 @@
#include "tdataformat.h"
#include "dnode.h"
#include "mgmtDef.h"
#include "mgmt
Log
.h"
#include "mgmt
Int
.h"
#include "mgmtDnode.h"
#include "mgmtMnode.h"
#include "mgmtSdb.h"
...
...
src/mnode/src/mgmtGrant.c
浏览文件 @
b8c6d6c0
...
...
@@ -18,7 +18,7 @@
#include "os.h"
#include "taoserror.h"
#include "tgrant.h"
#include "mgmt
Log
.h"
#include "mgmt
Int
.h"
int32_t
grantInit
()
{
return
TSDB_CODE_SUCCESS
;
}
void
grantCleanUp
()
{}
...
...
src/mnode/src/mgmtMain.c
浏览文件 @
b8c6d6c0
...
...
@@ -23,7 +23,7 @@
#include "tglobal.h"
#include "dnode.h"
#include "mgmtDef.h"
#include "mgmt
Log
.h"
#include "mgmt
Int
.h"
#include "mgmtServer.h"
#include "mgmtAcct.h"
#include "mgmtDnode.h"
...
...
src/mnode/src/mgmtMnode.c
浏览文件 @
b8c6d6c0
...
...
@@ -24,7 +24,7 @@
#include "tsocket.h"
#include "tdataformat.h"
#include "mgmtDef.h"
#include "mgmt
Log
.h"
#include "mgmt
Int
.h"
#include "mgmtMnode.h"
#include "mgmtDnode.h"
#include "mgmtSdb.h"
...
...
src/mnode/src/mgmtProfile.c
浏览文件 @
b8c6d6c0
...
...
@@ -19,7 +19,7 @@
#include "taoserror.h"
#include "tutil.h"
#include "mgmtDef.h"
#include "mgmt
Log
.h"
#include "mgmt
Int
.h"
#include "mgmtAcct.h"
#include "mgmtDnode.h"
#include "mgmtDb.h"
...
...
src/mnode/src/mgmtSdb.c
浏览文件 @
b8c6d6c0
...
...
@@ -27,7 +27,7 @@
#include "hashstr.h"
#include "dnode.h"
#include "mgmtDef.h"
#include "mgmt
Log
.h"
#include "mgmt
Int
.h"
#include "mgmtMnode.h"
#include "mgmtSdb.h"
...
...
src/mnode/src/mgmtServer.c
浏览文件 @
b8c6d6c0
...
...
@@ -25,7 +25,7 @@
#include "tglobal.h"
#include "dnode.h"
#include "mgmtDef.h"
#include "mgmt
Log
.h"
#include "mgmt
Int
.h"
#include "mgmtDb.h"
#include "mgmtMnode.h"
#include "mgmtProfile.h"
...
...
src/mnode/src/mgmtShell.c
浏览文件 @
b8c6d6c0
...
...
@@ -26,7 +26,7 @@
#include "tcache.h"
#include "dnode.h"
#include "mgmtDef.h"
#include "mgmt
Log
.h"
#include "mgmt
Int
.h"
#include "mgmtAcct.h"
#include "mgmtDb.h"
#include "mgmtDnode.h"
...
...
src/mnode/src/mgmtTable.c
浏览文件 @
b8c6d6c0
...
...
@@ -26,7 +26,7 @@
#include "tglobal.h"
#include "dnode.h"
#include "mgmtDef.h"
#include "mgmt
Log
.h"
#include "mgmt
Int
.h"
#include "mgmtAcct.h"
#include "mgmtDb.h"
#include "mgmtDnode.h"
...
...
src/mnode/src/mgmtUser.c
浏览文件 @
b8c6d6c0
...
...
@@ -23,7 +23,7 @@
#include "tdataformat.h"
#include "dnode.h"
#include "mgmtDef.h"
#include "mgmt
Log
.h"
#include "mgmt
Int
.h"
#include "mgmtAcct.h"
#include "mgmtMnode.h"
#include "mgmtSdb.h"
...
...
src/mnode/src/mgmtVgroup.c
浏览文件 @
b8c6d6c0
...
...
@@ -26,7 +26,7 @@
#include "dnode.h"
#include "tdataformat.h"
#include "mgmtDef.h"
#include "mgmt
Log
.h"
#include "mgmt
Int
.h"
#include "mgmtDb.h"
#include "mgmtDnode.h"
#include "mgmtMnode.h"
...
...
src/os/linux/src/linuxSysPara.c
浏览文件 @
b8c6d6c0
...
...
@@ -356,10 +356,15 @@ static bool taosGetCardName(char *ip, char *name) {
break
;
}
if
(
strcmp
(
host
,
ip
)
==
0
)
{
strcpy
(
name
,
ifa
->
ifa_name
);
ret
=
true
;
if
(
strcmp
(
host
,
"127.0.0.1"
)
==
0
)
{
continue
;
}
// TODO: the ip not config
// if (strcmp(host, ip) == 0) {
strcpy
(
name
,
ifa
->
ifa_name
);
ret
=
true
;
// }
}
freeifaddrs
(
ifaddr
);
...
...
src/plugins/monitor/src/monitorMain.c
浏览文件 @
b8c6d6c0
...
...
@@ -43,7 +43,7 @@
{ taosPrintLog("MON ", 255, __VA_ARGS__); }
#define SQL_LENGTH 1024
#define LOG_LEN_STR
8
0
#define LOG_LEN_STR
10
0
#define IP_LEN_STR 18
#define CHECK_INTERVAL 1000
...
...
@@ -148,8 +148,8 @@ static void dnodeBuildMonitorSql(char *sql, int32_t cmd) {
if
(
cmd
==
MONITOR_CMD_CREATE_DB
)
{
snprintf
(
sql
,
SQL_LENGTH
,
"create database if not exists %s replica 1 days 10 keep 30 cache
2
"
"blocks 2 maxtables
32
precision 'us'"
,
"create database if not exists %s replica 1 days 10 keep 30 cache
1
"
"blocks 2 maxtables
16
precision 'us'"
,
tsMonitorDbName
);
}
else
if
(
cmd
==
MONITOR_CMD_CREATE_MT_DN
)
{
snprintf
(
sql
,
SQL_LENGTH
,
...
...
@@ -407,7 +407,7 @@ void monitorSaveLog(int32_t level, const char *const format, ...) {
if
(
tsMonitorConn
.
state
!=
MONITOR_STATE_INITIALIZED
)
return
;
int32_t
len
=
snprintf
(
sql
,
(
size_t
)
max_length
,
"i
mpo
rt into %s.log values(%"
PRId64
", %d,'"
,
tsMonitorDbName
,
int32_t
len
=
snprintf
(
sql
,
(
size_t
)
max_length
,
"i
nse
rt into %s.log values(%"
PRId64
", %d,'"
,
tsMonitorDbName
,
taosGetTimestampUs
(),
level
);
va_start
(
argpointer
,
format
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录