<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <p>Hi Bo,</p>
    <p>Looking at the WAL docs for SQLite
      (<a class="moz-txt-link-freetext" href="https://www.sqlite.org/wal.html">https://www.sqlite.org/wal.html</a>) (what geopackage is built from)
      I see this:</p>
    <p>"The WAL file exists for as long as any database connection has
      the database open. Usually, the WAL file is deleted automatically
      when the last connection to the database closes. However, if the
      last process to have the database open exits without cleanly
      shutting down the database connection, or if the
      SQLITE_FCNTL_PERSIST_WAL file control is used, then the WAL file
      might be retained on disk after all connections to the database
      have been closed."</p>
    <p>So it sounds like whatever the last process is to touch the
      GeoPackage may not be closing the connection cleanly on exFat.</p>
    <p>Cheers,</p>
    <p>Jonathan<br>
    </p>
    <div class="moz-cite-prefix">On 2020-05-11 13:10, Bo Victor Thomsen
      wrote:<br>
    </div>
    <blockquote type="cite"
      cite="mid:dff03255-2f20-d875-5474-15485b099714@gmail.com">
      <p>Hi all -</p>
      <p>I have a strange problem. I'm have 3 different disk on my
        windows based system on Mac hardware<br>
      </p>
      <ol>
        <li>My system drive. Formatted to NTFS.</li>
        <li>A flash-drive. Formatted to FAT32.</li>
        <li>A data drive. Formatted to exFAT. The last is my primary
          data drive and is shared between my Windows partition and my
          Mac partition on my MacBook Pro. Hence the use of exFAT.<br>
        </li>
      </ol>
      <p>I have a QGIS plugin, which copies a template of a GeoPackage
        file to "where-ever the user wants it placed" and afterward make
        some content changes in the copy using the PyQT QSQL module with
        the QSPATIALITE driver<br>
      </p>
      <p>This work if the Geopackage  file is copied to either disk no 1
        (NTFS) or disk no 2 (FAT32). However, it doesn't work if the
        file is copied to disk no 3 (exFAT). The process leaves the WAL
        files even after the database is closed properly. <br>
      </p>
      <p>And even more strange: If I reformat the flash-drive to exFAT
        and repeat the experiment using the reformatted drive it too
        works without a hitch.</p>
      <p>The normal "divide et impera" method tells me that my exFat
        data disk is bork'ed. However this error <b>only</b> occurs
        with the QGIS/GeoPackage creation/modification scenario.
        Everything else is working OK.<br>
      </p>
      <p>The disk is not shared on the network. Has anyone experienced
        the same type of problems ? And have a solution ?? Just asking
        before I begin to clean up / reformat my 100 GB data disk <br>
      </p>
      <p>System setup: MacBook Pro 2014 / Windows 8.1 OS /QGIS 3.10.5
        (the same problem occurs with 3.10.0 , 3.10.2 ...3.12.2) <br>
      </p>
      <p> <br>
      </p>
      --
      <pre class="moz-signature" cols="72">Med venlig hilsen / Kind regards

Bo Victor Thomsen
</pre>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <pre class="moz-quote-pre" wrap="">_______________________________________________
QGIS-Developer mailing list
<a class="moz-txt-link-abbreviated" href="mailto:QGIS-Developer@lists.osgeo.org">QGIS-Developer@lists.osgeo.org</a>
List info: <a class="moz-txt-link-freetext" href="https://lists.osgeo.org/mailman/listinfo/qgis-developer">https://lists.osgeo.org/mailman/listinfo/qgis-developer</a>
Unsubscribe: <a class="moz-txt-link-freetext" href="https://lists.osgeo.org/mailman/listinfo/qgis-developer">https://lists.osgeo.org/mailman/listinfo/qgis-developer</a></pre>
    </blockquote>
  </body>
</html>