Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wait for logs to be opened before calling anonymous statistics #5573

Merged
merged 1 commit into from
Mar 8, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
8 changes: 3 additions & 5 deletions daemon/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -960,9 +960,6 @@ int main(int argc, char **argv) {
get_netdata_configured_variables();
set_global_environment();

netdata_anonymous_statistics_enabled=-1;
send_statistics("START","-", "-");

// work while we are cd into config_dir
// to allow the plugins refer to their config
// files using relative filenames
Expand Down Expand Up @@ -995,11 +992,9 @@ int main(int argc, char **argv) {

// --------------------------------------------------------------------
// get log filenames and settings

log_init();
error_log_limit_unlimited();


// --------------------------------------------------------------------
// setup process signals

Expand Down Expand Up @@ -1040,6 +1035,7 @@ int main(int argc, char **argv) {
user = config_get(CONFIG_SECTION_GLOBAL, "run as user", (passwd && passwd->pw_name)?passwd->pw_name:"");
}


// --------------------------------------------------------------------
// create the listening sockets

Expand All @@ -1052,6 +1048,8 @@ int main(int argc, char **argv) {

// initialize the log files
open_all_log_files();
netdata_anonymous_statistics_enabled=-1;
send_statistics("START","-", "-");

#ifdef NETDATA_INTERNAL_CHECKS
if(debug_flags != 0) {
Expand Down