美文网首页
MySQL:版本后-log代表什么

MySQL:版本后-log代表什么

作者: 重庆八怪 | 来源:发表于2021-09-24 11:07 被阅读0次
static void set_server_version(void)
{
  char *end= strxmov(server_version, MYSQL_SERVER_VERSION,
                     MYSQL_SERVER_SUFFIX_STR, NullS);
#ifdef EMBEDDED_LIBRARY
  end= my_stpcpy(end, "-embedded");
#endif
#ifndef DBUG_OFF
  if (!strstr(MYSQL_SERVER_SUFFIX_STR, "-debug"))
    end= my_stpcpy(end, "-debug");
#endif
  if (opt_general_log || opt_slow_log || opt_bin_log)
    end= my_stpcpy(end, "-log");          // This may slow down system
#ifdef HAVE_VALGRIND
  if (SERVER_VERSION_LENGTH - (end - server_version) >
      static_cast<int>(sizeof("-valgrind")))
    end= my_stpcpy(end, "-valgrind"); 
#endif
#ifdef HAVE_ASAN
  if (SERVER_VERSION_LENGTH - (end - server_version) >
      static_cast<int>(sizeof("-asan")))
    end= my_stpcpy(end, "-asan");
#endif
}

就代表你开了gernal log/慢查询/binlog 至少其中一种

相关文章

网友评论

      本文标题:MySQL:版本后-log代表什么

      本文链接:https://www.haomeiwen.com/subject/nkfzgltx.html