title: Exporting old logs efficiently
body: <p>As part of cloud migration effort, in order establish an archive of old logs, I'd like to export all existing logs from Stackdriver.</p>
  
  <p>I know it is possible to export old logs via <a href="https://cloud.google.com/logging/docs/reference/v2/rest/v2/entries/list" rel="nofollow noreferrer"><code>entries.list</code></a> as noted in the <a href="https://cloud.google.com/logging/docs/export/configure_export_v2#general_problems" rel="nofollow noreferrer">documentation</a>:</p>
  
  <blockquote>
    <p>Use the entries.list API method to retrieve your older log entries and use the destination service's API to write the log entries to the export destination.</p>
  </blockquote>
  
  <p>It appears that <code>gcloud logging read</code> relies on exactly this call, so I can pull all my logs via the following command:</p>
  
  <pre><code>gcloud logging read "logName=projects/my-project/logs/my-entity" --order asc | pv &gt; production-my-entity.logs
  </code></pre>
  
  <p>However, this is <strong>super slow</strong>.</p>
  
  <p>Is there a way to download older logs faster, like in bulk or something?</p>