<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=utf-8"><meta name=Generator content="Microsoft Word 15 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:Consolas;
panose-1:2 11 6 9 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri",sans-serif;
color:black;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
pre
{mso-style-priority:99;
mso-style-link:"HTML - wstępnie sformatowany Znak";
margin:0cm;
margin-bottom:.0001pt;
font-size:10.0pt;
font-family:"Courier New";
color:black;}
p.msonormal0, li.msonormal0, div.msonormal0
{mso-style-name:msonormal;
mso-margin-top-alt:auto;
margin-right:0cm;
mso-margin-bottom-alt:auto;
margin-left:0cm;
font-size:11.0pt;
font-family:"Calibri",sans-serif;
color:black;}
span.HTML-wstpniesformatowanyZnak
{mso-style-name:"HTML - wstępnie sformatowany Znak";
mso-style-priority:99;
mso-style-link:"HTML - wstępnie sformatowany";
font-family:"Consolas",serif;
color:black;}
span.Stylwiadomocie-mail21
{mso-style-type:personal-reply;
font-family:"Calibri",sans-serif;
color:windowtext;}
span.tlid-translation
{mso-style-name:tlid-translation;}
.MsoChpDefault
{mso-style-type:export-only;
font-size:10.0pt;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:70.85pt 70.85pt 70.85pt 70.85pt;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body bgcolor=white lang=PL link=blue vlink=purple><div class=WordSection1><p class=MsoNormal><span lang=EN-US style='color:windowtext;mso-fareast-language:EN-US'>Hi everybody,<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:windowtext;mso-fareast-language:EN-US'><o:p> </o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:windowtext;mso-fareast-language:EN-US'>Very interesting thread…<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='color:windowtext;mso-fareast-language:EN-US'>Does the same apply if we only read data from geopackage (not overwrite/edit it) on NFS? I have a situation with deadlocks when several users are only trying to read data (without competitive writing).<o:p></o:p></span></p><p class=MsoNormal><span class=tlid-translation><span lang=EN>Can anyone confirm this with his case?<o:p></o:p></span></span></p><p class=MsoNormal><span class=tlid-translation><span lang=EN><o:p> </o:p></span></span></p><p class=MsoNormal><span class=tlid-translation><span lang=EN>greeting from Poland<o:p></o:p></span></span></p><p class=MsoNormal><span class=tlid-translation><span lang=EN>Jarosław Sadowski<o:p></o:p></span></span></p><p class=MsoNormal><span lang=EN-US style='color:windowtext;mso-fareast-language:EN-US'><o:p> </o:p></span></p><div><div style='border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm'><p class=MsoNormal><b><span style='color:windowtext'>From:</span></b><span style='color:windowtext'> Qgis-user <qgis-user-bounces@lists.osgeo.org> <b>On Behalf Of </b>Jonathan Moules<br><b>Sent:</b> Monday, October 7, 2019 4:17 PM<br><b>To:</b> Tobias Wendorff <tobias.wendorff@tu-dortmund.de>; Andrea Peri <aperi2007@gmail.com><br><b>Cc:</b> qgis-user <qgis-user@lists.osgeo.org>; Paul Wittle <paul.wittle@dorsetcouncil.gov.uk><br><b>Subject:</b> Re: [Qgis-user] GeoPackage deadlocks (Andrea Peri)<o:p></o:p></span></p></div></div><p class=MsoNormal><o:p> </o:p></p><p>(A little late).<o:p></o:p></p><p>TL;DR: at least for QGIS, is - never multi-user edit SQLite/SpatiaLite/GeoPackages on network file systems.<o:p></o:p></p><p>SQLite, (and therefore SpatiaLite and GeoPackage) has quite a few caveats when it comes to multiple users trying to edit it at once. <o:p></o:p></p><p><a href="https://www2.sqlite.org/howtocorrupt.html">https://www2.sqlite.org/howtocorrupt.html</a><o:p></o:p></p><p>(my bold)<o:p></o:p></p><p>"SQLite depends on the underlying filesystem to do locking as the documentation says it will. But some filesystems contain bugs in their locking logic such that the locks do not always behave as advertised. <b>This is especially true of network filesystems and NFS in particular.</b> If SQLite is used on a filesystem where the locking primitives contain bugs, and if two or more threads or processes try to access the same database at the same time, then database corruption might result."<o:p></o:p></p><p>And there's also:<o:p></o:p></p><p><a href="https://www.sqlite.org/whentouse.html">https://www.sqlite.org/whentouse.html</a><o:p></o:p></p><p>Put simply (Note: I'm not an expert): It's fine to edit SQLite databases if they're not on a network file system with as many users as you want, or if they are on a network and you can guarantee only one process is going to write. However if multiple people/processes want to write to a network file system, you'll need a piece of middleware to manage the process, otherwise there's a good chance of corruption as Paul is seeing.<o:p></o:p></p><p>It may also be that QGIS is doing some of the other things on the "how to corrupt" page too. I imagine it will only get worse if you use multiple different software packages to edit simultaneously.<o:p></o:p></p><p>Cheers,<o:p></o:p></p><p>Jonathan<o:p></o:p></p><div><p class=MsoNormal>On 2019-09-27 09:50, Tobias Wendorff wrote:<o:p></o:p></p></div><blockquote style='margin-top:5.0pt;margin-bottom:5.0pt'><blockquote style='margin-top:5.0pt;margin-bottom:5.0pt'><pre>Am 27.09.2019 um 10:24 schrieb Andrea Peri <a href="mailto:aperi2007@gmail.com"><aperi2007@gmail.com></a>:<o:p></o:p></pre><pre><o:p> </o:p></pre><pre>Have you tried to use spatialite instead of geopackage. ?<o:p></o:p></pre></blockquote><pre><o:p> </o:p></pre><pre>Why not plain SQLite? Nobody needs and uses the spatial functions of Spatialite, they are even not part of bloatware GPKG (sorry, the created db-files are huge without any compression).<o:p></o:p></pre><pre><o:p> </o:p></pre><pre>The only reason is indexing and this could be forked off GPGK and Spatialite.<o:p></o:p></pre><pre><o:p> </o:p></pre><pre>To the topic: I think, it‘s always a bad idea to let multiple users work on a single SQLite-based database. It hasn‘t been created for this reason.<o:p></o:p></pre><p class=MsoNormal><br><br><o:p></o:p></p><pre>_______________________________________________<o:p></o:p></pre><pre>Qgis-user mailing list<o:p></o:p></pre><pre><a href="mailto:Qgis-user@lists.osgeo.org">Qgis-user@lists.osgeo.org</a><o:p></o:p></pre><pre>List info: <a href="https://lists.osgeo.org/mailman/listinfo/qgis-user">https://lists.osgeo.org/mailman/listinfo/qgis-user</a><o:p></o:p></pre><pre>Unsubscribe: <a href="https://lists.osgeo.org/mailman/listinfo/qgis-user">https://lists.osgeo.org/mailman/listinfo/qgis-user</a><o:p></o:p></pre></blockquote></div></body></html>