]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
Take into account q_quiet when determing loglevel and change a few 10474/head
authorOtto <otto.moerbeek@open-xchange.com>
Wed, 12 May 2021 10:46:44 +0000 (12:46 +0200)
committerOtto <otto.moerbeek@open-xchange.com>
Mon, 7 Jun 2021 07:12:43 +0000 (09:12 +0200)
loglevels.

(cherry picked from commit cf02f990a7fb9398aa4b13373c7ae35f7d2d47e3)

pdns/pdns_recursor.cc
pdns/syncres.cc

index a31c47d413247f19ec626d1822a3d3b57fb74444..2c4f2f148f00421394f82b91c1b689ddf5be75cf 100644 (file)
@@ -4004,7 +4004,7 @@ static void handleRCC(int fd, FDMultiplexer::funcparam_t& var)
     RecursorControlParser rcp;
     RecursorControlParser::func_t* command;
 
-    g_log << Logger::Notice << "Received rec_control command '" << msg << "' from control socket" << endl;
+    g_log << Logger::Info << "Received rec_control command '" << msg << "' from control socket" << endl;
     auto answer = rcp.getAnswer(fd, msg, &command);
 
     // If we are inside a chroot, we need to strip
@@ -4666,8 +4666,6 @@ static int serviceMain(int argc, char*argv[])
     g_log<<Logger::Warning<<endl;
   }
 
-  g_quiet=::arg().mustDo("quiet");
-
   /* this needs to be done before parseACLs(), which call broadcastFunction() */
   g_weDistributeQueries = ::arg().mustDo("pdns-distributes-queries");
   if(g_weDistributeQueries) {
@@ -5745,6 +5743,7 @@ int main(int argc, char **argv)
     g_recCache = std::unique_ptr<MemRecursorCache>(new MemRecursorCache(::arg().asNum("record-cache-shards")));
     g_negCache = std::unique_ptr<NegCache>(new NegCache(::arg().asNum("record-cache-shards")));
 
+    g_quiet=::arg().mustDo("quiet");
     Logger::Urgency logUrgency = (Logger::Urgency)::arg().asNum("loglevel");
 
     if (logUrgency < Logger::Error)
index 8cfed6f1faaff1b367a89bdfc0fd5f8b303e8173..dc8e9d22db6f8ffef5f266715d6d08e602b059aa 100644 (file)
@@ -4421,7 +4421,7 @@ int SyncRes::getRootNS(struct timeval now, asyncresolve_t asyncCallback, unsigne
     g_log<<Logger::Notice<<"Refreshed . records"<<endl;
   }
   else
-    g_log<<Logger::Error<<"Failed to update . records, RCODE="<<res<<endl;
+    g_log<<Logger::Warning<<"Failed to update . records, RCODE="<<res<<endl;
 
   return res;
 }