From: Victor Julien Date: Fri, 3 Jun 2016 07:45:23 +0000 (+0200) Subject: output: reduce verbosity on info level X-Git-Tag: suricata-3.1RC1~18 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2aac437927010dd5ccdd4a2f07ada0744c21a113;p=thirdparty%2Fsuricata.git output: reduce verbosity on info level --- diff --git a/src/output-json-file.c b/src/output-json-file.c index c4a7f5276b..a06628225a 100644 --- a/src/output-json-file.c +++ b/src/output-json-file.c @@ -261,20 +261,20 @@ OutputCtx *OutputFileLogInitSub(ConfNode *conf, OutputCtx *parent_ctx) const char *force_filestore = ConfNodeLookupChildValue(conf, "force-filestore"); if (force_filestore != NULL && ConfValIsTrue(force_filestore)) { FileForceFilestoreEnable(); - SCLogInfo("forcing filestore of all files"); + SCLogConfig("forcing filestore of all files"); } const char *force_magic = ConfNodeLookupChildValue(conf, "force-magic"); if (force_magic != NULL && ConfValIsTrue(force_magic)) { FileForceMagicEnable(); - SCLogInfo("forcing magic lookup for logged files"); + SCLogConfig("forcing magic lookup for logged files"); } const char *force_md5 = ConfNodeLookupChildValue(conf, "force-md5"); if (force_md5 != NULL && ConfValIsTrue(force_md5)) { #ifdef HAVE_NSS FileForceMd5Enable(); - SCLogInfo("forcing md5 calculation for logged files"); + SCLogConfig("forcing md5 calculation for logged files"); #else SCLogInfo("md5 calculation requires linking against libnss"); #endif diff --git a/src/util-coredump-config.c b/src/util-coredump-config.c index 2115f930fb..9555e0fd71 100644 --- a/src/util-coredump-config.c +++ b/src/util-coredump-config.c @@ -112,14 +112,14 @@ int32_t CoredumpLoadConfig (void) if (unlimited) { /* we want no limit on coredump size */ if (lim.rlim_max == RLIM_INFINITY && lim.rlim_cur == RLIM_INFINITY) { - SCLogInfo ("Core dump size is unlimited."); + SCLogConfig ("Core dump size is unlimited."); return 1; } else { new_lim.rlim_max = RLIM_INFINITY; new_lim.rlim_cur = RLIM_INFINITY; if (setrlimit (RLIMIT_CORE, &new_lim) == 0) { - SCLogInfo ("Core dump size set to unlimited."); + SCLogConfig ("Core dump size set to unlimited."); return 1; } if (errno == EPERM) { @@ -169,7 +169,7 @@ int32_t CoredumpLoadConfig (void) struct rlimit actual_lim; if (getrlimit (RLIMIT_CORE, &actual_lim) == 0) { if (actual_lim.rlim_cur == RLIM_INFINITY) { - SCLogInfo ("Core dump size set to unlimited."); + SCLogConfig ("Core dump size set to unlimited."); } #ifdef RLIM_SAVED_CUR else if (actual_lim.rlim_cur == RLIM_SAVED_CUR) { diff --git a/src/util-device.c b/src/util-device.c index a4e634ee0c..409f8732cc 100644 --- a/src/util-device.c +++ b/src/util-device.c @@ -214,7 +214,7 @@ int LiveBuildDeviceListCustom(const char *runmode, const char *itemname) if ((!strcmp(subchild->name, itemname))) { if (!strcmp(subchild->val, "default")) break; - SCLogInfo("Adding %s %s from config file", + SCLogConfig("Adding %s %s from config file", itemname, subchild->val); LiveRegisterDevice(subchild->val); i++; diff --git a/src/util-magic.c b/src/util-magic.c index 5d8615b182..679545751f 100644 --- a/src/util-magic.c +++ b/src/util-magic.c @@ -53,7 +53,8 @@ int MagicInit(void) g_magic_ctx = magic_open(0); if (g_magic_ctx == NULL) { - SCLogError(SC_ERR_MAGIC_OPEN, "magic_open failed: %s", magic_error(g_magic_ctx)); + SCLogError(SC_ERR_MAGIC_OPEN, "magic_open failed: %s", + magic_error(g_magic_ctx)); goto error; } @@ -62,15 +63,17 @@ int MagicInit(void) if (filename != NULL) { if (strlen(filename) == 0) { - /* set filename to NULL on *nix systems so magic_load uses system default path (see man libmagic) */ - SCLogInfo("using system default magic-file"); + /* set filename to NULL on *nix systems so magic_load uses system + * default path (see man libmagic) */ + SCLogConfig("using system default magic-file"); filename = NULL; } else { - SCLogInfo("using magic-file %s", filename); + SCLogConfig("using magic-file %s", filename); if ( (fd = fopen(filename, "r")) == NULL) { - SCLogWarning(SC_ERR_FOPEN, "Error opening file: \"%s\": %s", filename, strerror(errno)); + SCLogWarning(SC_ERR_FOPEN, "Error opening file: \"%s\": %s", + filename, strerror(errno)); goto error; } fclose(fd); @@ -78,7 +81,8 @@ int MagicInit(void) } if (magic_load(g_magic_ctx, filename) != 0) { - SCLogError(SC_ERR_MAGIC_LOAD, "magic_load failed: %s", magic_error(g_magic_ctx)); + SCLogError(SC_ERR_MAGIC_LOAD, "magic_load failed: %s", + magic_error(g_magic_ctx)); goto error; } diff --git a/src/util-mpm-hs.c b/src/util-mpm-hs.c index 61a6c4cf89..43e74d3142 100644 --- a/src/util-mpm-hs.c +++ b/src/util-mpm-hs.c @@ -1063,7 +1063,7 @@ void MpmHSGlobalCleanup(void) { SCMutexLock(&g_scratch_proto_mutex); if (g_scratch_proto) { - SCLogInfo("Cleaning up Hyperscan global scratch"); + SCLogPerf("Cleaning up Hyperscan global scratch"); hs_free_scratch(g_scratch_proto); g_scratch_proto = NULL; } @@ -1071,7 +1071,7 @@ void MpmHSGlobalCleanup(void) SCMutexLock(&g_db_table_mutex); if (g_db_table != NULL) { - SCLogInfo("Clearing Hyperscan database cache"); + SCLogPerf("Clearing Hyperscan database cache"); HashTableFree(g_db_table); g_db_table = NULL; }