Rsyslog for containers that are destroyed and recreated regularly

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
0
down vote

favorite












We have a fleet of devices running Docker containers. Each container is destroyed and recreated on a regular basis for updates. Programs in the container write logs to a volume that persists between container destroy/create cycles.



I'd like to use rsyslog to send logs in the persistent volume to a log aggregator service, and that part works fine. The problem is that every time we release an update, rsyslog sends the entire contents of the logs, including lines it has already sent.



How can we configure rsyslog to remember what it has sent, maybe in a file inside the persistent volume?



I've done some Googling, read through guides like this, and have skimmed the documentation, and haven't found an obvious solution.










share|improve this question

























    up vote
    0
    down vote

    favorite












    We have a fleet of devices running Docker containers. Each container is destroyed and recreated on a regular basis for updates. Programs in the container write logs to a volume that persists between container destroy/create cycles.



    I'd like to use rsyslog to send logs in the persistent volume to a log aggregator service, and that part works fine. The problem is that every time we release an update, rsyslog sends the entire contents of the logs, including lines it has already sent.



    How can we configure rsyslog to remember what it has sent, maybe in a file inside the persistent volume?



    I've done some Googling, read through guides like this, and have skimmed the documentation, and haven't found an obvious solution.










    share|improve this question























      up vote
      0
      down vote

      favorite









      up vote
      0
      down vote

      favorite











      We have a fleet of devices running Docker containers. Each container is destroyed and recreated on a regular basis for updates. Programs in the container write logs to a volume that persists between container destroy/create cycles.



      I'd like to use rsyslog to send logs in the persistent volume to a log aggregator service, and that part works fine. The problem is that every time we release an update, rsyslog sends the entire contents of the logs, including lines it has already sent.



      How can we configure rsyslog to remember what it has sent, maybe in a file inside the persistent volume?



      I've done some Googling, read through guides like this, and have skimmed the documentation, and haven't found an obvious solution.










      share|improve this question













      We have a fleet of devices running Docker containers. Each container is destroyed and recreated on a regular basis for updates. Programs in the container write logs to a volume that persists between container destroy/create cycles.



      I'd like to use rsyslog to send logs in the persistent volume to a log aggregator service, and that part works fine. The problem is that every time we release an update, rsyslog sends the entire contents of the logs, including lines it has already sent.



      How can we configure rsyslog to remember what it has sent, maybe in a file inside the persistent volume?



      I've done some Googling, read through guides like this, and have skimmed the documentation, and haven't found an obvious solution.







      logs raspbian docker rsyslog containers






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Sep 27 '17 at 0:48









      Sheng Wu

      11




      11

























          active

          oldest

          votes











          Your Answer







          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "106"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          convertImagesToLinks: false,
          noModals: false,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          bindNavPrevention: true,
          postfix: "",
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );













           

          draft saved


          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f394660%2frsyslog-for-containers-that-are-destroyed-and-recreated-regularly%23new-answer', 'question_page');

          );

          Post as a guest



































          active

          oldest

          votes













          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes















           

          draft saved


          draft discarded















































           


          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f394660%2frsyslog-for-containers-that-are-destroyed-and-recreated-regularly%23new-answer', 'question_page');

          );

          Post as a guest













































































          Popular posts from this blog

          Peggy Mitchell

          Palaiologos

          The Forum (Inglewood, California)