AKSW / OntoWiki

Semantic data wiki as well as Linked Data publishing engine
https://ontowiki.net
205 stars 51 forks source link

Exporting KB #75

Open amrapalijz opened 12 years ago

amrapalijz commented 12 years ago

When I click on "Export Knowledge Base as RDF/XML", for large knowledge bases ie above 100,000 triples, it does not export any file and shows a Page not found error.

seebi commented 12 years ago

Amrapali, is your debug mode on? can you turn it on an paste the error message as well as the the last lines or the error.log in logs here? most likely, php needs more memory ... in the meantime, please export with virtuoso directly.

0xfeedface commented 12 years ago

The store is unfortunately Zend_Db based and we have no direct export script for that. :\

amrapalijz commented 12 years ago

Ok, will paste the error message and from the log too. In the meanwhile, we used the ontowiki client to try to export the knowledge base and it gave the following error: "The server response was no valid json: Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 703357 bytes) in /var/www/OntoWiki/libraries/Erfurt/Erfurt/Cache/Backend/QueryCache/Database.php on line 181"

white-gecko commented 12 years ago

Your maximum memory is set to 256 MB did you try to increase it?

frodeseverin commented 12 years ago

I have a similar problem with Virtuoso backend. I get the following error:

SPARQL Error: [unixODBC][OpenLink][Virtuoso iODBC Driver][Virtuoso Server]SR353: Sorted TOP clause specifies more then 11000 rows to sort. Only 10000 are allowed. Either decrease the offset and/or row count or use a scrollable cursor () in query: define output:format "JSON" SELECT ?resourceUri ?p ?o FROM http://data.bergenbibliotek.no/data/ WHERE { ?resourceUri ?p ?o . } ORDER BY ?resourceUri LIMIT 1000 OFFSET 10000

Full error dump follows.

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>OntoWiki Error</title>
<style type="text/css">
body {
    font-family: sans-serif;
    line-height: 1.5;
    background-color: #eff9ff;
}

.info {
    margin: 0.5% 10%;
    border: 1px solid #aaa;
    padding: 1%;
    background-color: #f9f9f9;
}

.error {
    margin: 0.5% 10%;
    border: 1px solid #f00;
    padding: 1%;
    background-color: #fcc;
}
</style>
</head>
<body>
<div class="error">
<h1>OntoWiki Error</h1>
<details>
<summary>SPARQL Error: [unixODBC][OpenLink][Virtuoso iODBC Driver][Virtuoso Server]SR353: Sorted TOP clause specifies more then 11000 rows to sort. Only 10000 are allowed. Either decrease the offset and/or row count or use a scrollable cursor () in query: define output:format &quot;JSON&quot;
SELECT ?resourceUri ?p ?o
FROM &lt;http://data.bergenbibliotek.no/data/&gt;
WHERE { ?resourceUri ?p ?o . } ORDER BY ?resourceUri
LIMIT 1000
OFFSET 10000
</summary>
<p><code>Erfurt_Store_Adapter_Exception</code></p>
<p>
<code>/usr/share/OntoWiki/libraries/Erfurt/library/Erfurt/Store/Adapter/Virtuoso.php@993</code>
<br/ ><code>#0: Erfurt_Store_Adapter_Virtuoso->_execSparql@/usr/share/OntoWiki/libraries/Erfurt/library/Erfurt/Store/Adapter/Virtuoso.php:659<br />#1: Erfurt_Store_Adapter_Virtuoso->sparqlQuery@/usr/share/OntoWiki/libraries/Erfurt/library/Erfurt/Store.php:1403<br />#2: Erfurt_Store->sparqlQuery@/usr/share/OntoWiki/libraries/Erfurt/library/Erfurt/Syntax/RdfSerializer/Adapter/Turtle.php:77<br />#3: Erfurt_Syntax_RdfSerializer_Adapter_Turtle->serializeQueryResultToString@/usr/share/OntoWiki/libraries/Erfurt/library/Erfurt/Syntax/RdfSerializer/Adapter/Turtle.php:108<br />#4: Erfurt_Syntax_RdfSerializer_Adapter_Turtle->serializeGraphToString@/usr/share/OntoWiki/libraries/Erfurt/library/Erfurt/Syntax/RdfSerializer.php:95<br />#5: Erfurt_Syntax_RdfSerializer->serializeGraphToString@/usr/share/OntoWiki/application/controllers/ModelController.php:893<br />#6: ModelController->exportAction@/usr/share/OntoWiki/libraries/Zend/Controller/Action.php:513<br />#7: Zend_Controller_Action->dispatch@/usr/share/OntoWiki/libraries/Zend/Controller/Dispatcher/Standard.php:295<br />#8: Zend_Controller_Dispatcher_Standard->dispatch@/usr/share/OntoWiki/libraries/Zend/Controller/Front.php:954<br />#9: Zend_Controller_Front->dispatch@/usr/share/OntoWiki/libraries/Zend/Application/Bootstrap/Bootstrap.php:97<br />#10: Zend_Application_Bootstrap_Bootstrap->run@/usr/share/OntoWiki/libraries/Zend/Application.php:366<br />#11: Zend_Application->run@/usr/share/OntoWiki/index.php:175<br /></code>
</p>
</details>
<p>
     <a href="http://data.bergenbibliotek.no/index.php/model/info/?m=http%3A%2F%2Fdata.bergenbibliotek.no%2Fdata%2F">back</a>&nbsp;
<a href="http://data.bergenbibliotek.no/index.php/">home</a>
</p>
</div>
</body>
</html>
shinobu commented 8 years ago

while trying to reproduce this issue, I got unexpected errors: after creating a graph in ontowiki und uploading the data through isql-vt, i can browse through the classes without problems. But if i try to export per rdf/xml i only get a basicly empty xml file and the other options throw file not found errors ->XML output <!-- Exported with the Erfurt API - http://aksw.org/Projects/Erfurt --><rdf:RDF xml:base="http://large_test.com"><!-- Ontology specific informations --> <ns2:Ontology rdf:about="http://large_test.com" rdfs:label="large"/></rdf:RDF>

i will look if i get the same error if i upload the data through the web interface (though this might take a while to upload)

white-gecko commented 8 years ago

Could you please try it with a smaller, better to handle graph? E.g. ttl export from http://aksw.org/

Am 22. Mai 2016 16:06:03 MESZ, schrieb shinobu notifications@github.com:

while trying to reproduce this issue, I got unexpected errors: after creating a graph in ontowiki und uploading the data through isql-vt, i can browse through the classes without problems. But if i try to export per rdf/xml i only get a basicly empty xml file and the other options throw file not found errors ->XML output <!-- Exported with the Erfurt API - http://aksw.org/Projects/Erfurt --><rdf:RDF xml:base="http://large_test.com"><!-- Ontology specific informations --> <ns2:Ontology rdf:about="http://large_test.com" rdfs:label="large"/></rdf:RDF>

i will look if i get the same error if i upload the data through the web interface (though this might take a while to upload)


You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/AKSW/OntoWiki/issues/75#issuecomment-220834263

Diese Nachricht wurde von meinem Mobiltelefon mit Linux Kernel und JVM Userland von K-9 Mail gesendet.

shinobu commented 8 years ago

i seem to be unable to reach the OntoWiki store for aksw http://master.demo.ontowiki.eu/ throws an error if i try to visit it and should i try the isql upload with the aksw graph or the usual web-interface upload?

white-gecko commented 8 years ago

Try http://aksw.org/Index, there you should have the usual menus.

Am 22. Mai 2016 16:58:16 MESZ, schrieb shinobu notifications@github.com:

i seem to be unable to reach the OntoWiki store for aksw http://master.demo.ontowiki.eu/ throws an error if i try to visit it and should i try the isql upload with the aksw graph or the usual web-interface upload?


You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/AKSW/OntoWiki/issues/75#issuecomment-220836789

Diese Nachricht wurde von meinem Mobiltelefon mit Linux Kernel und JVM Userland von K-9 Mail gesendet.

shinobu commented 8 years ago

just to go back to the previous problems with the large dataset (aksw.org is only 54xx triples big): i get the same error as @frodeseverin and as i already said an almost empty xml file and a file not found error for the other ways to export

extracting the aksw dataset with rdf/xml and ttl mode showed a difference of about 300 triples for the xml file and about 5000 for the ttl file -> inserting both into my ontowiki copy led to:

  1. xml xml output and ttl output were this time the same (the 300 + triples)
  2. ttl again 300 against 5000 triples

transforming the .tll to .rdf with rapper, importing it into ontowiki and exporting leads to the same results as 2.

so we got at least 2 things to fix: the 10000 triples maximum error and the xml export function

white-gecko commented 8 years ago

So the 10000 triples maximum error issue should be this one, while the problems with the xml export function should be in that issue: https://github.com/AKSW/Erfurt/issues/43

shinobu commented 8 years ago

After setting the max row count to 10000000 instead of 10000 the error stopped to get logged into the ontowiki.log, but the files are still not found and I get the error printed if I try to export n-triples. Furthermore the logs now contain some kind of model/info about the queries, but oddly those throw no errors (log is attached as .txt because uploading a .log is not supported) ontowiki.txt

---n-triples error---

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>OntoWiki Error</title>
<style type="text/css">
body {
    font-family: sans-serif;
    line-height: 1.5;
    background-color: #eff9ff;
}

.info {
    margin: 0.5% 10%;
    border: 1px solid #aaa;
    padding: 1%;
    background-color: #f9f9f9;
}

.error {
    margin: 0.5% 10%;
    border: 1px solid #f00;
    padding: 1%;
    background-color: #fcc;
}
</style>
</head>
<body>
<div class="error">
<h1>OntoWiki Error</h1>
<details>
<summary>SPARQL Error: [unixODBC][OpenLink][Virtuoso iODBC Driver][Virtuoso Server]SR353: Sorted TOP clause specifies more then 11000 rows to sort. Only 10000 are allowed. Either decrease the offset and/or row count or use a scrollable cursor () on querying graph &lt;NULL&gt; with query: define output:format &quot;JSON&quot;
SELECT ?resourceUri ?p ?o

FROM &lt;https://issue75test.com&gt;
WHERE { ?resourceUri ?p ?o . } ORDER BY ?resourceUri
LIMIT 1000
OFFSET 10000
</summary>
<p><code>Erfurt_Store_Adapter_Exception</code></p>
<p>
<code>/var/www/html/OntoWiki/vendor/aksw/erfurt/library/Erfurt/Store/Adapter/Virtuoso.php@1059</code>
<br/ ><code>#0: Erfurt_Store_Adapter_Virtuoso->_execSparql@/var/www/html/OntoWiki/vendor/aksw/erfurt/library/Erfurt/Store/Adapter/Virtuoso.php:679<br />#1: Erfurt_Store_Adapter_Virtuoso->sparqlQuery@/var/www/html/OntoWiki/vendor/aksw/erfurt/library/Erfurt/Store.php:1691<br />#2: Erfurt_Store->sparqlQuery@/var/www/html/OntoWiki/vendor/aksw/erfurt/library/Erfurt/Syntax/RdfSerializer/Adapter/NTriples.php:67<br />#3: Erfurt_Syntax_RdfSerializer_Adapter_NTriples->serializeQueryResultToString@/var/www/html/OntoWiki/vendor/aksw/erfurt/library/Erfurt/Syntax/RdfSerializer/Adapter/NTriples.php:98<br />#4: Erfurt_Syntax_RdfSerializer_Adapter_NTriples->serializeGraphToString@/var/www/html/OntoWiki/vendor/aksw/erfurt/library/Erfurt/Syntax/RdfSerializer.php:134<br />#5: Erfurt_Syntax_RdfSerializer->serializeGraphToString@/var/www/html/OntoWiki/application/controllers/ModelController.php:647<br />#6: ModelController->exportAction@/var/www/html/OntoWiki/vendor/zendframework/zendframework1/library/Zend/Controller/Action.php:516<br />#7: Zend_Controller_Action->dispatch@/var/www/html/OntoWiki/vendor/zendframework/zendframework1/library/Zend/Controller/Dispatcher/Standard.php:308<br />#8: Zend_Controller_Dispatcher_Standard->dispatch@/var/www/html/OntoWiki/vendor/zendframework/zendframework1/library/Zend/Controller/Front.php:954<br />#9: Zend_Controller_Front->dispatch@/var/www/html/OntoWiki/vendor/zendframework/zendframework1/library/Zend/Application/Bootstrap/Bootstrap.php:105<br />#10: Zend_Application_Bootstrap_Bootstrap->run@/var/www/html/OntoWiki/vendor/zendframework/zendframework1/library/Zend/Application.php:384<br />#11: Zend_Application->run@/var/www/html/OntoWiki/index.php:144<br /></code>
</p>
</details>
<p>
     <a href="http://localhost/OntoWiki/index.php/model/info/?m=https%3A%2F%2Fissue75test.com">back</a>&nbsp;
<a href="http://localhost/OntoWiki/index.php/">home</a>
</p>
</div>
</body>
</html>
shinobu commented 8 years ago

a little update about this: if you go on the view all resources section in your knowledebase you can click on source and get an actual correct N3 as output.