Re: [Virtuoso-users] Obtain list of knowledge graphs in iSQL
Hi, > is there any isql command to list the URIs of the knowledge graphs currently > in triple store? There are instructions to load and delete graphs, but I > cannot find one to list those currently loaded. > You can try the following command in isql: SQL> sparql select distinct ?g where {graph ?g {?s ?p ?o}}; Patrick — OpenLink Software ___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] Loading arbitrary XML?
Hi Jonathan, > > I'm very new to Virtuoso. I just have some simple XML files to load and > query. Could anyone point me to a tutorial that would show me how to do that? > And/or tell me the commands I'd need to run? > Please read the following wiki document about bulk loading data into the Virtuoso database in a variety of formats: http://vos.openlinksw.com/owiki/wiki/VOS/VirtBulkRDFLoader Patrick --- Patrick van Kleef Program Manager OpenLink Software http://www.openlinksw.com/ http://twitter.com/openlink/ ___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] Can't create ldp:Resource from Turtle file
All, > You need to install the ODS-Framework [1] and ODS-Briefcase [2] modules > atop your Virtuoso instance. Net effect, it adds an LDP layer to the > Virtuoso WebDAV core. > > Once installed, you can simply perform the following verification tests. > > Setup verification tests: > > > 1. curl -X OPTIONS -IH "Accept: text/turtle" {URI-of-LDP-Folder} > > 2. curl -iH "Accept: text/turtle" {URI-of-LDP-Folder} > > If the above is successful, you can perform some based read-write tests: > > JSON-LD: > > curl --cert {pkcs#12-file}.p12:1234 --cert-type P12 -X POST -H > 'Content-Type: application/ld+json' \ > -d '[{"@id":"","http://schema.org/name":"Foo"}]' > {URI-of-LDP-Folder}/test.jsonld > > > RDF-Turtle: > > curl --cert {pkcs#12-file}.p12:1234 --cert-type P12 -X POST > -H'Content-Type: text/turtle' \ > -d '<#this> <#relatedTo> <#that> .' {URI-of-LDP-Folder}/test.ttl > > VOS requires a different version of the ODS packages in order to work: > Links: > > [1] > http://download3.openlinksw.com/uda/vad-packages/7.2/ods_framework_dav.vad > http://download3.openlinksw.com/uda/vad-vos-packages/7.2/ods_framework_dav.vad > [2] > http://download3.openlinksw.com/uda/vad-packages/7.2/ods_briefcase_dav.vad http://download3.openlinksw.com/uda/vad-vos-packages/7.2/ods_briefcase_dav.vad Patrick --- Patrick van Kleef Program Manager OpenLink Software http://www.openlinksw.com/ http://twitter.com/openlink/ ___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] URGENT! Insert error in Virtuoso 7.2.2!
Hi Piret, > As the quad dump failed I went with an option to select list of named graphs > we needed to save from corrupted database and I am making dumps of those > graphs one by one using procedure specified here > http://virtuoso.openlinksw.com/dataspace/doc/dav/wiki/Main/VirtRDFDatasetDump. > I uploaded to new fresh database 1745454 named graphs from old database > using bulk loader. This is just a small amount of overall named graphs still > need loading to new database. After uploading those graphs with bulk loader I > started a process to insert some named graphs through our java process using > query "SPARQL INSERT DATA { GRAPH { ... }}". After processing > 233270 named graphs I got the same error in the clean database: > > COL..: Insert stopped because out of seg data here or elsewhere host 0 > key RDF_QUAD_SP slice 0 > > The clean database file size is only 4G. Made an integrity check after that > and it passed. Additionally made crash dump and restore successfully, but > after starting java process again I still get the same error. The differences > with other named graphs I inserted and the named graphs inserted through java > process is that java process ones contain multiple plain literal object > values with some UTF-8 letters 'ÄÖÜÕ', for example (test values presented): > > <https://test.ee/organizations/ee-1234567890> > <http://purl.org/goodrelations/v1#legalName> "EXAMPLE TEST OÜ" . > > And multiple decimal values, for example (test values presented): > > <https://test.ee/amounts/total> <http://schema.org/amount> > "7.77"^^<http://www.w3.org/2001/XMLSchema#decimal> . > > Integrity check passes and no errors are logged to virtuoso.log file. The > database starts up correctly and select queries work just fine. Connection > with virtuoso is made with url > "jdbc:virtuoso://:/CHARSET=UTF-8". > > I was not able to create a debian package with debug binary with symbols in > place using debian/rules for compiling. Can someone maybe give me some > guidance on where to correctly add option --with-debug and CFLAGS variable? > Please use the following environment for Debian, else the deb_build tool will strip the binaries: export DEB_BUILD_OPTIONS="nostrip noopt” next edit the debian/rules file and add the following line to the DEB_CONFIGURE_EXTRA_FLAGS= setting: —with-debug \ then do a clean build of the VOS tree, and you should end up with binaries that have full debug symbols. Patrick --- Patrick van Kleef Program Manager OpenLink Software http://www.openlinksw.com/ http://twitter.com/openlink/ -- Site24x7 APM Insight: Get Deep Visibility into Application Performance APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month Monitor end-to-end web transactions and take corrective actions now Troubleshoot faster and improve end-user experience. Signup Now! http://pubads.g.doubleclick.net/gampad/clk?id=267308311=/4140 ___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] SQL Error on insert with virtuoso 7.2.1
HI Piret, > Saw that new release verison 7.2.2 of virtuoso is available. But when I try > to build debian packages I get an error: > > test -x debian/rules > /usr/bin/make -C binsrc/VirtuosoClient.Net clean > make[1]: Entering directory > `/tmp/build/virtuoso-opensource/binsrc/VirtuosoClient.Net' > make[1]: *** No rule to make target `clean'. Stop. > make[1]: Leaving directory > `/tmp/build/virtuoso-opensource/binsrc/VirtuosoClient.Net' > make: *** [cleanbuilddir/libvirtmono0-cil] Error 2 > > The steps I take: > - start clean ubuntu 14.04 LTS Virtual Machine. All commands in machine are > executed under root user. > - install initial dependencies: > apt-get update > apt-get install -y openjdk-6-jdk git build-essential automake devscripts > equivs > - clone virtuoso source from github: > git clone https://github.com/openlink/virtuoso-opensource.git > git checkout v7.2.2 > - make sure all dependencies needed are installed, based on another message > thread conversation ( > http://sourceforge.net/p/virtuoso/mailman/message/34650682/ ): > mk-build-deps --install debian/control > - start debian package build: > fakeroot debian/rules clean binary Looks like the clean rule fires too soon, before the actual Makefiles etc are created. Since this is a new checkout, as a workaround you can just use: fakeroot debian/rules binary After you have build the first time, the clean option is functional. I will fix this for the next release > Am I missing something? Did some thing changed with release? Because building > develop/7 branch latest state on 27th of November worked with these steps. Patrick Patrick --- Patrick van Kleef Program Manager OpenLink Software http://www.openlinksw.com/ http://twitter.com/openlink/ -- ___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] Send SPARQL queries via C# ?
HI, > I want to query my graphs in virtuoso via C# .Net, I note vi google there is > a dotnet dll to do that, any body has experience to query virtuoso via C# > -send sqprql to virtuoso and iterate query result data set- ??? Yes, the virtuoso open source version contains a OpenLink.Data.Virtuoso.dll which works with Mono. You can execute any sparql query via the Virtuoso .NET Adapter by prefixing the query with the SPARQL keyword as shown here: http://docs.openlinksw.com/virtuoso/rdfsparql.html#rdfsparqlinline The resultset is returned as a set of rows which can be iterated over. Patrick Patrick --- Patrick van Kleef Program Manager OpenLink Software http://www.openlinksw.com/ http://twitter.com/openlink/ -- ___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] traps: virtuoso-t[54165] general protection ip:931aa7 sp:7f9b34d2eda0 error:0 in virtuoso-t[400000+c00000]
HI Jörn, > > i'm running a machine learning algorithm against a local Virtuoso 7.2.1 > SPARQL endpoint containing ~ 6 G triples... > > After several weeks of using it (including reboots etc.) tonight it crashed > after > 6h of heavy load with no further information in any of the logs than > this in dmesg: > >> traps: virtuoso-t[54165] general protection ip:931aa7 sp:7f9b34d2eda0 >> error:0 in virtuoso-t[40+c0] > > > It seems like it tried to access some memory it wasn't meant to access and > the kernel simply killed it for that: > https://en.wikipedia.org/wiki/General_protection_fault > > Did anyone ever experienced something similar? > Any reasonable way i could maybe get some more meaningful log if that happens > again? > You could reconfigure your build using —with-debug so the compiler will add symbol information to your binary, and run the $ ulimit -c unlimited command before starting the $ virtuoso-t server to tell the kernel to save a core dump file containing postmortem information on threads, stack frames, memory etc. Then continue to run your algorithm. If the crash happens again, the following commands can be used to provide call stack information to OpenLink: $ gdb virtuso-t core gdb> bt Patrick --- Patrick van Kleef Program Manager OpenLink Software http://www.openlinksw.com/ http://twitter.com/openlink/ -- Go from Idea to Many App Stores Faster with Intel(R) XDK Give your users amazing mobile app experiences with Intel(R) XDK. Use one codebase in this all-in-one HTML5 development environment. Design, debug & build mobile apps & 2D/3D high-impact games for multiple OSs. http://pubads.g.doubleclick.net/gampad/clk?id=254741911=/4140 ___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] quick exact label search through all languages
Hi Jörn, > > I know i can do something like the following, but it's terribly slow > (timeout, no result): > > select * where { > ?s rdfs:label ?l . > FILTER(str(?l) = "贝拉克·奥巴马"). > } > > e.g. > http://dbpedia.org/sparql?default-graph-uri=http%3A%2F%2Fdbpedia.org=prefix+dbpedia%3A+%3Chttp%3A%2F%2Fdbpedia.org%2Fresource%2F%3E%0D%0Aselect+*+where+{%0D%0A++%3Fs+rdfs%3Alabel+%3Fl+.%0D%0A++FILTER%28str%28%3Fl%29+%3D+%22%E8%B4%9D%E6%8B%89%E5%85%8B%C2%B7%E5%A5%A5%E5%B7%B4%E9%A9%AC%22%29.%0D%0A}=text%2Fhtml_redir_for_subjs=121_redir_for_hrefs==3=on > This of course would result in a partial table scan as the str function would need to be evaluated for each record. > > I already tried bif:contains like this: > > select * where { > ?s rdfs:label ?l . > FILTER(bif:contains(?l, "贝拉克·奥巴马")). > } > > e.g. > http://dbpedia.org/sparql?default-graph-uri=http%3A%2F%2Fdbpedia.org=prefix+dbpedia%3A+%3Chttp%3A%2F%2Fdbpedia.org%2Fresource%2F%3E%0D%0Aselect+*+where+{%0D%0A++%3Fs+rdfs%3Alabel+%3Fl+.%0D%0A++FILTER%28bif%3Acontains%28%3Fl%2C+%22%E8%B4%9D%E6%8B%89%E5%85%8B%C2%B7%E5%A5%A5%E5%B7%B4%E9%A9%AC%22%29%29.%0D%0A}=text%2Fhtml_redir_for_subjs=121_redir_for_hrefs==3=on > > but this returns the following error (and it's actually not exactly what i > want): > >> Virtuoso 37000 Error XM029: Free-text expression, line 0: Invalid character >> in free-text search expression, it may not appear outside quoted string at è >> >> >> SPARQL query: >> define sql:big-data-const 0 >> #output-format:text/html >> define sql:signal-void-variables 1 define input:default-graph-uri >> <http://dbpedia.org> prefix dbpedia: <http://dbpedia.org/resource/> >> select * where { >> ?s rdfs:label ?l . >> FILTER(bif:contains(?l, "è´æ‹‰å…‹Â·å¥¥å·´é©¬")). >> } > > > > So, is there a way for a performant exact literal search ignoring the > language? > > Or could you maybe just make the standard `str(?l) = "something"` way quick > if `?l` is a literal? > The problem is that when you use the contain function with unicode characters it has difficulties find word separation, so you need to quote the word yourself: Try like this: prefix dbpedia: <http://dbpedia.org/resource/> select * where { ?s rdfs:label ?l . FILTER(bif:contains(?l, "'贝拉克·奥巴马'")). } which will give you super fast results: http://dbpedia.org/sparql?default-graph-uri=http%3A%2F%2Fdbpedia.org=prefix+dbpedia%3A+%3Chttp%3A%2F%2Fdbpedia.org%2Fresource%2F%3E%0D%0Aselect+*+where+%7B%0D%0A++%3Fs+rdfs%3Alabel+%3Fl+.%0D%0A++FILTER%28bif%3Acontains%28%3Fl%2C+%22%27%E8%B4%9D%E6%8B%89%E5%85%8B%C2%B7%E5%A5%A5%E5%B7%B4%E9%A9%AC%27%22%29%29.%0D%0A%7D=text%2Fhtml_redir_for_subjs=121_redir_for_hrefs==3=on Patrick --- Patrick van Kleef Program Manager OpenLink Software http://www.openlinksw.com/ http://twitter.com/openlink/ -- ___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] Virtuoso DBpedia load - parsing errors
n our end, but on closer examination this was not the case. The issue here is that this value is tagged as a <http://www.w3.org/1999/02/22-rdf-syntax-ns#XMLLiteral> which triggers Virtuoso to actually parse the XML inside the object. Unfortunately it appears there was either a problem with a lot of pages they crawled for this BTC 2014 dataset, or they cut out part of the page. In any case i examined a number of lines that failed and all had issues with artifacts causing the strings not to be valid XML. Virtuoso actually can be build with the Tidy library which we use in our Sponger and crawlers to fixup the HTML from pages before further parsing it, to make sure these kind of errors do not occur when then dumping the data, but that does not help you at this point. One thing you can do is to edit the files and change http://www.w3.org/1999/02/22-rdf-syntax-ns#XMLLiteral to http://www.w3.org/1999/02/22-rdf-syntax-ns#PlainLiteral That would allow the bulk loader to load these strings without parsing so you would get these triples in place. It might have a small effect on the size of the free text index when using the CONTAINS keyword in SPARQL, but other than that it should be ok. Patrick --- Patrick van Kleef Program Manager OpenLink Software http://www.openlinksw.com/ http://twitter.com/openlink/ -- ___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] Virtuoso DBpedia load - parsing errors
Hi Roman, > I have a lot of errors when I want to load DBpedia dataset using isql, the > command: > ld_dir('/workingDir/btc2014_unzipped/01', 'data.nq-*', 'http://fake.org'); > > Example error: > > 22007 XM003: XML parser detected an error: ERROR : Tag nesting > error: name 'img' of end tag does not match the name 'p' of start tag > at line 4 column 432 at line 4 column 438 of source text > 04/02/skos/core#" xmlns:xsd="http://www.w3.org/2001/XMLSchema#;> > --^ > > Ok, let's find the line where the error occured (I put a line break, so it is > easier to see): > > <http://core-project.kmi.open.ac.uk/data-description> > <http://purl.org/rss/1.0/modules/content/encoded> " xmlns=\"http://www.w3.org/1999/xhtml\; > xmlns:content=\"http://purl.org/rss/1.0/modules/content/\; > xmlns:dc=\"http://purl.org/dc/terms/\; > xmlns:foaf=\"http://xmlns.com/foaf/0.1/\; xmlns:og=\"http://ogp.me/ns#\; > xmlns:rdfs=\"http://www.w3.org/2000/01/rdf-schema#\; > xmlns:sioc=\"http://rdfs.org/sioc/ns#\; > xmlns:sioct=\"http://rdfs.org/sioc/types#\; > xmlns:skos=\"http://www.w3.org/2004/02/skos/core#\; > xmlns:xsd=\"http://www.w3.org/2001/XMLSchema#\;>What data are > exposed\nhttp://www.w3.org/1999/xhtml\; > xmlns:content=\"http://purl.org/rss/1.0/modules/content/\; > xmlns:dc=\"http://purl.org/dc/terms/\; > xmlns:foaf=\"http://xmlns.com/foaf/0.1/\; xmlns:og=\"http://ogp.me/ns#\; > xmlns:rdfs=\"http://www.w3.org/2000/01/rdf-schema#\; > xmlns:sioc=\"http://rdfs.org/sioc/ns#\; > xmlns:sioct=\"http://rdfs.org/sioc/types#\; > xmlns:skos=\"http://www.w3.org/2004/02/skos/core#\; xmlns:xsd= \"http://www.w3.org/2001/XMLSchema#\;>The CORE project exposes data about the aggregated content. The following schema shows the kind of metadata CORE holds about each resource. \nhttp://www.w3.org/1999/xhtml\; xmlns:content=\"http://purl.org/rss/1.0/modules/content/\; xmlns:dc=\"http://purl.org/dc/terms/\; xmlns:foaf=\"http://xmlns.com/foaf/0.1/\; xmlns:og=\"http://ogp.me/ns#\; xmlns:rdfs=\"http://www.w3.org/2000/01/rdf-schema#\; xmlns:sioc=\"http://rdfs.org/sioc/ns#\; xmlns:sioct=\"http://rdfs.org/sioc/types#\; xmlns:skos=\"http://www.w3.org/2004/02/skos/core#\; xmlns:xsd=\"http://www.w3.org/2001/XMLSchema#\;>Data Schema\nhttp://www.w3.org/1999/xhtml\; xmlns:content=\"http://purl.org/rss/1.0/modules/content/\; xmlns:dc=\"http://purl.org/dc/terms/\; xmlns:foaf=\"http://xmlns.com/foaf/0.1/\; xmlns:og=\"http://ogp.me/ns#\; xmlns:rdfs=\"http://www.w3.org/2000/01/rdf-schema#\; xmlns:sioc=\"http://rdfs.org/sioc/ns#\; xmlns:sioct=\"http://rdfs.org/sioc/typ es#\" xmlns:skos=\"http://www.w3.org/2004/02/skos/core#\; xmlns:xsd=\"http://www.w3.org/2001/XMLSchema#\;> > \nhttp://www.w3.org/1999/xhtml\; > xmlns:content=\"http://purl.org/rss/1.0/modules/content/\; > xmlns:dc=\"http://purl.org/dc/terms/\; > xmlns:foaf=\"http://xmlns.com/foaf/0.1/\; xmlns:og=\"http://ogp.me/ns#\; > xmlns:rdfs=\"http://www.w3.org/2000/01/rdf-schema#\; > xmlns:sioc=\"http://rdfs.org/sioc/ns#\; > xmlns:sioct=\"http://rdfs.org/sioc/types#\; > xmlns:skos=\"http://www.w3.org/2004/02/skos/core#\; > xmlns:xsd=\"http://www.w3.org/2001/XMLSchema#\;>Data License\n xmlns=\"http://www.w3.org/1999/xhtml\; > xmlns:content=\"http://purl.org/rss/1.0/modules/content/\; > xmlns:dc=\"http://purl.org/dc/terms/\; > xmlns:foaf=\"http://xmlns.com/foaf/0.1/\; xmlns:og=\"http://ogp.me/ns#\; > xmlns:rdfs=\"http://www.w3.org/2000/01/rdf-schema#\; > xmlns:sioc=\"http://rdfs.org/sioc/ns#\; > xmlns:sioct=\"http://rdfs.org/sioc/types#\; > xmlns:skos=\"http://www.w3.org/2004/02/skos/core#\; > xmlns:xsd=\"http://www.w3.org/2001/XMLSchema#\;>All data from CORE (unless > otherwise specified) are available under th e a Creative Commons Attribution 3.0 Unported License. \n"^^<http://www.w3.org/1999/02/22-rdf-syntax-ns#XMLLiteral> . > > Also tried to load using different errors bits, the same result: > DB.DBA.TTLP_MT (file_to_string_output > ('/workingDir/btc2014_unzipped/01/data.nq-9'), '', 'http://fake.org', 512) > > Why Virtuoso tries to check HTML/XML tags consistency inside the literals?! > Is it possible to turn it off? I have too many errors in the dataset, it is a > waste of time trying to find all lines with errors and remove them by hands. > Can't find anything related to this in the documentation. I have reproduced the problem in-house and i am current
Re: [Virtuoso-users] SPARQL update question
Hi Boris, I'm working with Virtuoso version 07.10.3208 on Linux (x86_64-unknown-linux-gnu), Single Server Edition. I have to do some postprocessing processess (via scripts) and I need to do lot of queries like this DEFINE sql:log-enable 3 DELETE { GRAPH http://data.isoco.net/havas/graph/data { http://data.isoco.net/resource/member/abhishek-agrawal-1 http://vocab.isoco.net/degree ?o . } } WHERE { http://data.isoco.net/resource/member/abhishek-agrawal-1 http://vocab.isoco.net/degree ?o . } I'm not getting any error on virtuoso.log but seems to be the triples are still there on the triplestore. I also included the TransactionAfterImageLimit parameter as suggested here [1] But, nothing, some triples are not deleted Any idea what I'm missing? Best TIA Boris [1] http://www.openlinksw.com/wiki/main/VOS/VirtTipsAndTricksGuideTransactionLogControl Can you run the following queries on your system using the isql tool and share the output with me: select count (*) from rdf_quad a table option (index rdf_quad) where not exists (select 1 from rdf_quad b table option (loop, index rdf_quad_pogs) where a.g = b.g and a.p = b.p and a.o = b.o and a.s = b.s); select count (*) from rdf_quad a table option (index rdf_quad_pogs) where not exists (select 1 from rdf_quad b table option (loop, index primary key) where a.g = b.g and a.p = b.p and a.o = b.o and a.s = b.s); select count (*) from rdf_quad a table option (index rdf_quad) where not exists (select 1 from rdf_quad b table option (loop, index rdf_quad) where a.g = b.g and a.p = b.p and a.o = b.o and a.s = b.s); select count (*) from rdf_quad a table option (index rdf_quad_pogs) where not exists (select 1 from rdf_quad b table option (loop, index rdf_quad_pogs) where a.g = b.g and a.p = b.p and a.o = b.o and a.s = b.s); Patrick -- OpenLink Software -- Comprehensive Server Monitoring with Site24x7. Monitor 10 servers for $9/Month. Get alerted through email, SMS, voice calls or mobile push notifications. Take corrective actions from your mobile device. http://p.sf.net/sfu/Zoho ___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] R on Virtuoso Server
HI Esra, I would like to ask if it is possible to run R script (http://www.r-project.org/) on Virtuoso server. Thanks! You can interface between R and Virtuoso using the RODBC package: http://cran.r-project.org/package=RODBC This uses the Virtuoso ODBC driver to connect to the Virtuoso database engine and retrieve information via SQL or SPASQL from your Virtuoso database and process it further within the R language. Patrick -- Learn Graph Databases - Download FREE O'Reilly Book Graph Databases is the definitive new guide to graph databases and their applications. Written by three acclaimed leaders in the field, this first edition is now available. Download your free book today! http://p.sf.net/sfu/NeoTech ___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] Question about Sparql query (Virtuoso)
Hi Esra, I installed Virtuoso on Windows. Now I want to work with Sparql queries (connected to Openlink Virtuoso on cmd). I have an rdf file called 'example.rdf'. I want to run this Sparql query: SPARQL PREFIX ore:http://www.openarchives.org/ore/terms/ PREFIX dc:http:purl.org/dc/elements/1.1/ SELECT distinct ?resource ?title FROM D:/example.rdf/ WHERE {?resource ore:proxyIn ?proxy . ?resource dc:title ?title .}; The result: resource title LONG VARCHAR LONG VARCHAR So I get empty results instead of resource and title values. How can I get these two columns? I'm sure that my Sparql query is correct because I get the title and resource values when I am running the same Sparql above on Java or on R. I notice that I get empty result on every running Sparql on Virtuoso. For example, also at this query I get empty result: SPARQL SELECT ?p ?s WHERE { { SELECT DISTINCT ?p ?s FROM http://dbpedia.org WHERE { ?s ?p http://dbpedia.org/resource/Germany } ORDER BY ASC(?p) } } OFFSET 5 LIMIT 1000; The result of this query: p s LONG VARCHAR LONG VARCHAR How can I solve this problem? Do I need to install or to do something else for running sparql queries? E.g. jena libraries (I have virt_jena.jar file in the folder jena and virt_jena2.jar in the folder jena2). Thanks! Before you can query this data, you first need to load it into your virtuoso database, which can be done in several ways as described in the following wiki document: http://virtuoso.openlinksw.com/dataspace/doc/dav/wiki/Main/VirtRDFInsert one of the methods uses this function: http://docs.openlinksw.com/virtuoso/fn_rdf_load_rdfxml_mt.html Copy your example.rdf file into the same directory where your virtuoso database is located, as Virtuoso by default is not allowed to read files from your D: drive. Make a connection with the isql.exe tool to your virtuoso database and then perform the following command: DB.DBA.RDF_LOAD_RDFXML_MT (file_to_string_output ('example.rdf'), '', 'mygraphname'); This command will load the data from the D:/example.rdf file and load it under the graph name mygraphname. After this has completed you an use it: SPARQL PREFIX ore:http://www.openarchives.org/ore/terms/ PREFIX dc:http:purl.org/dc/elements/1.1/ SELECT distinct ?resource ?title FROM mygraphname WHERE {?resource ore:proxyIn ?proxy . ?resource dc:title ?title .}; Patrick -- Learn Graph Databases - Download FREE O'Reilly Book Graph Databases is the definitive new guide to graph databases and their applications. Written by three acclaimed leaders in the field, this first edition is now available. Download your free book today! http://p.sf.net/sfu/NeoTech ___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] ASSUME ???
HI Jerven, What is the ASSUME variable that you added in 6.1.7 ? http://virtuoso.openlinksw.com/dataspace/doc/dav/wiki/Main/ I can't find any reference to this in the SPARQL 1.1 query standard. Is this a virtuoso specific extension? I passed your question to the virtuoso development team and will reply as soon as i have an answer. Patrick -- See everything from the browser to the database with AppDynamics Get end-to-end visibility with application monitoring from AppDynamics Isolate bottlenecks and diagnose root cause in seconds. Start your free trial of AppDynamics Pro today! http://pubads.g.doubleclick.net/gampad/clk?id=48808831iu=/4140/ostg.clktrk ___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] strafter and strbefore
HI Erich, Are STRAFTER and STRBEFORE supported in Virtuoso 6.1.6 or is it time to go to Virtuoso 7? - Erich These two functions are in the upcoming 6.1.7 version OpenLink is about to release. https://github.com/openlink/virtuoso-opensource/commit/46344d4d7007ae7f11473e249a43dce6122e4c2e If you want to use them right now, i suggest you clone the develop/6 branch from github: git clone -b develop/6 https://github.com/openlink/virtuoso-opensource.git Best regards, Patrick -- Get 100% visibility into Java/.NET code with AppDynamics Lite It's a free troubleshooting tool designed for production Get down to code-level detail for bottlenecks, with 2% overhead. Download for free and get started troubleshooting in minutes. http://p.sf.net/sfu/appdyn_d2d_ap2 ___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] Negative xsd:date issue
Hi Julien, Yes I saw your previous answer this morning. Thank you very much for your quick answer and to let me know when the bug will be solved. This bug has been fixed and is available on both the develop/6 and develop/7 branches on github. Patrick I replied to the email you sent to me on this issue from your friends email address which you may not have seen I suppose, which was: The does look like a bug which has been confirmed with development and a report for them to fix created. Once completed it will be announced on the github RSS feed or I shall let you know ... Best Regards Hugh Williams Professional Services OpenLink Software, Inc. // http://www.openlinksw.com/ Weblog -- http://www.openlinksw.com/blogs/ LinkedIn -- http://www.linkedin.com/company/openlink-software/ Twitter -- http://twitter.com/OpenLink Google+ -- http://plus.google.com/100570109519069333827/ Facebook -- http://www.facebook.com/OpenLinkSoftware Universal Data Access, Integration, and Management Technology Providers On 3 Apr 2013, at 20:28, Julien Plu julien@redaction-developpez.com wrote: Hi, I have a bug in trying to insert negatives xsd:date in my virtuoso store. When I try to do this I have this error : Error DT006: Cannot convert -0010-01-01 to datetime : Incorrect year field length There is a way to do this, or it's a bug from Virtuoso ? Thanks in advance for your answer. Best regards. Julien Plu. -- Minimize network downtime and maximize team effectiveness. Reduce network management and security costs.Learn how to hire the most talented Cisco Certified professionals. Visit the Employer Resources Portal http://www.cisco.com/web/learning/employer_resources/index.html___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users -- Precog is a next-generation analytics platform capable of advanced analytics on semi-structured data. The platform includes APIs for building apps and a phenomenal toolset for data science. Developers can use our toolset for easy data analysis visualization. Get a free account! http://www2.precog.com/precogplatform/slashdotnewsletter___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users smime.p7s Description: S/MIME cryptographic signature -- Precog is a next-generation analytics platform capable of advanced analytics on semi-structured data. The platform includes APIs for building apps and a phenomenal toolset for data science. Developers can use our toolset for easy data analysis visualization. Get a free account! http://www2.precog.com/precogplatform/slashdotnewsletter___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] Unable to connect to virtuoso : Connect failed to localhost:1111
Hi Sumit, [root@rdesc db]# /usr/local/virtuoso-opensource/bin/virtuoso-t -f -c /usr/local/virtuoso-opensource/bin/virtuoso.ini Sun Mar 24 2013 20:15:51 { Loading plugin 1: Type `plain', file `wikiv' in `/usr/local/virtuoso-opensource/lib/virtuoso/hosting' 20:15:51 WikiV version 0.6 from OpenLink Software 20:15:51 Support functions for WikiV collaboration tool 20:15:51 SUCCESS plugin 1: loaded from /usr/local/virtuoso-opensource/lib/virtuoso/hosting/wikiv.so } 20:15:51 { Loading plugin 2: Type `plain', file `mediawiki' in `/usr/local/virtuoso-opensource/lib/virtuoso/hosting' 20:15:51 MediaWiki version 0.1 from OpenLink Software 20:15:51 Support functions for MediaWiki collaboration tool 20:15:51 SUCCESS plugin 2: loaded from /usr/local/virtuoso-opensource/lib/virtuoso/hosting/mediawiki.so } 20:15:51 { Loading plugin 3: Type `plain', file `creolewiki' in `/usr/local/virtuoso-opensource/lib/virtuoso/hosting' 20:15:51 CreoleWiki version 0.1 from OpenLink Software 20:15:51 Support functions for CreoleWiki collaboration tool 20:15:51 SUCCESS plugin 3: loaded from /usr/local/virtuoso-opensource/lib/virtuoso/hosting/creolewiki.so } 20:15:51 OpenLink Virtuoso Universal Server 20:15:51 Version 06.01.3127-pthreads for Linux as of Mar 5 2013 20:15:51 uses parts of OpenSSL, PCRE, Html Tidy 20:15:51 Virtuoso is already running (pid 0) 20:15:51 Server exiting When virtuoso starts it attempts to get an exclusive lock on the .db file to make absolutely sure it is the only process using this file. If it fails to get this lock, this normally means the pid of the process that holds the lock is printed. In your case however it appears to be unable to ask for a lock since your filesystem type does not support it. I will fix the code to make sure we report this condition in a more understandable way. Since your earlier emails indicated it was working on the same location before your reboot, it could be that the system failed to restart an appropriate lock manager for your fs, for instance when you use NFS, the nfslock daemon should be running. Can you tell me what filesystem type you are using for the filesystem that contains: /projects/rdesc/virtuoso-opensource/var/lib/virtuoso/db/virtuoso.db Patrick smime.p7s Description: S/MIME cryptographic signature -- Everyone hates slow websites. So do we. Make your web apps faster with AppDynamics Download AppDynamics Lite for free today: http://p.sf.net/sfu/appdyn_d2d_mar___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] HTTP Request Size in Virtuoso
Hello Burak Yönyül, I cannot execute queries which are greater than a few kilobytes on Virtuoso. I've loaded example drugbank dataset into Virtuoso Opensource 6.1 and I'm trying to execute the query in the file I've attached here, on my local drugbank dataset with the sparql endpoint http://155.223.24.47:8893/drugbank/sparql;. But when I execute this I get HTTPException: 400 Bad Request. How can I execute queries greater than 25 KB? How do I configure incoming HTTP request size in Virtuoso server(opensource 6.1)? I cannot send queries which are greater than a few kilobytes (25 KB). The main problem that you cannot use the GET method to execute such a big query to any server. First of all your query in text form is around 25Kb large, but before it can be posted your browser will have to urlencode it so it can make a query=ENCODED_TEXT_OF_QUERY parameter to add to the URL which blows it up to around 57Kb. Even when you remove the whitespace from the beginning of each line this will still result in a large query of 16Kb. This will still cause problems as all modern browsers have a practical limit on the total length of a URL[1] that can be used by a form METHOD=GET request. And even many HTTP servers like Apache, IIS etc have a server side limit on the length of a URL request line. Fortunately there are several ways to resolve this problem. a. Virtuoso supports both GET and POST forms to the /sparql interface so if you use like an AJAX call (in case of javascript), a CURL call (in case of php) etc, you should be able to change your code to use a POST method. This will encode the parameter into the body of the request which can hold much more data than the request-header, instead of adding this to the URL as a param. NOTE: the basic form you get when you use /sparql uses GET by default, but this can be changed to use a post without much problems. b. Virtuoso can also handle SPARQL requests through an ODBC or JDBC interface which does not have such length limits. You can test this by using the isql (on some Linux distros this is installed as isql-vt) to connect to your database : isql SQL sparql select * where {?s a ?o} limit 100; Note the sparql keyword at the start of the line. This is a trigger for Virtuoso to parse and execute this with the SPARQL engine instead of the SQL engine. When using any of the above suggestions, you will find out that Virtuoso will return an error as your query has to many expressions generated: The nesting depth of subexpressions exceed limits of SPARQL compiler I will check if there is a more compact way to write this query instead of this huge number of UNIONS and will send a separate reply about that later. I have attached two small patches that you can try, provided you do not have a problem rebuilding the Virtuoso Open Source Edition from its source code. Both patches should apply without any errors on the latest version 6.1.6 or even better the develop/6 branch of VOS on Github. I will discuss these temp patches internally to see if we can make a permanent fix for these issues in time for the next release of VOS. Best regards, Patrick See Also: [1] http://stackoverflow.com/questions/417142/what-is-the-maximum-length-of-a-url [2] Attached patch sparql_form_use_post.diff [3] Attached patch sparql_h_depth_define.diff sparql_h_depth_define.diff Description: Binary data sparql_form_use_post.diff Description: Binary data smime.p7s Description: S/MIME cryptographic signature -- LogMeIn Rescue: Anywhere, Anytime Remote support for IT. Free Trial Remotely access PCs and mobile devices and provide instant support Improve your efficiency, and focus on delivering more value-add services Discover what IT Professionals Know. Rescue delivers http://p.sf.net/sfu/logmein_12329d2d___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] HTTP Request Size in Virtuoso
Hello Burak Yönyül, I cannot execute queries which are greater than a few kilobytes on Virtuoso. I've loaded example drugbank dataset into Virtuoso Opensource 6.1 and I'm trying to execute the query in the file I've attached here, on my local drugbank dataset with the sparql endpoint http://155.223.24.47:8893/drugbank/sparql;. But when I execute this I get HTTPException: 400 Bad Request. How can I execute queries greater than 25 KB? I promised i would also have a look at the query itself and see if it could be simplified. Your query consists of a union of repeating patterns like this: { ?y_0 http://www.w3.org/2002/07/owl#sameAs http://dbpedia.org/resource/Tetrahydrocannabinol . ?Int_0 http://www4.wiwiss.fu-berlin.de/drugbank/resource/drugbank/interactionDrug1 ?y_0 . ?Int_0 http://www4.wiwiss.fu-berlin.de/drugbank/resource/drugbank/interactionDrug2 ?IntDrug_0 . ?Int_0 http://www4.wiwiss.fu-berlin.de/drugbank/resource/drugbank/text ?IntEffect_0 } UNION { ?y_1 http://www.w3.org/2002/07/owl#sameAs http://dbpedia.org/resource/Mescaline . ?Int_1 http://www4.wiwiss.fu-berlin.de/drugbank/resource/drugbank/interactionDrug1 ?y_1 . ?Int_1 http://www4.wiwiss.fu-berlin.de/drugbank/resource/drugbank/interactionDrug2 ?IntDrug_1 . ?Int_1 http://www4.wiwiss.fu-berlin.de/drugbank/resource/drugbank/text ?IntEffect_1 } } UNION { ?y_2 http://www.w3.org/2002/07/owl#sameAs http://dbpedia.org/resource/Bacillus_Calmette-Gu%C3%A9rin . ?Int_2 http://www4.wiwiss.fu-berlin.de/drugbank/resource/drugbank/interactionDrug1 ?y_2 . ?Int_2 http://www4.wiwiss.fu-berlin.de/drugbank/resource/drugbank/interactionDrug2 ?IntDrug_2 . ?Int_2 http://www4.wiwiss.fu-berlin.de/drugbank/resource/drugbank/text ?IntEffect_2 } } UNION { ?y_3 http://www.w3.org/2002/07/owl#sameAs http://dbpedia.org/resource/Sugammadex . ?Int_3 http://www4.wiwiss.fu-berlin.de/drugbank/resource/drugbank/interactionDrug1 ?y_3 . ?Int_3 http://www4.wiwiss.fu-berlin.de/drugbank/resource/drugbank/interactionDrug2 ?IntDrug_3 . ?Int_3 http://www4.wiwiss.fu-berlin.de/drugbank/resource/drugbank/text ?IntEffect_3 } } UNION { ?y_4 http://www.w3.org/2002/07/owl#sameAs http://dbpedia.org/resource/Carnitine . ?Int_4 http://www4.wiwiss.fu-berlin.de/drugbank/resource/drugbank/interactionDrug1 ?y_4 . ?Int_4 http://www4.wiwiss.fu-berlin.de/drugbank/resource/drugbank/interactionDrug2 ?IntDrug_4 . ?Int_4 http://www4.wiwiss.fu-berlin.de/drugbank/resource/drugbank/text ?IntEffect_4 } } etc. In this case you should be able to use the SPARQL 1.1 IN construction[1] as in: SELECT * WHERE { ?y_0 http://www.w3.org/2002/07/owl#sameAs ?d_1 . FILTER (?d_1 in ( http://dbpedia.org/resource/Tetrahydrocannabinol , http://dbpedia.org/resource/Mescaline, http://dbpedia.org/resource/Bacillus_Calmette-Gu%C3%A9rin, http://dbpedia.org/resource/Sugammadex, http://dbpedia.org/resource/Carnitine )). ?Int_0 http://www4.wiwiss.fu-berlin.de/drugbank/resource/drugbank/interactionDrug1 ?y_0 . ?Int_0 http://www4.wiwiss.fu-berlin.de/drugbank/resource/drugbank/interactionDrug2 ?IntDrug_0 . ?Int_0 http://www4.wiwiss.fu-berlin.de/drugbank/resource/drugbank/text ?IntEffect_0 } which results in a much shorter query. See also: [1] http://www.w3.org/TR/sparql11-query/#func-in Best regards, Patrick smime.p7s Description: S/MIME cryptographic signature -- LogMeIn Rescue: Anywhere, Anytime Remote support for IT. Free Trial Remotely access PCs and mobile devices and provide instant support Improve your efficiency, and focus on delivering more value-add services Discover what IT Professionals Know. Rescue delivers http://p.sf.net/sfu/logmein_12329d2d___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] correct upstart config file
Hi Sebastian, We want to start and supervise (this is important since virtuoso crashes sometimes) our virtuoso instances with upstart, the Ubuntu init process. I've found a config file at [1] but unfortunately it seems to be not optimal (e.g. virtuoso forks and upstart can not follow the pid). My question: What is the optimal upstart configuration for virtuoso and if it does not exist - can someone from Openlink with enough internal information can build such a config file? In my opinion, such a configuration is a big advantage over the init scripts. Best regards Sebastian Tramp 1. http://wimmics.inria.fr/projects/dbpedia/doc/index.php/D%C3%A9ploiement_de_Virtuoso#Avec_Upstart Please try the following script for upstart: cat /etc/init/virtuoso.conf # virtuoso - Upstart script for Virtuoso Open Source Edition 6.1 description virtuoso author Patrick van Kleef pkl...@openlinksw.com # When to start the service start on runlevel [2345] # When to stop the service stop on runlevel [016] # Automatically restart process if crashed respawn # Virtuoso will fork into background expect fork # Start Virtuoso exec /usr/bin/virtuoso-t -c /etc/virtuoso-opensource-6.1/virtuoso.ini +wait The -c options should point at the virtuoso.ini file that contains all the parameters for this database. In my case i used the defaults from the Ubuntu 12.04 LTS i have as a test VM. The +wait option make virtuoso fork itself into the background, while the foreground process waits until until it receives an OK from the background process that the server has been started successfully. If there is a failure a status code is passed back to the calling process, so it knows whether the server has been started or not. Best regards, Patrick -- OpenLink Software smime.p7s Description: S/MIME cryptographic signature -- LogMeIn Rescue: Anywhere, Anytime Remote support for IT. Free Trial Remotely access PCs and mobile devices and provide instant support Improve your efficiency, and focus on delivering more value-add services Discover what IT Professionals Know. Rescue delivers http://p.sf.net/sfu/logmein_12329d2d___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] Problem with FILTER NOT EXISTS and MINUS
HI Nate, I get following error when I try to execute any query containing FILTER NOT EXISTS or MINUS: SPARQL Error: [unixODBC][OpenLink][Virtuoso iODBC Driver][Virtuoso Server]SQ074: Line 47: SP031: SPARQL: Internal error: 'output:valmode' declaration conflicts with 'output:format' () in query:... I'm using virtuoso 6.1.4.3127-pthreads Is there a setting wrong in my installation or is this a bug? I suggest you upgrade to the 6.1.6 release as this problem was fixed after the 6.1.4 you are running was released. Patrick smime.p7s Description: S/MIME cryptographic signature -- Monitor your physical, virtual and cloud infrastructure from a single web console. Get in-depth insight into apps, servers, databases, vmware, SAP, cloud infrastructure, etc. Download 30-day Free Trial. Pricing starts from $795 for 25 servers or applications! http://p.sf.net/sfu/zoho_dev2dev_nov___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] Connecting to Virtuoso
Hi Nate, I have installed virtuoso from the debian repository on my olinuxino board when I run the odbctest script [1] from ontowiki with php-cli the connection works. If I invoke it from the browser I get: Connection failed - Something is wrong with your configuration. Used connection parameters: - DSN: VOS - Username: dba - Password: dba Error message: [unixODBC][OpenLink][Virtuoso iODBC Driver]CL033: Connect failed to localhost: = localhost:. I have also installed the conductor if I call my board at port 8890 I see the link to the conductor but get: Error HTCLI HC001: Connection Error in HTTP Client when I click on it. The log [2] has also some strange content but it says 15:03:16 Server online at (pid 1417) in the end. Am I missing something, or how can I debug the problem? Thank you Nate [1] https://github.com/AKSW/OntoWiki/blob/develop/application/scripts/odbctest.php [2] http://paste.debian.net/207498/ Looking at this paste output you provided, there is a problem with the build you have tried to install. Errors like: 15:03:09 Error executing a server init statement : 37000: SQ074: Line 63 (line 498 of [executable]/wsrm_xsd.sql): syntax error at '\\' before '' type=\\'' -- SOAP_LOAD_SCH (WSRM_WSS0212_XSD (), null, 0, 0) and 15:03:09 Error compiling stored procedure: 37000: SQ074: Line 25 (line 79 of [executable]/vspx.sql): syntax error at '%' before 's' -- #line 55 [executable]/vspx.sql create trigger VSPX_SESSIO 15:03:09 Error compiling a server init statement : 37000: SQ074: Line 33: syntax error at '%' before 's' -- create method vc_render () for vspx_button should of course not happen when starting up a database for the first time. During the creation of the database, a number of compiled-in stored procedures are called to actually create the meta-structure of the db. In the build you installed these procedures have not been generated properly during the compilation process and most likely the build was not verified with the supplied testsuite. As such even though the server managed to start, your database is not initialized correctly and both the http service as well as the odbc connection will be unusable. Can you give me the first 7 lines of output from this command: virtuoso-t -? You should probably contact the Debian Maintainer and ask him if there is a newer build for your version of Debian available. Note the most current virtuoso version for Debian is available here: http://packages.debian.org/sid/virtuoso-opensource The latest version of Virtuoso Open Source is actually 6.1.6 which has a lot of bugfixes and optimizations and is currently the recommended version to install. If you have no problem compiling packages for your platform yourself, you can find the source code tree on: http://github.org/openlink/virtuoso-opensource or the tar ball on: http://sourceforge.net/projects/virtuoso/files/virtuoso/6.1.6/ Patrick -- Maintainer Virtuoso Open Source Edition smime.p7s Description: S/MIME cryptographic signature -- Everyone hates slow websites. So do we. Make your web apps faster with AppDynamics Download AppDynamics Lite for free today: http://p.sf.net/sfu/appdyn_d2d_nov___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] Simple html escape functions?
HI Will, I'm looking for some simple XML/HTML escape functions amongst Virtuoso's built-in functions, but I can't find anything other than http_value (http_url etc.) which are awkward to use for a string result (via string_output_string). Ideally I was expecting to find something similar to the PHP urlencode and htmlspecialchars functions that simply return the escaped string. Am I just missing something? I basically just wanted this to fix /rdfdesc/description.vsp to produce valid XHTML but it uses sprintf substitutions where some variables need to be escaped first (_url, _label in rdfdesc_http_print_r). I noticed some other syntax breakage in there also (closing on iframe height attribute, missing alt on img tags.. use of iframe itself even) so I was intending to make a patch. I am already working on a fix for that too specifically for dealing with international characters, but i also saw the problems your reported with some tags when using the w3c validator. Patch should be forthcoming on monday. Patrick -- OpenLink Software smime.p7s Description: S/MIME cryptographic signature -- Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] Fatal error installing Demo package
Hi Peter, I'm trying to install the VAD package Demo through Conductor 6.01.3127 (System Admin - Packages - Demo - Install) It's failing to install and returning the following Fatal Error: 0 Errors detected 0 Installation of Demo Database was unsuccessful. The installation of this VAD package has failed. Please delete the transaction file /usr/local/virtuoso-opensource/var/lib/virtuoso/db//usr/local/virtuoso-opensource/var/lib/virtuoso/db/virtuoso.trx and then restart your database server. Note: Your database will be in its pre VAD installation state after you restart. 0 FATAL Can anyone help me with this? Are there any scripts available to manually populate the Demo database so I can install it with data without needing the package to work? Please check your virtuoso.log file. Just above the lines you show here, is another couple of lines that hold the clue to why the package could not be installed. If you cut/paste them in an email to me, i will help you understand why the package could not be installed. Of course you could try to load all the SQL scripts and other parts by hand, but the reason of the VAD is to make this simpler. Patrick smime.p7s Description: S/MIME cryptographic signature
Re: [Virtuoso-users] SPARQL FILTER by xsd types
HI Quintin, I have a bit of weirdness though it's been resolved/worked-around. A query that looks like: prefix ont: ontStuff select ?dq { GRAPH http://stuff { ?li ont:code S . ?li ont:liHasDQ ?dq . ?dq ont:Quantity ?qty . ?dq ont:Quantity 0^^xsd:int } } Or with a filter: prefix ont: ontStuff select ?dq { GRAPH http://stuff { ?li ont:code S . ?li ont:liHasDQ ?dq . ?dq ont:Quantity ?qty . ?dq ont:Quantity ?qty FILTER (?qty= 0^^xsd:int) } } These don't return and under some circumstances, crash Virtuoso. Changing the Quantity to a variable bind and with a FILTER doesn't help much though I haven't observed it to crash. But if I change the FILTER to (?qty = 0) then it returns in a few seconds. Any idea why this would happen? The underlying literal is a typed as (actual example): 01^^http://www.w3.org/2001/XMLSchema#int. Casting to xsd:int doesn't help either, that won't return in reasonable time either. I did a quick check, but without some sample data, i was not able to quickly re-create your crash. Which version of Virtuoso are you currently using? Would it be possible for you to configure the VOS tree with --with-debug and rebuild your tree and retest upto the point where it crashes. Once you have a core dump, i would like to see a backtrace of the stack, so we can pinpoint what is going on. Patrick smime.p7s Description: S/MIME cryptographic signature
Re: [Virtuoso-users] Encoding and bif:contains
Hi Alexandre, Anyone from the Virtuoso team knows how to solve this (if that can be solved) I have forwarded your questions internally. I hope to have some answers for you soon. Patrick -- OpenLink Software smime.p7s Description: S/MIME cryptographic signature
Re: [Virtuoso-users] Null character escape in wide string literals?
Hi Will, I am trying to figure out the correct way to escape a null character in a wide string literal for Virtuoso. For narrow literals with c-escapes turned on I can use \0 as expected. But in a wide literal (e.g. N'null\0escape') Virtuoso complains with SQ074 Invalid wide string literal. I tried \00 \ even \z and \u but I can't find the right sequence. Can anyone help? In the current version of Virtuoso Open Source, the \0 is not accepted as a wide char, so a workaround until fixed is to use concatenation like : N'aaa' || '\0' || N'bbb' We are working on a permanent fix, so please keep an eye on our Github commit list: https://github.com/openlink/virtuoso-opensource/commits/develop/6 Patrick smime.p7s Description: S/MIME cryptographic signature
Re: [Virtuoso-users] Long read issues with PHP odbc
HI Will, OK forget this, it's definitely a PHP problem. Sorry for the noise. If you can tell me what is going wrong with PHP, i still maybe able to help by sending them a bugfix if need be. Patrick --- Maintainer iODBC
Re: [Virtuoso-users] tweaking default language settings?
Hi Joe, I am importing some RDF/XML triples that have both language and XMLLiteral datatype specified. The behavior is different depending on language: en triples are stored with no language tag, and with the XMLLiteral datatype, whereas non-en triples are stored with their given language tag, and without the XMLLiteral datatype. Is there a way to tweak the language settings so that en is not treated differently from other languages? Can you send me sample of the data you are trying to load, so i can check it here. Patrick --- Maintainer Virtuoso Open Source Edition
Re: [Virtuoso-users] ResultSet to Java Collection
Hi Alex, is there any method available in virtuoso driver 4 for jdbc to get the result of a query to a java collection. I am interested to make a difference set operation and I would like to avoid the iteration over the results. Moreover, could someone point me the javadocs of the referred driver? If you have a copy of the VOS source tree, the jdbc driver is in libsrc/JDBCDriverType4 directory, which allows you to see how the current implementation is done. As for documentation, assuming you have configured the tree with --with-jdk4=/path/to/your/java-1.6, you can do: cd libsrc/JDBCDriverType4 gmake doc which would result in a doc/virtjdbc4 subdirectory being created. Patrick --- Maintainer Virtuoso Open Source Edition
Re: [Virtuoso-users] Virtuoso v6.1.5 (Open Source Edition) missing file sparqlwords.gperf
Hi Rex, Failed to build for me, Makefile's seem to reference some non-existent (and seemingly otherwise unused sparqlwords.gperf file). I patched it out (see attached patch). Thanks for reporting this issue. When you use the tarball, the sparqlwords.h is already generated, so you do not need to have the underlying .gperf file, except when you want to add new keywords. I will put a new tarball online shortly that fixes this problem, so others will benefit. For those who already have downloaded the tarbal, you can take the attached file and put it into the libsrc/Wi directory, or you can use the following commands to continue building: cd libsrc/Wi touch sparqlwords.gperf touch sparqlwords.h that will allow you to build a working binary. Patrick --- OpenLink Software sparqlwords.gperf Description: Binary data
Re: [Virtuoso-users] Priviliged admin user
Hi Maxime, I wonder if the DBA has a dedicated cannal to connect to Virtuoso. Indeed, DBA as the admin user of Virtuoso, it is the only one who can run some commands (disconnect, backup ...) and if all threads are used by other applications, it can't connect and run a request, not privilege. Is there a way to do to have a privileged admin user? Currently we do not have such a dedicated channel, however i discussed this internally and i have raised a feature request for this. https://sourceforge.net/tracker/?func=detailaid=3487224group_id=161622atid=820577 Patrick
Re: [Virtuoso-users] How to disconnect SPARQL USER
HI Maxime, When i run the http_pending_req(); request during a sparl-end-point requests, nothing is return. The http_pending_req() returns a vector e.g.: SQL select http_pending_req(); VARCHAR ___ vector(0x04460c78,0x04460cd8,0x04460d08,0x0446e3b8) 1 Rows. -- 0 msec. Each of these 4 elements in the vector contains a tuple with the IP address, the endpoint and the ID of the request. To use it, you can create a procedure like this: create procedure my_show_http_req() { declare HTTP_IP varchar(40); declare HTTP_REQ varchar(20); declare HTTP_ID varchar(15); result_names (HTTP_IP, HTTP_REQ, HTTP_ID); foreach (any req in http_pending_req()) do { result(req[0], req[1], req[2]); } } ; Here is an example: SQL my_show_http_req(); HTTP_IP HTTP_REQ HTTP_ID VARCHAR VARCHARVARCHAR __ 127.0.0.1 /sparql46920327908064 127.0.0.1 /about 46920103636928 127.0.0.1 /sparql46919932624640 127.0.0.1 /describe 46919654535248 4 Rows. -- 1 msec. The output of this can then be used with http_kill e.g.: SQL http_kill ('127.0.0.1', '/sparql', 46920327908064); Patrick
Re: [Virtuoso-users] Renaming a big graph
Hi Martin, will the database binary format be backwards compatible, i.e. can we just copy our 6.1.3-pre database over into 6.1.4's working directory? Please read the README.UPGRADE file from the 6.1.4 source tree. There was a potential problem with some types of XML fragments that could break one of the indexes. When you start up your 6.1.3-pre database with the 6.1.4 binary, it will do a diagnostic on your database to determine if your database might be affected by this. If not, then the database will just start up without any problems and will not check again on subsequent starts. If your database does have this problem, the README.UPDATE contains the steps you need to take to allow virtuoso to fix this problem and recreate the index. Note this can take some time depending on the size of your database and your database will grow in size, which after conversion will be added to your free block count. If you have any questions, please contact me. Patrick -- OpenLink Software
Re: [Virtuoso-users] Signal 11 while uploading a large file
HI Vanessa, I installed the latest version of virtuoso on my Mac Lion. I modified virtuoso.ini to use up to 4GB of memory (I have 8GB), however when I am uploading the DBpedia infoboxes it fails after a couple of hours or more. 00:48:36 PL LOG: Loader started 00:48:36 PL LOG: No more files to load. Loader has finished, 00:48:59 PL LOG: Loader started 00:48:59 PL LOG: No more files to load. Loader has finished, 00:51:01 PL LOG: Loader started 01:42:24 Checkpoint started 01:42:34 Checkpoint finished, log reused 02:42:37 Checkpoint started 02:42:50 Checkpoint finished, log reused 02:49:45 Server received signal 11. Continuing with the default action for that signal. I use the DBpedia script and I did not have any problem to install and upload virtuoso in Linux using the same procedure. Any idea what the problem can be? cat BulkLoaderScript.txt | /usr/local/src/virtuoso/bin/isql SQL /usr/local/src/virtuoso/bin/isql SQL ld_dir ('/virtuosodata/dbpedia/', 'infobox_properties_en.nt', 'http://dbpedia.org '); SQL rdf_loader_run(); To be able to analyze what is going on, you need to setup your system to produce meaningful core dumps on Mac OS X. Firstly i suggest you run the following commands to re-configure virtuoso build to include debug info: ./config.nice --with-debug make clean make Next you run the following command so your system will write core dumps ulimit -c unlimited and then start the virtuoso server from this same shell and run your bulkload script. When it next gets a signal 11, you will find a core in /cores/core.PID where PID is the process id of your virtuoso server. Then you can do: gdb virtuoso-t /cores/core.PID and on the gdb prompt run the bt command to show the stack trace for this crash. Please send me the output of this command, plus the last couple of lines of your virtuoso.log so i can analyze what is going on and what steps to take next. Patrick
Re: [Virtuoso-users] Query not parsed via PHP but works in iSQL
Hi Norman, thanks for your reply. I am using Mac OS X 10.7.2 (Darwin macbook- pro.local 11.2.0 Darwin Kernel Version 11.2.0: Tue Aug 9 20:54:00 PDT 2011; root:xnu-1699.24.8~1/RELEASE_X86_64 x86_64) with stock PHP 5.3.6 built against iODBC. I have attached the odbc trace log. The query in question seems to start at line 26287. I think the problem is the fact that by default PHP-ODBC uses a cursor and virtuoso fails to detect that your query is a SPARUL query that might not lent itself to a cursor model. When you are using the SPARQL_EVAL stored procedure, Virtuoso lowers the cursor model automatically which is why this work. Could you edit your php.ini and find the [ODBC] section and set: [ODBC] odbc.default_cursortype = 0 and test again. I will be checking the code to see exactly what is going on and make a patch when possible, but cursor_type 0 (forward only) or using the SPARQL_EVAL method should be a good workaround for the moment. Patrick --- OpenLink Software
Re: [Virtuoso-users] Query not parsed via PHP but works in iSQL
HI Norman, Hi, I got a query that uses bif:contains filter (see below). When I issue it via PHP_ODBC using the sparql prefix keyword, it cannot be parsed. It works however, in iSQL and via PHP_ODBC using SPARQL_EVAL function. The issue occurs with both, Virtuoso OpenSource 6.1.3 and 6.1.4. Query: define output:format JSON SELECT DISTINCT ?resourceUri FROM http://lod2.eu/ FROM http://lod2.eu/schema/ WHERE { ?listresource ?p0 ?o0 . ?listresource ?resourceUri ?showPropsObj . FILTER (bif:contains(?o0, testimonial*)) } The following error is thrown: SQ200: No column t2.S., SQL state S0022 in SQLExecDirect in /Library/ WebServer/Sites/odbctest.php on line 15 Call Stack: 0.0002 645256 1. {main}() /Library/WebServer/Sites/odbctest.php:0 0.0030 647072 2. odbc_exec() /Library/WebServer/Sites/odbctest.php:15 Which version of PHP and ODBC driver manager are you using and what OS are you using, so i can setup a similar testbed here and try to figure out what is going on. Also can you put the following into your odbc.ini or odbcinst.ini file (latter when using unixodbc) to get a trace on the ODBC level: [ODBC] Trace=1 Tracefile=/tmp/odbc-trace.log and retry the failing test, so i can see what commands are exactly passed to the driver. Patrick -- OpenLink
Re: [Virtuoso-users] [Dbpedia-discussion] 502 Proxy Error on SPARQL Query
HI Gerber, I asked this question some time ago on the DBpedia Mailing List. I would still be very grateful if anybody could tell me the setting I need to change in order to avoid the 502 Proxy Error. I want to fix that for the DBpedia Live Endpoint. The fix i made was not a Virtuoso setting, but a proxy setting. The http://live.dbpedia.org/sparql endpoint, i think it is using a Apache proxy as a front end. Without having access to the error logs, it is hard for me to speculate the exact problem, but there are two possibilities: 1. DBPedia can generate large headers due to alternate LINK in http HEAD, so the proxy should be configured with larger settings for header packets. 2. Apache proxy timeout is too small for using long running queries as yours, so it times out before getting response from the virtuoso server. This is the most likely scenario in your case. In both cases some simple tweaking of the apache settings, should resolve this. Unfortunately at this time apache.org times out on me, so i cannot point you to the individual pages with the exact names of the settings. Patrick --- OpenLink Software
Re: [Virtuoso-users] Segfault with Virtuoso 6.1.2 / 6.1.3
Hi Cédric, sometimes our Virtuoso server segfaults on a sparql query. When we were using version 6.1.2, the error on the log was: 09:24:48 GPF: bitmap.c:1552 next/prev of non-valid bit pos With version 6.1.3, the error is now: 12:35:34 Invalid bit position on index: RDF_QUAD_POGS 12:35:34 GPF: bitmap.c:1606 next/prev of non-valid bit pos Any idea of what the problem could be ? I believe this issue is fixed in the 6.1.4 release we just announced earlier this week. I suggest you first upgrade to 6.1.4 then you should run the following two statements on your database using the isql tool: select count (*) from RDF_QUAD table option (index primary key) select count (*) from RDF_QUAD table option (index RDF_QUAD_POGS) These counts should match, else you may need to drop the index and re- create it: drop index RDF_QUAD_POGS; create bitmap index RDF_QUAD_POGS on RDF_QUAD (P, O, G, S) partition (O varchar (-1, 0hex)) Let me know if this solves your problem. Patrick --- OpenLink Software
Re: [Virtuoso-users] Regexp_replace pattern matching with variable substitution
HI Peter, I'm using Virtuoso regexp_replace to strip newline and whitespace characters from an xml file before passing it to xtree_doc. My pattern to match is: 'n[0-9]:(\n|\s)' I need to preserve the value matched by [0-9] in the replacement string. eg: regexp_replace(string,'n3:(\n|\s)','n3:') as well as regexp_replace(string,'n5:(\n|\s)','n5:') and so forth for any value of [0-9]. Is there a way to do this? In some regexp implementations parts of the pattern can be tagged as a variable ( eg {$1} ) and passed to the replacement string. Yes, this is possible since Virtuoso, by using the following construct: regexp_replace(string,'n([0-9]):(\n|\s)','n\\1:') Best regards, Patrick
Re: [Virtuoso-users] Unstable endpoint
Hi Arne, I was requested by Hugh Williams and Jens Lehmann to send an email to this mailing list regarding the unstable performance of the dbpedia sparql endpoint. I’m currently working on a project for the EU that requires me to use LOD to retrieve information about cities and Eurostat data. For the information about the cities I’m relying on the dbpedia project to retrieve the info I need. The problem is that the endpoint is behaving in a weird fashion at the moment. At certain times, I receive information reasonably fast from the endpoint, but in most cases the endpoint either times out or doesn’t return any data at all. I assume your code does check the HTTP status result codes? There are a number of reasons why the dbpedia endpoint can give timeouts such as: 1. you send too many requests in very short amount of time 2. you send very time-consuming queries and you receive a timeout 3. someone else is doing some very expensive queries We have several ACLs in place to deal with the above scenarios but that does not mean that some users write crawlers that ignore the HTTP status codes and properly act upon them. We are looking into the best way to deal with such. A few examples of cities that I’m working with can be located here: -http://dbpedia.org/resource/Antwerp -http://dbpedia.org/resource/Düsseldorf -http://dbpedia.org/resource/London From the datasets, I’m able to deduct that I have a thumbnail property and abstract property, and this is the information that I require in the project. Using Ruby on Rails, I have created some classes that allow me to communicate with the SPARQL endpoint located at http://dbpedia.org/sparql Using a simply GET request I send the following query to the endpoint: PREFIX dbo: http://dbpedia.org/ontology/ PREFIX prop: http://dbpedia.org/property/ PREFIX foaf: http://xmlns.com/foaf/0.1/ PREFIX rdfs: http://www.w3.org/2000/01/rdf-schema# SELECT ?thumbnail ?abstract WHERE { ?location rdfs:label ?label; a dbo:PopulatedPlace OPTIONAL { ?location dbo:thumbnail ?thumbnail . } OPTIONAL { ?location dbo:abstract ?abstract . FILTER langMatches(lang(?abstract), 'en')} FILTER regex(?label, 'Swanage', 'i') } LIMIT 1 Where the language and name of town are beeing injected by the code. In some cases this returns information in other cases this returns northing. In the case of multiple results I’m only interested in the first match. I’m using the OPTIONAL parts because I don’t know if the properties are always there, it’s just a safeguard to prevent exceptions on my side. If I’m doing something wrong with the query, please let me know and I’ll change it, but my understanding is that the endpoint is not working as intended. The performance killer in your query is the use of: FILTER regex(?label, 'Swanage', 'i') which is basically will need to check every individual place triple to see if it matches which is not a very efficient way to quickly get the results. I suggest you replace this FILTER line and replace it with: ?label bif:contains '\'Düsseldorf\'' or ?label bif:contains 'Antwerpen' which takes into account the fact there can be special characters in names. If you are dealing only with Latin1 characters, you can leave out the inner quotes. Also note the spaces between the double and single quote are not needed, but enhance readability. The CONTAINS function has the same advantage as the REGEX (x, 'i') option of finding both antwerpen, Antwerpen or any other case mixes but using an index which is much faster. so this would mean your query would look like: PREFIX dbo: http://dbpedia.org/ontology/ PREFIX prop: http://dbpedia.org/property/ PREFIX foaf: http://xmlns.com/foaf/0.1/ PREFIX rdfs: http://www.w3.org/2000/01/rdf-schema# SELECT ?thumbnail ?abstract WHERE { ?location rdfs:label ?label; a dbo:PopulatedPlace. ?label bif:contains 'Antwerpen' . OPTIONAL { ?location dbo:thumbnail ?thumbnail . } OPTIONAL { ?location dbo:abstract ?abstract . FILTER langMatches(lang(?abstract), 'en')} } LIMIT 1 which is much faster. Another trick you can use is to turn a SPARQL request into an ANYTIME query. This is done by adding timeout=5000 to the end of the /sparql/?query= request which instructs the Virtuoso SPARQL endpoint to only return results that it can find in approximate 5000msec. There are special HTTP result header flags that indicate if the resultset is a partial or full result. See also: http://docs.openlinksw.com/virtuoso/anytimequeries.html Patrick
Re: [Virtuoso-users] Missing ldap related functions ?
Hi, I was trying to setup the ldap backend for ldap authentication using the conductor web interface, and when I tested, I received an error message stating: SR185: Undefined procedure DB.DBA.ldap_search I'm using the version 6.1.2 packaged for ubuntu natty (11.04). Am I missing something, did I forget to install a VAD package or do you think there is a bug somewhere? in the meantime, how can I solve this issue ? To work with LDAP, Virtuoso needs to be configured with the --with- openldap flag to incorporate functions in virtuoso that interface with the openldap client library. At this time the Ubuntu package is not build with this extension. To resolve this, you would need to either get in touch with the ubuntu maintainer for virtuoso, or compile it yourself using the following instructions for ubuntu/debian and including the --with-openldap in the configure phase: http://virtuoso.openlinksw.com/dataspace/dav/wiki/Main/VOSUbuntuNotes#Building%20from%20Upstream%20Source Best regards, Patrick --- OpenLink Software
Re: [Virtuoso-users] [Virtuoso-devel] Upgrading Virtuoso and Proxy reversing
HI Houda, I am trying to upgrade my Virtuoso server from version 1.6.2 to version 1.6.3 by simply installing the Version 1.6.3 using ./ configure -prefix=/Path/OldVirtuoso. But, I get this error after several attempts to start server on port (this port is not busy by any application in my machine). Waiting Virtuoso Server start on port ... ***FAILED: Could not start Virtuoso Server within 600 seconds make[2]: *** [rdf_mappers_dav.vad] Error 1 make[2]: Leaving directory `/home/khrouf/Documents/virtuoso- opensource-6.1.3/binsrc/rdf_mappers' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/home/khrouf/Documents/virtuoso- opensource-6.1.3/binsrc' make: *** [all-recursive] Error 1 I think also that there are some persons which have the same problem. Please go to the following directory: binsrc/rdf_mappers and check the content of the *.log files in this directory as hints on why virtuoso cannot build this vad are in these files. You can forward me these files if you need assistance in solving the problem. Another question : I published a SPARQL endpoint using HTTP Virtual directories of Virtuoso. But, I want to create a nice URL of a SPARQL endpoint. So, I want to know if Virtuoso 1.6.3 supports the reversing proxies and if there are some configuration to do. If i understand you correctly you can use RewriteRules to make nice URLs. Please read: http://docs.openlinksw.com/virtuoso/rdfiridereferencing.html#urlrewriting Patrick
Re: [Virtuoso-users] HTTPS setup on Localhost
HI Daniel, I'm trying to get HTTPS to work with Virtuoso. I'm following these two documentation pages: 1) X.509 certificate Generation http://www.openlinksw.com/dataspace/dav/wiki/Main/VirtGenerateX509Cert 2) Guide for Setting Up the Virtuoso HTTPS Listener using File System to host Certificate and Public Key http://www.openlinksw.com/dataspace/dav/wiki/Main/VirtSetupSSLFileSystem I've got as far as establishing all the right pem files using OpenSSL, and have modified my virtuoso.ini [parameters] to look like this: SSLServerPort = 2111 SSLCertificate = /my-path/newcert.pem SSLPrivateKey = /my-path/newkey.pem X509ClientVerify= 1 X509ClientVerifyDepth = 15 X509ClientVerifyCAFile = /my-path/cakey.pem I've also changed my URIQA DefaultHost to be wildebeest, which is what my localhost machine is named. (where my-path is my actual path... I've changed it in this email for simplicity.) Then I try to fire up virtuoso (using the virtuoso-start.sh script), and I get this error: $ sudo ./bin/virtuoso-start.sh Starting Virtuoso instance in [database] The VDBMS server process terminated prematurely after opening the database. *** *** ERROR: Could not start this Virtuoso Instance. *** 10:35:26 { Loading plugin 7: Type `Hosting', file `hosting_php.so' in `../hosting' 10:35:26 Hosting version 3129 from OpenLink Software 10:35:26 PHP engine version 5.2.18-dev 10:35:26 SUCCESS plugin 7: loaded from ../hosting/hosting_php.so } 10:35:26 { Loading plugin 12: Type `plain', file `qrcode' in `../hosting' 10:35:26 QRcode version 0.1 from OpenLink Software 10:35:26 Support functions for ISO/IEC 18004:2006, using QR Code encoder (C) 2006 Kentaro Fukuchi fuki...@megaui.net 10:35:26 SUCCESS plugin 12: loaded from ../hosting/qrcode.so } 10:35:26 Error loading the ODBC server X509 private key /my-path/newkey.pem : � 10:35:26 Server exiting *** *** Please fix the above issue(s) before trying again. *** It seems to think that there are odd characters in the newkey.pem (the commandline renders them as a question-mark and a 0001-box). Here are my relevant system specs: * Ubuntu 11.04 (The standard gnome desktop edition) with Linux Kernel 2.6.38-8-generic * OpenSSL 0.9.8o-5ubuntu1 * OpenLink Virtuoso Universal Server 06.02.3129 (single server edition) (Build: Mar 16 2011) Any ideas why this may be? (it works fine when I comment out the SSL and X509 parameters in virtuoso.ini - but I could do with getting HTTPS to work) First of all your settings are in the wrong section. The settings in [Parameters] are for SSL secured ODBC connections. The settings in [Httpserver] are for setting up HTTPS. Patrick
Re: [Virtuoso-users] Virtuoso Open-Source Edition, Version 6.1.3
Hi Matteo, I am running a virtuoso OSE 6.1.2 on an old box, and now I am in the process to move the data on a newer machine, and maybe it's time to upgrade to 6.1.3. Is it possible to move the database files (or perform the backup with the instructions at [2]) and get the newer machine run on the old data? I read at the page [1] that the only problem regards the transaction logs, is it right? Thanks, Matteo Moci [1] http://virtuoso.openlinksw.com/dataspace/dav/wiki/Main/UpgradingToVOS610#Upgrading to a newer VOS 6.1.x from an earlier VOS 6.1.x [2] http://docs.openlinksw.com/virtuoso/backup.html Correct. There is no conversion or backup/restore needed to go from VOS 6.1.2 to 6.1.3 except to make sure that you have shutdown your database with the 6.1.2 binary. If there is a virtuoso.trx file with a non-zero length, the 6.1.3 executable will fail to start. The database file itself is machine independent, so after you have done a shutdown of the database, you can copy it direct to the new machine and start it with the new 6.1.3 executable. Patrick
Re: [Virtuoso-users] SPARQL Query using SERVICE
HI Boris, Now, I'm having this error Virtuoso 42000 Error SR186: No permission to execute procedure DB.DBA.SPARQL_SINV_IMP with user ID 106, group ID 106 Try: GRANT EXECUTE on DB.DBA.SPARQL_SINV_IMP to SPARQL_SELECT; But you should really consider upgrading this installation to 6.1.3 which has much better SPARQL-FED support to begin with. Patrick Executing the following statement should fix the problem: GRANT EXECUTE on DB.DBA.SPARQL_SINV to SPARQL_SELECT; Best Regards, Rumi - Original Message - From: Boris Villazón Terrazas To: Virtuoso Users Sent: Monday, June 20, 2011 1:25 PM Subject: [Virtuoso-users] SPARQL Query using SERVICE Hi all Apologies if this is a trivial question. I'm trying to perform the following query, in my local endpoint, PREFIX uniprot:http://purl.uniprot.org/uniprot/ SELECT * WHERE { ?a owl:sameAs ?b . SERVICE http://chebi.bio2rdf.org/sparql { ?b owl:sameAs uniprot:P20439 } } I'm having the following error 42000 Error SQ200: Must have select privileges on view DB.DBA.SPARQL_SINV Would you please point me out a way to set the priviligies? thanks in advance and regards Boris -- EditLive Enterprise is the world's most technically advanced content authoring tool. Experience the power of Track Changes, Inline Image Editing and ensure content is compliant with Accessibility Checking. http://p.sf.net/sfu/ephox-dev2dev ___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users -- EditLive Enterprise is the world's most technically advanced content authoring tool. Experience the power of Track Changes, Inline Image Editing and ensure content is compliant with Accessibility Checking. http://p.sf.net/sfu/ephox-dev2dev___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] New version with very slow free text search
Hi Bruno. I upgraded to Version 06.01.3.3127-pthreads linux and some queries that ran on 4 seconds or less are now taking 45 seconds. Also, the commercial version Version 06.02.3129-pthreads have similar problems. One query that got a lot worse was: sparql define input:inference http://semantica.globo.com/ruleset select distinct ?s ?label { {graph http://semantica.globo.com/esportes/ { ?s a http://semantica.globo.com/esportes/ Jogo ; ?p ?o . ?o bif:contains '22/05/2011*' . ?s rdfs:label ?label . } } UNION { graph http://semantica.globo.com/ { ?s a http://semantica.globo.com/base/ Evento ; ?p ?o . ?o bif:contains '22/05/2011*' . ?s rdfs:label ?label . } } UNION { graph http://semantica.globo.com/esportes/ { ?s a http://semantica.globo.com/esportes/ Prova ; ?p ?o . ?o bif:contains '22/05/2011*' . ?s rdfs:label ?label . } } UNION { graph http://semantica.globo.com/esportes/ { ?s a http://semantica.globo.com/esportes/Edicao_de_campeonato ; ?p ?o . ?o bif:contains '22/05/2011*' . ?s rdfs:label ?label . } } } ORDER BY (?label) LIMIT 10; Is anyone experiencing the same problems ? We are already in contact with Roosevelt on this query. Please check with him for solution. Patrick
Re: [Virtuoso-users] starting virtuoso under mac os x
Hi Joe, I have Fink's virtuoso installed, Version 6.1.2.3127-pthreads as of Apr 29 2011 Compiled for Darwin (i386-apple-darwin10.7.0) When I try to start the server (with or without sudo privileges), I get messages like below (copied to the log file as well). However, trying to connect via isql gives errors (further below). Any help is appreciated! /sw/var/lib/virtuoso/db $ sudo virtuoso-t -f Wed May 25 2011 11:30:09 { Loading plugin 1: Type `plain', file `wikiv' in `/sw/lib/virtuoso/hosting' 11:30:09 FAILED plugin 1: Unable to locate file } 11:30:09 { Loading plugin 2: Type `plain', file `mediawiki' in `/sw/lib/virtuoso/hosting' 11:30:09 FAILED plugin 2: Unable to locate file } 11:30:09 { Loading plugin 3: Type `plain', file `creolewiki' in `/sw/lib/virtuoso/hosting' 11:30:09 FAILED plugin 3: Unable to locate file } 11:30:09 { Loading plugin 4: Type `plain', file `im' in `/sw/lib/virtuoso/hosting' So the fink installation does not install these plugins. They are only important if you want to run the ODS-Wiki vad package, which i think they probably have not build either. 11:30:09 IM version 0.5 from OpenLink Software 11:30:09 Support functions for Image Magick 6.5.8 11:30:09 SUCCESS plugin 4: loaded from /sw/lib/virtuoso/hosting/ im.so } 11:30:09 { Loading plugin 5: Type `plain', file `wbxml2' in `/sw/lib/virtuoso/hosting' 11:30:09 WBXML2 version 0.9 from OpenLink Software 11:30:09 Support functions for WBXML2 0.10.7 Library 11:30:09 SUCCESS plugin 5: loaded from /sw/lib/virtuoso/hosting/ wbxml2.so } So these plugins were loaded without a problem. 11:30:09 { Loading plugin 9: Type `Hosting', file `hosting_perl.so' in `/sw/lib/virtuoso/hosting' There should be more output at this point including the SQL and HTTP port to connect with like: 13:14:52 OpenLink Virtuoso Universal Server 13:14:52 Version 06.01.3127-pthreads for Darwin as of May 19 2011 13:14:52 uses parts of OpenSSL, PCRE, Html Tidy 13:14:52 Database version 3126 13:14:52 SQL Optimizer enabled (max 1000 layouts) 13:14:54 Compiler unit is timed at 0.001573 msec 13:14:55 Roll forward started 13:14:55 Roll forward complete 13:14:55 Checkpoint started 13:14:55 Checkpoint finished, log reused 13:14:58 HTTP/WebDAV server online at 8894 13:14:58 Server online at 3 (pid 57000) These ports are set in the virtuoso.ini file in this db directory. /sw/var/lib/virtuoso/db $ isql.virtuoso -U dba -P dba *** Error S2801: [Virtuoso Driver]CL033: Connect failed to localhost: = localhost:. at line 0 of Top-Level: This means that your virtuoso installation either is not running yet on port or is possibly configured to use another port. Please check your virtuoso.ini file and look for [Parameters] ... ServerPort = ... If it is running on a different port you need to use: isql.virtuoso -U dba -P dba -S or using short connect method: isql.virtuoso localhost: dba dba where is the port number from your virtuoso.ini file. Best regards, Patrick
Re: [Virtuoso-users] starting virtuoso under mac os x
HI Joe, In any case, this is just a partial startup log - you should expect a small delay while it creates an empty database and possibly installs the Conductor VAD package into it, followed by: ... 16:48:10 INFO: Checkpoint finished, log reused 16:48:12 INFO: HTTP/WebDAV server online at 8890 16:48:12 INFO: Server online at (pid n) It simply kicks me back to my shell prompt after printing the info I posted. [...] 13:11:10 SUCCESS plugin 5: loaded from /sw/lib/virtuoso/hosting/ wbxml2.so } 13:11:10 { Loading plugin 9: Type `Hosting', file `hosting_perl.so' in `/sw/lib/virtuoso/hosting' /sw/var/lib/virtuoso/db $ It could be there is an issue with this plugin. If you modify your virtuoso.ini file and look for [Plugins] section and put a semicolon before the Load9, Load10 and Load11 to comment them out. These plugins are not important for first time users. Patrick
Re: [Virtuoso-users] starting virtuoso under mac os x
Hi Joe, Patrick: Commenting out those plugins solves it. Thanks! And I'll keep in mind Tim's advice about building directly from source if I see subsequent problems. For the record, the Macports version of Virtuoso doesn't build and I reported a bug about it here: https://trac.macports.org/ticket/29584 Good to hear. Note that depending on the version of Mac OS X, you can do the port with the native XCode development set without any of these macport or fink installations, as we support the Mac OS X environment natively as well. At least on 10.5 and 10.6 you should be able to build a working Virtuoso out of the box, using the source code available on: http://sourceforge.net/projects/virtuoso/files/virtuoso/ The README file inside the source tree shows you what to do and there are more instructions in the Wiki: http://virtuoso.openlinksw.com/dataspace/dav/wiki/Main/ Tim will be looking into any possible issues with Fink and/or Macports. Please let us know if you have more questions about Virtuoso. Patrick
Re: [Virtuoso-users] No remap dp for a dirty buffer error
HI Mohamed, I'm Mohamed Morsey, I'm working on DBpedia-Live in the AKSW group of the University of Leipzig. After running DBpedia-Live application for a while (something like 14 Hrs), Virtuoso crashes and gives that error message GPF: insert.c:1172 In compact, no remap dp for a dirty buffer ./start.sh: line 4: 56609 Segmentation fault sudo /opt/virtuoso/ose/6.1.3/bin/virtuoso-t -f -c $iniFile I also assign 8GB of memory to Virtuoso by configuring NumberOfBuffers but after running it for a while I also notice that memory allocated to it exceeds that amount. I also tried to assign only 4GB of memory to it, but the problem remains. So, would you please help me in that issue, is there a specific setting that I should configure in the .ini file or something. We have seen this issue in a couple of our simulations, but we have not been able to pinpoint the exact set of circumstances under which it occurs. We are currently trying to narrow down to a repeatable testcase that is easier to debug. I will keep you posted when we have a fix available. Patrick
Re: [Virtuoso-users] Sorting in SPARQL XML result format
Hi Jonas, i have a problem with sorting again :) given the dataset in the attachment, when i do the query SELECT DISTINCT ?resourceUri FROM http://example.com/activities/ WHERE { ?resourceUri http://www.w3.org/1999/02/22-rdf-syntax-ns#type http://xmlns.notu.be/aair#Activity . ?resourceUri http://www.w3.org/2005/Atom/published ?published . ?resourceUri http://xmlns.notu.be/aair#activityVerb ?verb . ?resourceUri http://xmlns.notu.be/aair#activityActor ?actor . ?resourceUri http://xmlns.notu.be/aair#activityObject ?object FILTER (!isBLANK(?resourceUri)) } ORDER BY ASC(?published) LIMIT 10 the result is as expected. but when i add define output:format RDF/XML the returned xml is unsorted. could that be a bug? Can you please tell me the version of Virtuoso you are using, so i can do some testing to make sure this is already fixed. Patrick
Re: [Virtuoso-users] Sorting in SPARQL XML result format
Hi Jonas, i have a problem with sorting again :) given the dataset in the attachment, when i do the query SELECT DISTINCT ?resourceUri FROM http://example.com/activities/ WHERE { ?resourceUri http://www.w3.org/1999/02/22-rdf-syntax-ns#type http://xmlns.notu.be/aair#Activity . ?resourceUri http://www.w3.org/2005/Atom/published ?published . ?resourceUri http://xmlns.notu.be/aair#activityVerb ?verb . ?resourceUri http://xmlns.notu.be/aair#activityActor ?actor . ?resourceUri http://xmlns.notu.be/aair#activityObject ?object FILTER (!isBLANK(?resourceUri)) } ORDER BY ASC(?published) LIMIT 10 the result is as expected. but when i add define output:format RDF/XML the returned xml is unsorted. could that be a bug? Can you please tell me the version of Virtuoso you are using, so i can do some testing to make sure this is already fixed. im on 6.1.2 Is it possible you upgrade to VOS 6.1.3 which has been released on 30 april of this year as i believe this issue has already been resolved. I have verified that it does not occur anymore in the latest VOS development code. Best regards, Patrick
Re: [Virtuoso-users] Change number of connection?
Hi, On May 19, 2011, at 5:09 PM, Nguyen Mau Quoc Hoan wrote: How could I configure the limit number connection of virtuoso server? I checked the virtuoso configuration and I saw the limit number connection is 10. Now I want to increase it for my project. How could I do it It depends on whether you want to increase the number of concurrent HTTP connections or the number of concurrent ODBC/JDBC/iSQL connections. To increase the number of concurrent HTTP threads, edit the file called virtuoso.ini that is in same directory as your database, find the section called [HTTPServer] and change the ServerThreads parameter in that section. To increase the number of concurrent ODBC threads, edit the same file but this time find the section called [Parameters] and change the ServerThreads parameter in that section. Best regards, Patrick
Re: [Virtuoso-users] Subgraphs or SPARQL views
HI Mohammed, I'm Mohamed Morsey, I'm one of the DBpedia developers team of Leipzig university, and I'm currently working in DBpedia live. We divide the triples of DBpedia live into 2 separate parts, one part for dynamic triples, i.e. the triples that should be updated upon live extraction, in which we place in one graph. And another part for static triples, that we place in another graph. The problem now is SPARQL query the user should specify 2 FROM clauses for each graph, and we want avoid that issue, may be by using something like a subgraph or making something like a relational database view that combine both of these graphs, and then use it in Default Graph URI, so I'm asking if any of this features apply and if so, how can I achieve this. I am discussing various options with the developers here to see what is the best way to do this. We will do some experiments to verify these solutions and see which is the most optimal to use. I will contact you privately to get some more background information and sample data for us to look at. Patrick
Re: [Virtuoso-users] bif:contains function not working
Hi Dimitris, i have a problem with the bif:contains function. It does not work and i could find if there is any configuration options to enable it. Server/Virtuoso: version 06.01.3127, on Linux (x86_64-pc-linux-gnu), Single Edition SPARQL Endpoint: http://el.dbpedia.org/sparql For the same query, the bif:contains function does not return any results, while with Filter regex does e.g. PREFIX rdfs: http://www.w3.org/2000/01/rdf-schema# A) select ?o ?l where { ?o rdfs:label ?l. ?l bif:contains Linux.} B) select ?o ?l where { ?o rdfs:label ?l. FILTER(regex(?l,Linux)).} I tested the (A) option in the dbpedia.org/sparql and it works fine Execute urls A) http://el.dbpedia.org/sparql?default-graph-uri=http%3A%2F%2Fel.dbpedia.orgshould-sponge=query=PREFIX+rdfs%3A+%3Chttp%3A%2F%2Fwww.w3.org%2F2000%2F01%2Frdf-schema%23%3E%0D%0A%0D%0Aselect+%3Fo+%3Fl+where+ {%0D%0A%3Fo+rdfs%3Alabel+%3Fl.%0D%0A%3Fl+bif%3Acontains+%22Linux %22.%0D%0A}format=text%2Fhtmldebug=ontimeout= B) http://el.dbpedia.org/sparql?default-graph-uri=http%3A%2F%2Fel.dbpedia.orgshould-sponge=query=PREFIX+rdfs%3A+%3Chttp%3A%2F%2Fwww.w3.org%2F2000%2F01%2Frdf-schema%23%3E%0D%0A%0D%0Aselect+%3Fo+%3Fl%0D%0Awhere+ {%0D%0A%3Fo+rdfs%3Alabel+%3Fl.%0D%0AFILTER%28regex%28%3Fl%2C%22Linux %22%29%29.%0D%0A}format=text%2Fhtmldebug=ontimeout= It looks like you did not initialize the RDF freetext index. To create index on all triples just perform the following command using isql: DB.DBA.RDF_OBJ_FT_RULE_ADD (null, null, 'All'); Then force a synchronization: DB.DBA.VT_INC_INDEX_DB_DBA_RDF_OBJ (); Please read: http://docs.openlinksw.com/virtuoso/sparqlextensions.html Best regards, Patrick
Re: [Virtuoso-users] bif:contains function not working
Hi Dimitris, Sorry, it was easy after all :) now, something extra, we have about 3-4M triples that we update occasionally by clearing the gragh and inserting the new triples. 1) does the index affect the clear/update procedure? and if it does, are there any commands to call before / after to speed it up Virtuoso maintains its free-text indexes either in real-time, or in batch mode. See paragraph 16.3.1.2. Time of Indexing from: http://docs.openlinksw.com/virtuoso/sparqlextensions.html In this case what you could do is set the index to manual mode: DB.DBA.VT_BATCH_UPDATE ('DB.DBA.RDF_OBJ', 'ON', 10); before doing the delete/load sequence and then afterwards run the: DB.DBA.VT_INC_INDEX_DB_DBA_RDF_OBJ (); to force another synchronization. 2) (a little out of topic), but i read somewhere that by disabling the http host the update is much faster. Is there a function to call from a script? e.g. disable http (maybe disable index) clear / update (re-enable index) enable http Of course loading is quickest when it does not have to wait for any locks left by long running sparql queries, however in most cases they can co-exist. If you really want to stop/start the http server, there are two new functions in the upcoming VOS release: http_lock(); http_unlock(); which can be used to accomplish this. I would recommend you also set in your virtuoso.ini: [HTTP Server] MaintenancePage = atomic.html This static page that should go into the vsp directory in your virtuoso installation, will be send to any client for as long as the http server is locked using a 503 Service temporary unavailable status, to let them know to try again later. Best regards, Patrick
Re: [Virtuoso-users] bif:contains function not working
HI Dimitris, Sorry, it was easy after all :) now, something extra, we have about 3-4M triples that we update occasionally by clearing the gragh and inserting the new triples. 1) does the index affect the clear/update procedure? and if it does, are there any commands to call before / after to speed it up Virtuoso maintains its free-text indexes either in real-time, or in batch mode. See paragraph 16.3.1.2. Time of Indexing from: http://docs.openlinksw.com/virtuoso/sparqlextensions.html In this case what you could do is set the index to manual mode: DB.DBA.VT_BATCH_UPDATE ('DB.DBA.RDF_OBJ', 'ON', 10); Oops, this should be: DB.DBA.VT_BATCH_UPDATE ('DB.DBA.RDF_OBJ', 'ON', NULL); before doing the delete/load sequence and then afterwards run the: DB.DBA.VT_INC_INDEX_DB_DBA_RDF_OBJ (); to force another synchronization. 2) (a little out of topic), but i read somewhere that by disabling the http host the update is much faster. Is there a function to call from a script? e.g. disable http (maybe disable index) clear / update (re-enable index) enable http Of course loading is quickest when it does not have to wait for any locks left by long running sparql queries, however in most cases they can co-exist. If you really want to stop/start the http server, there are two new functions in the upcoming VOS release: http_lock(); http_unlock(); which can be used to accomplish this. I would recommend you also set in your virtuoso.ini: [HTTP Server] MaintenancePage = atomic.html This static page that should go into the vsp directory in your virtuoso installation, will be send to any client for as long as the http server is locked using a 503 Service temporary unavailable status, to let them know to try again later.
Re: [Virtuoso-users] SPARQL Update string literals
Hi Lars, I'm sending the following SPARQL Update statement to Virtuoso: insert data into file:/C:/Bouvet/OntopiaServer/apache-tomcat/common/ classes/ifs.xtm { http://psi.ontopia.net/customers/ifs/ su5566629993 http://www.w3.org/2000/01/rdf-schema#label MM'S LUNCH CATERING .http://psi.ontopia.net/customers/ifs/ su5566629993 http://www.w3.org/1999/02/22-rdf-syntax-ns#type http://psi.ontopia.net/customers/ifs/supplier . } To which Virtuoso replies: 37000 Error SP030: SPARQL compiler, line 0: Unterminated short double-quoted string at '' SPARQL query: insert data into file:/C:/Bouvet/OntopiaServer/apache-tomcat/common/ classes/ifs.xtm { http://psi.ontopia.net/customers/ifs/ su5566629993 http://www.w3.org/2000/01/rdf-schema#label MM'S LUNCH This makes me think the '' character is the problem. The BNF given here doesn't define the String production: http://docs.openlinksw.com/virtuoso/rdfsparql.html However, according to production [88] here, it's definitely legal: http://www.w3.org/Submission/SPARQL-Update/#rSTRING_LITERAL2 As far as i can see this issue has been resolved in the upcoming release of VOS: $ isql SQL sparql insert data into file:/C:/Bouvet/OntopiaServer/apache- tomcat/common/classes/ifs.xtm { http://psi.ontopia.net/customers/ifs/su5566629993 http://www.w3.org/2000/01/rdf-schema#label MM'S LUNCH CATERING .http://psi.ontopia.net/customers/ifs/su5566629993 http://www.w3.org/1999/02/22-rdf-syntax-ns#type http://psi.ontopia.net/customers/ifs/supplier . } ; callret-0 VARCHAR ___ Insert into file:/C:/Bouvet/OntopiaServer/apache-tomcat/common/ classes/ifs.xtm, 2 (or less) triples -- done 1 Rows. -- 22 msec. SQL sparql select * from file:/C:/Bouvet/OntopiaServer/apache-tomcat/ common/classes/ifs.xtm where {?s ?p ?o}; s p o VARCHAR VARCHAR VARCHAR ___ http://psi.ontopia.net/customers/ifs/ su5566629993 http://www.w3.org/1999/02/22-rdf-syntax-ns#type http://psi.ontopia.net/customers/ifs/supplier http://psi.ontopia.net/customers/ifs/ su5566629993 http://www.w3.org/2000/01/rdf-schema#label MM'S LUNCH CATERING 2 Rows. -- 1 msec. Note that the next VOS release is scheduled to happen over the next few days. Patrick
Re: [Virtuoso-users] No of graphs created and performance
HI Abhi, In my project, when I persist an entity I create a new graph for each entity persisted. Will the performance degrade due to the huge no of graphs crated? This depends how queries are written and what is the distribution of the data is. Principally performance would not degrade with large numbers of graphs, however the database size would be a bit larger due to the number of duplicate triples in many distinct graphs. As long as you have adequate memory in your system, this should not matter. Without knowing more about your data, the biggest problem might come from performing queries without a graph, as this would return duplicates if triple patterns are contained in different graphs. Intuitively this might trigger you to use a DISTINCT clause, but on a large result set this will have an impact on performance. Best regards, Patrick --- OpenLink Software
Re: [Virtuoso-users] sparql and conductor on different port
HI Pierre, Next you add a New directory to this line, click on Type radio button and choose Sparql access point from the dropdown list and press Next button. Set Path to /sparql and press the Save Changes button to store. At this point you have created: http://my.example.com:8080/sparql I followed your procedure and it works fine, thanks ! However I see that by default the new sparql endpoint is run under the user 'dba'. I was therefore wondering if it would not be more secure to create a new user dedicated to this sparql endpoint and having only rights to retrieve data (not insert or update). Is this correct ? There is no need to do this as this is already done. Even though the endpoint is run as dba, it is not calling a .vsp page (think .php and other dynamic pages which mix html with scripting language) but it is calling a service /!sparql which is a build-in service in the virtuoso server. First thing this service does is to sudo to the SPARQL user. This SPARQL user by default does not have permissions the add/modify/ delete data in the database, unless specifically granted. Patrick
Re: [Virtuoso-users] sparql and conductor on different port
Hi Pierre, Although I have been looking through the documentation, I could not find if it is possible to have the sparql endpoint on a different port than the conductor ? For security reason I would like to keep my conductor listening on a different port and be able to publish my sparql endpoint on port 80 (or os). If that is not possible, I would be interested in the feedback on the approach taken by projects already using virtuoso (bio2rdf? dbpedia ?) Virtuoso's web server has the capability to create extra listeners using the conductor interface which is documented here: http://docs.openlinksw.com/virtuoso/htmlconductorbar.html#admui.internetdomains At install time you have your HTTP Server port in your virtuoso.ini set to 8890, which you want to keep in your local network as this contains ALL the endpoints that you have registered in Virtuoso. So as long as you do not open this port in your firewall, you can only get at it from the local machine. Next you create a new vhost entry using the EXTERNAL name of your machine and use port 80 (or a higher port if you do not want to run as root) e.g: Interface: 0.0.0.0 Port: 8080 Http Host: my.example.com Next you add a New directory to this line, click on Type radio button and choose Sparql access point from the dropdown list and press Next button. Set Path to /sparql and press the Save Changes button to store. At this point you have created: http://my.example.com:8080/sparql which functions exactly the same as your internal http://localhost:8890/sparql . You can now open your firewall and allow outside machines to connect to port 8080 so people can use your sparql endpoint without access to any other endpoint on your virtuoso installation. You should probably also change your virtuoso.ini so: [URIQA] DefaultHost = my.example.com:8080 If you use port 80, you do not have to add :80 at the end of this setting, although it should not make any difference. You can now add other directories / endpoints to the new my.example.com interface you just created e.g. a nice / directory that points to a index.html which describes your site etc. Patrick --- OpenLink Software
Re: [Virtuoso-users] nquads dump -- and possible bug in rdfbox.c
Hi William, I've adapted some of the example routines for doing an nquads dump and load, the recipe is here: https://bitbucket.org/ww/virtuoso/src/tip/sql/nq_dump.sql One thing that I encountered is there seems to be no good way to tell if a variable is a blank node from within a stored procedure, I had to resort to printing it into a temporary buffer using http_nt_object and checking if it starts with a 'b'. This is important because nquads, unlike ntriples, wants blank nodes to start with '_:'. I think you can use the function: is_bnode_iri_id (val) which will return 1 if it is a bnode, else 0 So it's slightly kludgy but it works. However I believe I may have found a bug in rdfbox.c, the function http_nt_write_obj(). This only seems to surface with terms that have xsd:gYear as datatype, but it seems like both the case statement and the switch below it obtain, causing the datatype to be printed out twice. So we get output like this: http://bnb.bibliographica.org/entry/GB5001806 http://purl.org/dc/terms/issued 1950-01-01T00:00:00Z^^http://www.w3.org/2001/XMLSchema#gYear^^http://www.w3.org/2001/XMLSchema#gYear http://bnb.bibliographica.org/entry/GB5001806 . (all on one line, obviously). If I have identified the bug correctly, hopefully there is still time for a fix to make it into the next opensource release? Thank you for reporting this. I will make sure it is fixed in the upcoming release. Patrick OpenLink Software
Re: [Virtuoso-users] Problem adding external datasource
Hi Claus, As I've seen on the list that someone recently managed to get RDF views working with spatial queries, I also wanted to give it another try. However, when I go to: Conductor-Database-External Data Sources - Configure Data Sources then whenever I click on any of the add dsn buttons (user, system, file) I do not get a form - instead I get the following error: HZ000VD017: Cannot get installed drivers in v:form dsn_new (render) I know that I have already been beyond this step a few months ago. So I wonder what or whether I did something wrong this time. (Maybe some path needs to be configured?) The ODBC config is working from php. My Virtuoso version is: OpenLink Virtuoso Universal Server (Enterprise Edition) Version 06.02.3128-pthreads as of Nov 15 2010 Compiled for Linux (x86_64-generic-linux-glibc25-64) Hosted Runtime Environments: VDB Copyright (C) 1998-2010 OpenLink Software Virtuoso gets a list of installed drivers using an ODBC API call which in turn retrievss this information from the odbcinst.ini file. Since you reported you already passed this point before, it would suggest you have an odbcinst.ini file somewhere, but not in the default place for your platform (commonly /etc/odbcinst.ini on Unix/ Linux) and have not set an ODBCINSTINI environment variable to point to your file. Last possibility is that there is a typo in your odbcinst.ini file so the api cannot find a section called [ODBC Drivers]. Here is a sample of what an odbcinst.ini file should look like: [ODBC Drivers] OpenLink Virtuoso = Installed OpenLink Virtuoso (Unicode) = Installed [OpenLink Virtuoso] Driver = /opt/virtuoso/lib/virtodbc_r.so [OpenLink Virtuoso (Unicode)] Driver = /opt/virtuoso/lib/virtodbcu_r.so Hope this solves your issue.
Re: [Virtuoso-users] Support for Lines and Polygons in Virtuoso's Geospatial Extensions
Hi Jamey, In playing with a trial copy of Virtuoso 6.2 (Commercial Edition), I've noticed that it appears that its geospatial capabilities only cover points. For example: SQL select st_geomfromtext('LINESTRING(3 4,10 50,20 25)'); *** Error 37000: [Virtuoso Driver][Virtuoso Server]GEO..: Bad geometry syntax LINESTRING(3 4,10 50,20 25), only formats like point(12 23) are allowed. Am I correct in interpreting this to mean that there is currently no support for lines, polygons, etc? And if so, are there any plans to add such capabilities? There is currently only support for geo POINT data in Virtuoso Commercial Edition. We have already drawn up some plans to add other types like LINES, POLYGON etc, but we have not yet had sufficient feedback or commercial incentive to move it more to the front of our development queue. However given the right signals from the marketplace we can certainly re-prioritize this effort. Best regards, Patrick
Re: [Virtuoso-users] Trippi connector
Hi Alex, This one goes to Virtuoso devs. Is there a release or are there plans to develop a Trippi Connector for Virtuoso Triple Store? http://trippi.sourceforge.net/implementation-guide.html I would like to test Fedora Commons Repository backed by Virtuoso OS both as its relational database and as its resource index (triple store) to reduce number of components, the former through JDBC and the later through Trippi (I believe it is the only way). As I already have a Virtuoso OS instance running with dbpedia loaded, I think it makes sense to use it for the Fedora triples about the Digital Objects in the repository so later I can do some nice reasoning using both graphs. Details: https://wiki.duraspace.org/display/FCR30/Installation+and+Configuration+Guide #InstallationandConfigurationGuide-OtherDatabases https://wiki.duraspace.org/display/FCR30/Resource +Index#ResourceIndex-Configuration We will have a look at this API to see how difficult it is to write an adapter for Virtuoso in it. Note that we already support Jena and Sesame for Virtuoso, as well as the possibility to use the SPASQL protocol to embed SPARQL/SPARUL queries direct inside JDBC statement execution. See: http://ods.openlinksw.com/dataspace/dav/wiki/Main/VOSRDFDataProviders http://docs.openlinksw.com/virtuoso/VirtuosoDriverJDBC.html#jdbc3features Note that Virtuoso also has a full ODBC based driver that can handle both relational queries and SPARQL queries (using SPARQL) as detailed in: http://docs.openlinksw.com/virtuoso/odbcimplementation.html#odbcimplementationext Patrick
Re: [Virtuoso-users] BUG Ubuntu 64bits -- GPF: bitmap.c:1552 next/prev of non-valid bit pos
HI Remi, It is my first post on this mailing list so do not hesitate to tell me if you need more information or anything else ;) Here is the trouble, after starting Virtuoso on an ubuntu server, and after a while (a day or so) I got this error : 04:34:49 Checkpoint started 04:35:05 Checkpoint finished, log reused 05:00:29 GPF: bitmap.c:1552 next/prev of non-valid bit pos GPF: bitmap.c:1552 next/prev of non-valid bit pos I guess it should be du to a configuration parameter but it is based on the config file to run a Dbpedia dataset... It looks like an I/O disk problem to me... What do you think? Please let me know the version of Virtuoso you are using, so i can cross check if this is a known issue and in which version this is/will be resolved. You should be able to get this information from the .deb package you used, or just run: virtuoso-t -? and report the first couple of lines. Patrick
Re: [Virtuoso-users] Installing open source viruoso
Hi Luka, I am trying to create a web application in PHP which would use a semantic storage. Virtuoso seems the most powerful tool to use but I have problems and questions regarding it's installation... I'm using WinXP 32b and I can't figure out the easiest way to install it. I don't need the source code because I don't intend to modify and build it. I found and downloaded http://sourceforge.net/projects/virtuoso/files/virtuoso/6.1.2/virtuso-opensource-win32-6.1.2.zip/download but I can't find a simple instructions how to install. Please, could someone provide me some links to tutorials how to start? I think you should start with reading this document: http://virtuoso.openlinksw.com/dataspace/dav/wiki/Main/VOSUsageWindows Patrick
Re: [Virtuoso-users] virtuoso-opensource-6.1.2.tar.gz: broken or out of date vad packages?
Hi Martin, We download the virtuoso-opensource-6.1.2.tar.gz snapshot from sourceforge, and installed the debian package in it on a debian (lenny) Linux system. In contradiction to the product working fine so far, we have some issues with the vad packages that come with the snapshot. Installing from conductor the package 'Demo' (version 1.107.34) crashed (my thanks to Hugh Williams who provided me a more recent version, 1.107.66, that installs well) There are no patches for building the demo vad package between the development tree and the 6.1.2 snapshot. All packages are loaded into a clean database as part of the 'make check' command in the demo directory. This is done prior to every source release. We are performing some checks to see if we can determine what could have failed building this vad using the debian build method. We will let you know as soon as we find any issue and will make sure this is fixed in the next release of VOS. Package 'doc' (version 1.1.18) seems to be incomplete - the local pdf is missing (a minor issue, I agree, but a symptom?) That is because the build process to produce the pdf document is a bit peculiar and i think needs some tools not available on every platform. We are trying to see if we can fix this for some upcoming release. This document can always be downloaded from: http://docs.openlinksw.com/pdf/virtdocs.pdf For the full documentation you can always go to: http://docs.openlinksw.com/virtuoso this site always has the most up-to-date documentation and will certainly be newer than the snapshot. - topics are missing (RDF Data Access and Data Management is topic 14 rather than 16 in http://docs.openlinksw.com/virtuoso/ - 2 topics missing) There are some chapters missing from the documentation that have to do with functionality that is only available in the commercial version of the documentation. The documentation on docs.openlinksw.com are the full set of docs, including chapters on Clusters, Geo Index, Virtual Database and Replication. For list of differences between Commercial and Open Source edition, please also read: http://virtuoso.openlinksw.com/features-comparison-matrix/ - in the RDF Data Access and Data Management topic (the one I'm interested in to start with), chapters are missing ('Extensions' - really useful, and: this functionality is available in the build) Please use the online docs for now. The upcoming release 6.1.3 will include a new snapshot of the documentation. Did someone else have the same experience with vad packages in this snapshot? Are the vad packages in the snapshots not always in sync with the product? Is there a general advise on installing vad packages? They are in sync with what was available in source form at the time the snapshot was produced. Patrick
Re: [Virtuoso-users] Virtuoso SQL, how can I get the last insert ID? (dentity)
Hi Matthew, Normally I’d use a PDO function for this but it says it isn’t supported for this database.. I am trying to migrate data over from SQL server and other sources but need to adjust table relationships to new identity keys. I think you are looking for the identity_value() function. For a complete description please read: http://docs.openlinksw.com/virtuoso/fn_identity_value.html http://docs.openlinksw.com/virtuoso/CREATETABLE.html#identity Patrick
Re: [Virtuoso-users] Backup_online malformed command appears to HANG server
HI Roosevelt, running a backup_online command with a dot ('.') left a pending process. And after issuing a backup_context_clear() the whole server seemed to hang. Below the step to do it: Done. -- 271 msec. SQL backup_context_clear(); Done. -- 271 msec. SQL backup_online('./bkp_',1); Done. -- 271 msec. SQL backup_context_clear(); I will provide you with a patch for this issue shortly, but you should know you should not have a path in the backup prefix at all, since this can also makes it more difficult to restore a database if the backups are in a different location. As recommended, please use: backup_online ('bkp_', 100); which accomplishes the same thing. If you want to write into a specific directory, you must use the following: backup_online ('bkp_', 100, 0, vector('/backup/virtuoso')); Please see also: http://docs.openlinksw.com/virtuoso/fn_backup_online.html Patrick
Re: [Virtuoso-users] does backup_online() do a checkpoint internally?
Hi Aldo, By looking at the checkpoint audit trail I can inferr that each time backup_online() is run, it will create a checkpoint. It also makes sense from an intuitive standpoint. However, by looking at the docs, I found this snippet: SQL backup_context_clear (); SQL checkpoint; SQL backup_online ('virt-inc_dump_#', 150); ( from: http://docs.openlinksw.com/virtuoso/ databaseadmsrv.html#backup ) Note the explicit call to checkpoint. What's the official answer? It has implications when trying to restore from backup + audit trail ( to find the point in which they match ). Actually backup_context_clear and backup_online both do an implicit checkpoint and if CheckpointAuditTrail is enabled this already switches to a new transaction log file. The backup_context_clear () command should ONLY be used when you want to start a complete new full backup of your database. Repeated calls to backup_online ('virt_inc_dump_#', 100); insert more data in the database delete some data from the database backup_online ('virt_inc_dump_#', 100); will only backup any changes. This backup_online command can be put into the virtuoso scheduler, so at regular intervals the incremental backup is updated and new backup sequence files are created. Since backup_online does an implicit checkpoint before temporarily disabling further checkpointing while the backup is running, there is no need to perform an explicit call to checkpoint. However it does NO harm if you do. Patrick
Re: [Virtuoso-users] php hosting with virtuoso on Leopard
HI David, I'm am not having success in getting php hosting up on Mac OS 10.5. Following the instructions here http://virtuoso.openlinksw.com/dataspace/dav/wiki/Main/VOSBldPHP , I am getting a link error. I can't figure out how to get a dylib out of the php build process. configure:23970: /usr/bin/gcc-4.0 -o conftest -O2 -arch ppc -I/opt/ local/include -I/Users/virgin ia/php53/include/php/main -I/Users/virginia/php53/include/php/Zend -I/ Users/virginia/php53/inclu de/php/TSRM -I/Users/virginia/php53/include/php -L/opt/local/lib -arch ppc conftest.c -L/Users/ virginia/php53/lib -lphp5 5 ld: in /Users/virginia/php53/lib/libphp5.so, can't link with bundle (MH_BUNDLE) only dylibs (MH_ DYLIB) collect2: ld returned 1 exit status Please note that the php hosting code in virtuoso not been verified to work with PHP 5.3.3 at this time. We have tested versions upto 5.2.14 as most applications in PHP work on on the 5.2.X line without modifications, which may not be the case for 5.3.X. any ideas on the proper build flags and where to add them to the build process (acinclude.m4 maybe?)? Can you send me by private email the following information: 1. From your php build the config.nice file 2. From your virtuoso vos build the config.nice file Hopefully this has recorded the exact CFLAGS settings etc you used to build both. Also did you do any special steps for configuring and building php? Initial testing at my location did not show any strange build issues, but it is very dependent on flags etc used, which is why i need more info from you in order to help. Patrick
Re: [Virtuoso-users] Problems loading the DBpedia dump (very long URIs)
Hi Jörn, after having a lot trouble with our group internal DBpedia mirror, I decided to do a fresh install. I downloaded all the files (we only need a subset of the dbpedia: {en,de}) and followed this guide yesterday: http://virtuoso.openlinksw.com/dataspace/dav/wiki/Main/VirtBulkRDFLoaderExampleDbpedia It uses the http://virtuoso.openlinksw.com/dataspace/dav/wiki/Main/VirtBulkRDFLoaderScript to load the dumps (btw: the script could greatly benefit from a few comments). Now today I found these lines in the logs: 23:33:20 PL LOG: Loader started Sat Aug 07 2010 00:06:49 PL LOG: File /usr/local/data/dbpedia/3.5.1/en/external_links_en.nt.gz error 23000 SR133: Can not set NULL to not nullable column 'DB.DBA.RDF_QUAD.O' 00:32:56 Checkpoint started 00:34:39 Checkpoint finished, log reused 02:05:30 PL LOG: File /usr/local/data/dbpedia/3.5.1/en/ page_links_en.nt.gz error 23000 SR133: Can not set NULL to not nullable column 'DB.DBA.RDF_QUAD.O' 02:47:44 PL LOG: No more files to load. Loader has finished, So I went to investigate where this comes from and it seems that inside the ld_file procedure of the VirtBulkRDFLoaderScript the error is caught. It uses the TTLP procedure to load the data. 1. Is there a possibility to for example get the line number where the error occurred? I did a few checks on the external_links_en.nt.gz file with zcat and grep and I think that a very long URL is the problem (see appendix). The loader process creates a table called load_list which records which datasets where not loaded completely and for what reason. Please try: select * from load_list where where ll_error is not null; This should give you good indication of what is going on, including the line number where the failure happened. 2. Can I somehow tell virtuoso not to quit TTLP on such lines, but to either ignore or truncate them? There are some flags to the TTLP code that would probably skip this errror, but in certain cases that could insert partial data into the database, which is much harder to clean up, so we have not made it default. 3. How much data was not inserted? The error handler calls a rollback work, but it seems that in the rdf_loader_run procedure a commit work is done only after every 100 files loaded, which would mean that all which was inserted before is lost? At the same time log_enable(2, 1) is set, which means autocommit for every row, no log, so why is there a commit at all? The commit is there because you can overrule the log_enable when calling the rdf_loader_run call. Since you did not, it was on autocommit so all the triples loaded before the bad triple have been committed. 4. How do I continue? Can I simply restart with just these two files after fixing? When you have found the offending line, you can dump all the remaining triples of this file to a new file and just load that partial result. Since all records before this point in the file are already in, that should complete without this one bad record. Appendix: === did a few checks: == SPARQL select count(*) where { ?s http://dbpedia.org/property/reference ?o . }; results in: 348955 At the same time the external_links_en.nt.gz file has: 5081932 lines (zcat external_links_en.nt.gz | wc -l) The corresponding lines in the file look like this (zcat external_links_en.nt.gz | cat -n | head -n $((348955+1)) | tail -n 2 ): 348955 http://dbpedia.org/resource/Fourteen_Points http://dbpedia.org/property/reference http://wwi.lib.byu.edu/index.php/ President_Wilson's_Fourteen_Points . 348956 http://dbpedia.org/resource/Fourteen_Points http://dbpedia.org/property/reference http://www.mtholyoke.edu/acad/intrel/doc31.htm . Notice the 's in line 348955, but actually as we got 348955 triples, the problem should've occured in the line after that one, but in line 348956 I see nothing wrong. Also notice that sparql select * where { http://dbpedia.org/resource/Fourteen_Points http://dbpedia.org/property/reference ?o .}; results in: http://www.loc.gov/exhibits/treasures/trm053.html http://wwi.lib.byu.edu/index.php/Main_Page http://wwi.lib.byu.edu/index.php/President_Wilson's_Fourteen_Points http://www.mtholyoke.edu/acad/intrel/doc31.htm http://www.ourdocuments.gov/doc.php?flash=truedoc=62 http://web.jjay.cuny.edu/jobrien/reference/ob34.html So line 348956 is imported. Using nested intervals i found this: 356036 http://dbpedia.org/resource/Antisocial_personality_disorder http://dbpedia.org/property/reference http://www.faculty.missouristate.edu/M/MichaelCarlie/what_I_learned_about/GANGS/WHYFORM/pathological.htm . 356037 http://dbpedia.org/resource/Hugo_Simberg http://dbpedia.org/property/reference
Re: [Virtuoso-users] In SQL how can I reference my tables?
HI Matthew, It shows my database studies at the same level as DB, PUMP, UDDI, VAD, etc. Clicking down to the tables, it shows them as: studies.DBA.studies I used the default DBA account (for now). I didn't modify any defaults of installation from the tarball, to keep things simple. But SELECT * FROM studies.DBA.studies; still returns the same syntax error as did SELECT * FROM studies..studies; Under the Interactive SQL tab, SELECT * FROM studies..studies; works fine.. So, does this mean Virtuoso is somehow seeing it differently from my php script: ?php $dbc = odbc_connect('virtuoso','dba','dba'); $(!$dbc) { exit(Failed!\n); } $sql = SELECT * FROM studies..studies;; $rs = odbc_exec($dbc, $sql); When using the isql tool, you need to use a semi colon, so the parser knows when it has reached the end of the statement. In ODBC you should not use a semicolon, unless you want a compound statement, which in this case you do not have. So please use: $sql = SELECT * FROM studies..studies; Patrick -Original Message- From: Ted Thibodeau Jr [mailto:tthibod...@openlinksw.com] Sent: Friday, August 06, 2010 10:11 AM To: Matthew Tedder Cc: virtuoso-users@lists.sourceforge.net Subject: Re: [Virtuoso-users] In SQL how can I reference my tables? Hi, Matthew -- On Aug 6, 2010, at 08:42 AM, Matthew Tedder wrote: So the PHP odbc_connect() method seems to connect, because I get SQL errors. Can anyone tell me how to at least select from these tables.. I created them using isql like this: USE studies; CREATE TABLE studies ( ...); But the following variations give SQL errors: USE studies; SELECT * FROM studies; SELECT * FROM studies.studies; SELECT * FROM studies..studies; SELECT * FROM DB.studies; SELECT * FROM DB.studies.studies; To keep working, I made a mirror of these tables in MySQL and so that's what I am working with now. I am already past my deadline. As a last resort I might end up setting up a PHP ARC -based SPARQL endpoint and dumping to that, periodically from the tables. But that won't scale and has other limitations. But I kinda feel not so good. I got excited reading about Virtuoso and now everyone's looking at me. We're looking at possibly moving a lot over to it, including VIVO (researchers and their publications-currently using Sesame/Jena), a huge clinical data repository, and others. I feel so close to breaking the egg-shell that can open up a huge new world of uses.. but also stressed with a very short timeline. It seems that you're trying to learn a lot of new things all at once, and that they're mixing up together and confusing each other. Telling us that the following variations give SQL errors doesn't give us much with which to debug the issue -- because we don't know whether the errors are identical in all cases, nor even what the single error is (unless it's a repeat of the original you reported?) ... Do you have a Web browser? Can you use it to target the Virtuoso Conductor (the web-based Admin interface)? By default, you'll find it somewhere like -- http://localhost:8890/conductor/ -- or -- http://virtuoso-host.example.com:8890/conductor/ -- with a different port, if you've changed [HTTPServer]:ServerPort (*NOT* [Parameters]:ServerPort) during installation or by manually editing the virtuoso.ini. Log in, and drill down to the Database area. You should be able to see where your tables are -- and thus how to identify them in your SQL queries. This documentation section may help you out -- http://docs.openlinksw.com/virtuoso/htmlconductorbar.html Hope that helps, Ted -- A: Yes. http://www.guckes.net/faq/ attribution.html | Q: Are you sure? | | A: Because it reverses the logical flow of conversation. | | | Q: Why is top posting frowned upon? Ted Thibodeau, Jr. // voice +1-781-273-0900 x32 Evangelism Support // mailto:tthibod...@openlinksw.com // http://twitter.com/TallTed OpenLink Software, Inc. // http:// www.openlinksw.com/ 10 Burlington Mall Road, Suite 265, Burlington MA 01803 http://www.openlinksw.com/weblogs/uda/ OpenLink Blogs http://www.openlinksw.com/weblogs/ virtuoso/ http://www.openlinksw.com/blog/~kidehen/ Universal Data Access and Virtual Database Technology Providers -- This SF.net email is sponsored by Make an app they can't live without Enter the BlackBerry Developer Challenge http://p.sf.net/sfu/RIM-dev2dev ___ Virtuoso-users mailing list Virtuoso-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/virtuoso-users
Re: [Virtuoso-users] Examples of how to connect SQL from PHP (under apache)?
HI Matthew, Thank you for trying to point me toward help but I am still at a loss at how to connect to Virtuoso from PHP under Apache. I cannot use Virtuoso as a webserver for lack of Shibboleth support and so __virt_internal_dsn() is of no use to me. It might be possible to build a hybrid apache/mysql/ php and virtuoso/php application (separated the public and secure areas, accordingly) and using web services between the two. The _virt_internal_dsn() function is only usable when you use the internal hosted version of PHP as this provides an extra security layer as you do not have to put the password inside your .php source file, which normally needs to be changed very time you change your dba password. If you had looked beyond that fact, you would have noticed the page uses standard odbc_connect calls to make a connection. You can use any Apache/PHP combination from your favorite distribution as long as it is build with ODBC support which is normally built into any Linux disto and many others. In some cases PHP ODBC support is an optional package which you need to install. There is no other difference between running Virtuoso/PHP and Apache/ PHP/Virtuoso from a programming point of view. There has got to be some way to do this.. some documentation somewhere.. I cannot imagine that the only way for a php app to connect is by running under virtuoso's webserver, lacking such a wealth of capabilities. I am getting pretty tired of searching, reading, testing ideas, and coming up empty-handed. There must be some way. As said in my previous mail, Virtuoso uses the ODBC API for connections. This means that any programming language that has an ODBC binding can use it. Many languages like perl, php, python, ruby etc have a working ODBC layer either build in, or through an extension package. This layer uses one of the ODBC Driver Managers like iODBC or unixODBC to connect with any target database through a specific ODBC Driver, in this case using the virtodbc_r.so driver. There is plenty of documentation on making an ODBC connection to PHP, available on both the PHP site and others. Very simply put: 1. Create an ODBC DSN Edit the file /etc/odbc.ini and add the following data there (obviously putting the full pathname to your virtodbc_r.so file into this line) [Local Virtuoso] Driver = /path/to/your/lib/virtodbc_r.so Address = localhost: 2. Create a sample php script like below and put this into your apache directory: html body ?php // Make a connection $conn=odbc_connect('Local Virtuoso','dba','dba'); if (!$conn) {exit(Connection Failed: . $conn);} // Get a list of tables $sql=select TABLE_CATALOG, TABLE_SCHEMA, TABLE_NAME from INFORMATION_SCHEMA.TABLES; $rs=odbc_exec($conn,$sql); if (!$rs) {exit(Error in SQL);} // Show results in a table echo tabletr; echo thCatalog/th; echo thSchema/th; echo thTable Name/th/tr; while (odbc_fetch_row($rs)) { $catname=odbc_result($rs,TABLE_CATALOG); $schemaname=odbc_result($rs,TABLE_SCHEMA); $tablename=odbc_result($rs,TABLE_NAME); echo trtd$catname/td; echo td$schemaname/td; echo td$tablename/td/tr; } echo /table; // Close connection odbc_close($conn); ? /body /html 3. Connect with your browser to the created URL and you should get a list of tables. I hope this information help you get your project on track, if not sufficient, please let me know. Best regards, Patrick
Re: [Virtuoso-users] Examples of how to connect SQL from PHP (under apache)?
HI Matthew, I need to run my php app under apache for Shibboleth authentication. (If shibboleth can be done under virtuoso is something I need to ask later, as I need to just get some things done right now). Given enough incentive we may implement support for this at some point. We do already support SSO systems like OpenID, and WebID Is there an example anywhere on how to connect to a Virtuoso relational store? I presume to use generic ODBC and some port number, whatever it is? The port is listed in your virtuoso.ini file: [Parameters] ServerPort = You indeed can use ODBC to connect from your PHP application to Virtuoso. Please check out: http://docs.openlinksw.com/virtuoso/odbcimplementation.html http://www.openlinksw.com/dataspace/dav/wiki/Main/VirtuosoPHP It’s too bad there’s no PHP PDO (Portable Data Object) module for it.. because I generally prefer to use that. No biggy. There is of course pdo-odbc. Patrick
Re: [Virtuoso-users] Issues with Getting Started..
HI Matthew, My installations are on Debian Lenny w/ latest updates. I downloaded the tarball version, did ./configure make and sudo make install. That’s all very standard. I didn’t see any errors. Issue (1): But I don’t see any startup/shutdown scripts in or to put in / etc/init.d, certainly not where a anything I found on Google said they would be. I tried building one using: cd /usr/local/virtuoso-opensource/var/lib/virtuoso/db nohup /usr/local/virtuoso-opensource/virtuoso-t –f Is that correct? Yes that is correct, although it not needed to use nohup, the -f flag and the If you start virtuoso with: cd /usr/local/virtuoso-opensource/var/lib/virtuoso/db /usr/local/virtuoso-opensource/bin/virtuoso-t It will automatically put itself into the background as a detached process. The -f flag means run in the foreground, and the nohup and create a detached background process. Issue (2): While I see documentation on how to build an RDF view of relational tables and various SQL commands work like, create table (in isql), “create database” does not work.. I don’t see any way to create a database… not via isql nor the conductor web interface.. How is that done? And I saw nothing about it on the wiki. There’s a lot of nice stuff in there but it seems to skip the really basic, normal stuff… and I cannot find any tutorial anywhere on how to use Virtuoso as a relational SQL database.. much less from php. Any pointers would be greatly appreciated. Virtuoso uses separate schemas within a physical database. User accounts can default to a specific schema and grants are used to control who can see/do what within the database, just like any normal SQL RDBMS. To create a schema, you can just the isql tool or the conductor and use the USE command like: use mydb; create table test (id integer not null primary key, val varchar (32)) This will create a separate schema called mydb and switch over to it. All further commands are done within this schema unless fully qualified like: select * from db.dba.testtable; or select * from db..testtable; Did you already read this chapter: http://docs.openlinksw.com/virtuoso/sqlreference.html If you require completely separate physical databases, you can just create another directory (like /usr/local/virtuoso-opensource/var/lib/ virtuoso/db2 ) and put a separate virtuoso.ini configuration file in there. Edit it so it uses different ports for SQL and HTTP access. This way you can run multiple independent virtuoso instances. Issue (3): I hope connecting and working w/ Virtuoso via php won’t be too difficult. I wish there was examples or a tutorial for this. Please read this chapter from the wiki that explains how to build the PHP plugin and deploy it within Virtuoso: http://www.openlinksw.com/dataspace/dav/wiki/Main/ VirtuosoPHP#Developers:%20building%20Virtuoso%20Open-Source%20with %20PHP%20support Hope this gives you some starters. If not enough, just ask for more info. Patrick
Re: [Virtuoso-users] EF support improvements
Hi Alexander, And the last thing. What about EF4 support? We hope to roll first set of enhancements for this into virtuoso next week. Patrick
Re: [Virtuoso-users] source_uri for file resources in vad stickers
HI Jamey, The vad_sticker.dtd file in the Virtuoso source code (and the documentation at http://docs.openlinksw.com/virtuoso/VAD.html) appears to indicate that file resource elements in vad stickers will accept a source_uri attribute. When this attribute is populated, I would expect the VAD_PACK procedure to use it to determine where to obtain the actual file contents. But it does not appear to do so. From my reading of the code, VAD_PACK defers to VAD_TEST_CREATE, which does not have any logic to use the source_uri attribute (and instead always derives the source path from the target path). Is that a bug? Or am I misunderstanding the DTD and documentation? I'm attaching a modified version of the VAD_TEST_CREATE procedure to illustrate my question. It likely isn't entirely correct (since this is my first time attempting to modify Virtuoso procedures), but it does handle a simple case where the source_uri attribute is set for a file resource. (The modified portions involve the s5 variable.) We will be looking into this issue shortly. Patrick
Re: [Virtuoso-users] DB.DBA.RDF_GEO_FILL exits with error
Hi Claus, The first time the after a DB start DB.DBA.RDF_GEO_FILL () is called, the error occurs after less than a half a minute. On consecutive attempts it then only takes a few seconds. The error occurs independent of whether resources carry the virtuoso specific geo-literals. However, as already mentionend, adding those seems to be a workaround for that issue. This problem is fixed in the new build. I will contact you shortly where to get a new binary from. Patrick
Re: [Virtuoso-users] Mac re-install error
Hi Nico, I installed virtuoso already once on another server. But this time I have some problems while compiling. This files are not there, and they are not in the files I downloaded. The source archive does not have this file either, but sometimes external tools like editors etc create such local files. I will see if i can fix the script so it filters out such files in a following release of VOS. In the mean time, please perform the following commands: First we clean up the directory: cd binsrc/rdf_mappers gmake clean Next we check this unwanted file is there and remove it: cd main/xslt ls -l ._abmeta2rdfxml.xsl rm ._abmeta2rdfxml.xsl Next we rebuild the vad package: cd ../.. gmake Please let me know if this resolves your build problem. Patrick The output: = = STARTED RDF Mappers PACKAGING = Mon Jul 12 18:51:07 BST 2010 = Shutdown Virtuoso Server... VAD Sticker vad_dav.xml creation... VAD Sticker vad_fs.xml creation... Virtuoso.ini creation... Waiting Virtuoso Server start on port ... PASSED: Virtuoso Server successfully started on port ***FAILED: execution of DB.DBA.VAD_PACK('vad_fs.xml', '.', 'rdf_mappers_filesystem.vad') SQL ERROR - *** Error 42VAD: [Virtuoso Driver][Virtuoso Server]Inexistent file resource (./vad/vsp/rdf_mappers/xslt/main/._abmeta2rdfxml.xsl) in signal:(BIF), VAD.DBA.VAD_FAIL_CHECK, VAD.DBA.VAD_OUT_ROW_FILE, VAD.DBA.VAD_TEST_CREATE, DB.DBA.VAD_PACK, Top Level at line 0 of Top-Level: DB.DBA.VAD_PACK('vad_fs.xml', '.', 'rdf_mappers_filesystem.vad') PASSED: commit work PASSED: checkpoint ***FAILED: execution of DB.DBA.VAD_PACK('vad_dav.xml', '.', 'rdf_mappers_dav.vad') SQL ERROR - *** Error 42VAD: [Virtuoso Driver][Virtuoso Server]Inexistent file resource (./vad/vsp/rdf_mappers/xslt/main/._abmeta2rdfxml.xsl) in signal:(BIF), VAD.DBA.VAD_FAIL_CHECK, VAD.DBA.VAD_OUT_ROW_FILE, VAD.DBA.VAD_TEST_CREATE, DB.DBA.VAD_PACK, Top Level at line 0 of Top-Level: DB.DBA.VAD_PACK('vad_dav.xml', '.', 'rdf_mappers_dav.vad') PASSED: commit work PASSED: checkpoint Shutdown Virtuoso Server... = = Checking log file /data/virtuoso-opensource-6.1.0/binsrc/ rdf_mappers/make_rdf_mappers_vad.log for statistics: = = Total number of tests PASSED : 5 = Total number of tests FAILED : 2 = Total number of tests ABORTED : 0 = *** Not all tests completed successfully *** Check the file /data/virtuoso-opensource-6.1.0/binsrc/ rdf_mappers/make_rdf_mappers_vad.log for more information # egrep \* \*.*FAILED:|\*\*.*ABORTED: /data/virtuoso-opensource-6.1.0/binsrc/ rdf_mappers/make_rdf_mappers_vad.log make[2]: *** [rdf_mappers_dav.vad] Error 1 make[2]: Leaving directory `/data/virtuoso-opensource-6.1.0/binsrc/ rdf_mappers' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/data/virtuoso-opensource-6.1.0/binsrc' make: *** [all-recursive] Error 1
Re: [Virtuoso-users] how to run virtuoso without client
Hi Bin, I have virtuoso installed in a linux server, every time I have to log into the server from another pc using putty and run the virtuoso...but once the putty connection is disconnected, the virtuoso in the linux is terminated simultaneously, How can I keep the virtuoso running when I close the putty connection. Thanks a lot. It depends on how you start virtuoso. If you start with: virtuoso -f or virtuoso +foreground or virtuoso -f /tmp/log then virtuoso is running in the foreground and is attached to your terminal session. Some installations / shells will terminate all processes attached to the controlling terminal when the session ends. If for whatever reason you do want to keep virtuoso in the foreground (e.g. when you want to see the log output that it produces, i suggest you install the GNU screen program and run it from within a screen session. That will keep virtuoso running even if you close your putty session and allows you to re-attach back later. If you run virtuoso with: virtuoso or virtuoso +wait then virtuoso will automatically detach itself from the controlling terminal and fork itself into the background. Unless the administrator of your Linux machine has set special settings, it should remain running when your terminal session is closed. Patrick
Re: [Virtuoso-users] select statement and limit
Hi Nikolaos, I am using Virtuoso 6.1 as a relational database backend (so far). I see in the select statement reference http://docs.openlinksw.com/virtuoso/SELECTSTMT.html that the LIMIT construct (found e.g. in mysql) is not supported. How would I submit an sql query of the form: SELECT t FROM some_table ORDER BY t DESC LIMIT 1 OFFSET 50 is there a workaround for the LIMIT and OFFSET constructs in Virtuoso? If no, are there any plans to support LIMIT? You need to use the TOP function which is the SQL-92 compliant way of doing this e.g.: http://docs.openlinksw.com/virtuoso/SELECTSTMT.html#topselectoption SELECT TOP (50,1) t FROM some_table ORDER BY t DESC which will skip the first 50 records from some_table based on the ordering and returns just 1 record. Patrick
Re: [Virtuoso-users] HTTP-Proxy settings for Virtuoso Sponger
Hi Johannes, I'm trying to use a locally installed Virtuoso Sponger with both data from intranet and the internet. So far I can only use it to extract RDF from intranet sources. Is there a way to configure the Sponger to use an HTTP proxy for external URLs? This can be done on a request by request bases, or for all http client operations by changing your virtuoso.ini file and adding the following key: [HTTP] HTTPProxyServer = host:port Where host and port obviously point to the proxy server in your intranet server. Virtuoso supports both traditional HTTP proxies like squid, as well as socks4 and socks5 proxies. Please read the following page for more information and syntax: http://docs.openlinksw.com/virtuoso/fn_http_get.html Patrick
Re: [Virtuoso-users] Virtuoso server on Debian with apache proxying
Hi Nicolas, I followed your recommandation, still having the same issue. I had the message: Invalid command 'ProxyHTMLEnable' when restarting apache. In fact, it seems to be related to my problem, as response from html server systematically removed /virtuoso/. This module may not be installed by default on every distro and some older versions do not ship it at all. On Fedora i also had to install it separately. You can try searching for mod_proxy_html using apt-cache on Debian. After investigating on the web, I found the following hack: Have you tried leaving out ProxyHTMLEnable on entirely? I think that directive is new and not in the version in Ubuntu.Do put SetOutputFilter proxy-html in its place. I tried and ... it works ;) Going now investigating further to be sure that everything is OK. Good to hear. I will have a look what the difference between this and the ProxyHTMLUrlMap is. Thank you very much for providing me the configuration file. No problem. I will add this as a suggestion into the documentation so others may benefit. Patrick 2010/5/23 Patrick van Kleef vos.ad...@openlinksw.com Hi Nicolas, I'm trying to access virtuoso server through an apache server, using mod_proxy. Calling http://www.mysite.net/virtuoso, it should redirect on my local server on 88.191.91.72:8890 http://88.191.91.72:8890 NameVirtualHost 88.191.91.72 VirtualHost 88.191.91.72 ServerName www.mysite.net http://www.mysite.net ... ProxyRequests off Proxy * Order deny,allow Allow from all /Proxy ProxyPass /virtuoso/ http://172.16.12.128:8890/ ProxyPass /virtuoso http://172.16.12.128:8890 ProxyPassReverse /virtuoso/ http://172.16.12.128:8890/ ProxyPassReverse /virtuoso http://172.16.12.128:8890 ProxyTimeout 300 ProxyHTMLURLMap /virtuoso/ http://172.16.12.128:8890/ ProxyHTMLURLMap /virtuoso http://172.16.12.128:8890 ProxyPreserveHost On /VirtualHost But doing so, when trying to enter login and password for virtuoso login, from http://www.mysite.net/virtuoso/conductor (with expected screen). I have an error with a returned address http://www.plm-interop.net/conductor/main_tabs.vspx, and a message Not found. I think it does not work, because some call are may be not done under the path /virtuoso , in particular with the login, but I'm not so sure. Did some one already address successfully this need (redirection on a server) and can indicate me how to proceed? I think your ProxyHTMLURLMap arguments are in reverse order. The following should work: NameVirtualHost 88.191.91.72 VirtualHost 88.191.91.72 ServerName www.mysite.net http://www.mysite.net ... # Disable global proxy ProxyRequests Off # Pass original host to Virtuoso ProxyPreserveHost On # Timeout waiting for Virtuoso ProxyTimeout300 # Set permission Proxy * Order deny,allow Allow from all /Proxy # # Map /virtuoso/ to a local Virtuoso instance. # # Since ProxyPass and ProxyPassReverse only fix the Headers # of the request, we need to use ProxyHTMLURLMap to rewrite # content. # Location /virtuoso/ ProxyPass http://172.16.12.128:8890/ ProxyPassReverse/ # Enable rewrite rules ProxyHTMLEnable On ProxyHTMLURLMap / /virtuoso/ ProxyHTMLURLMap http://172.16.12.128:8890/ /virtuoso/ # Uncomment this when EnabledGzipContent=1 in virtuoso.ini #SetOutputFilter INFLATE;DEFLATE /Location /VirtualHost If we map the virtual host straight through to Virtuoso, we only need header rewriting and save the time/cpu power to rewrite the content. # # Map / to a local Virtuoso instance # # Since paths are mapped straight through, we do not have to # rewrite the content. # Location / ProxyPass http://172.16.12.128:8890/ ProxyPassReverse/ /Location Note that the next version of Virtuoso OpenSource has a couple of patches to fix some issues with running under a reverse proxy, so you may need a newer version of Virtuoso. Please contact me if you continue to experience problems and i will make a new snapshot available to you. Patrick
Re: [Virtuoso-users] Virtuoso server on Debian with apache proxying
HI Nicolas, Going further on investigation, I've some little problems: 1- strange caracters appearing on the conductor screen (A like symbol on capture of virtuoso conductor screen) Will need to have a look using your method of proxy rewrite to see what it produces. I did not notice anything when using the method i suggested. 2- with isparql, it seems that some stylesheet does not apply (can be compared between the two ispaql captures attached) That could be issue with the OAT toolkit. You have to remember that most HTML applications are not written to cater extra directories in the vhost setup and expect / as / and not as /virtuoso/ Any idea of complementary parameterization on the proxying in order to avoid such issue? Note that my remote server is on debian. I will try to have a look at this. Can you please tell me the exact version of Debian you are using so i can see if i have a VM to test this with your version. Patrick
Re: [Virtuoso-users] Virtuoso server on Debian with apache proxying
Hi Nicolas, I'm trying to access virtuoso server through an apache server, using mod_proxy. Calling http://www.mysite.net/virtuoso, it should redirect on my local server on 88.191.91.72:8890 http://88.191.91.72:8890 NameVirtualHost 88.191.91.72 VirtualHost 88.191.91.72 ServerName www.mysite.net http://www.mysite.net ... ProxyRequests off Proxy * Order deny,allow Allow from all /Proxy ProxyPass /virtuoso/ http://172.16.12.128:8890/ ProxyPass /virtuoso http://172.16.12.128:8890 ProxyPassReverse /virtuoso/ http://172.16.12.128:8890/ ProxyPassReverse /virtuoso http://172.16.12.128:8890 ProxyTimeout 300 ProxyHTMLURLMap /virtuoso/ http://172.16.12.128:8890/ ProxyHTMLURLMap /virtuoso http://172.16.12.128:8890 ProxyPreserveHost On /VirtualHost But doing so, when trying to enter login and password for virtuoso login, from http://www.mysite.net/virtuoso/conductor (with expected screen). I have an error with a returned address http://www.plm-interop.net/conductor/main_tabs.vspx, and a message Not found. I think it does not work, because some call are may be not done under the path /virtuoso , in particular with the login, but I'm not so sure. Did some one already address successfully this need (redirection on a server) and can indicate me how to proceed? I think your ProxyHTMLURLMap arguments are in reverse order. The following should work: NameVirtualHost 88.191.91.72 VirtualHost 88.191.91.72 ServerName www.mysite.net http://www.mysite.net ... # Disable global proxy ProxyRequests Off # Pass original host to Virtuoso ProxyPreserveHost On # Timeout waiting for Virtuoso ProxyTimeout300 # Set permission Proxy * Order deny,allow Allow from all /Proxy # # Map /virtuoso/ to a local Virtuoso instance. # # Since ProxyPass and ProxyPassReverse only fix the Headers # of the request, we need to use ProxyHTMLURLMap to rewrite # content. # Location /virtuoso/ ProxyPass http://172.16.12.128:8890/ ProxyPassReverse/ # Enable rewrite rules ProxyHTMLEnable On ProxyHTMLURLMap / /virtuoso/ ProxyHTMLURLMap http://172.16.12.128:8890/ /virtuoso/ # Uncomment this when EnabledGzipContent=1 in virtuoso.ini #SetOutputFilter INFLATE;DEFLATE /Location /VirtualHost If we map the virtual host straight through to Virtuoso, we only need header rewriting and save the time/cpu power to rewrite the content. # # Map / to a local Virtuoso instance # # Since paths are mapped straight through, we do not have to # rewrite the content. # Location / ProxyPass http://172.16.12.128:8890/ ProxyPassReverse/ /Location Note that the next version of Virtuoso OpenSource has a couple of patches to fix some issues with running under a reverse proxy, so you may need a newer version of Virtuoso. Please contact me if you continue to experience problems and i will make a new snapshot available to you. Patrick
Re: [Virtuoso-users] ADO.NET provider DateTime bug(?)
HI Alexander, Previously I stored DateTime values as strings and casted them to xsd:dateTime dynamically at query time. Then according to Ivan's advice I reimplemented SPARUL part to cast DateTime values when they are added to the store. But now ADO.NET http://ADO.NET provider returns xsd:dateTime values as strings without timezone offset information. At the same time sparql-endpoint web interface displays values correctly. Thank you for reporting this. I have assigned one of the developers to have a look at this issue. Patrick
Re: [Virtuoso-users] Redland Python bindings with Virtuoso 6.1
Hi Chris, I'm back on the trail to get redland working with virtuoso storage. I want to be able to use virtuoso as a backend from python (and probably c++ later on)! I'm still having issues with the librdf 1.0.10 version. I can connect using pyodbc to virtuoso with unixodbc installed. I am getting undefined symbol errors when using the bindings with virtuoso support built in. In [1]: import RDF python: symbol lookup error: /home/prima/opt/redland/lib/ redland/librdf_storage_virtuoso.so: undefined symbol: librdf_storage_register_factory This looks like a bug in the plugin code. I assume you also contacted the redland development team about this, as this sounds like a recent change in their code that has not been fixed in all the backend drivers. Does the virtuoso support in redland need iODBC? I don't have that installed, rather unixodbc and it's sources. Will it still work with this version of sql.h? or does it expect the sql.h from virtuoso itself? (I noticed there was an sql.h in the virtuoso sources at virtuoso-opensource-6.1.0/libsrc/odbcsdk/include/sql.h.) It compiled ok using the system sql.h... No, virtuoso support in redland does not require iODBC, but should function with unixODBC as well as we tried to use plain ODBC API throughout the code. As maintainers of iODBC we do have a slight preference to use iODBC, but the original code was tested with unixODBC as well before we submitted it to redland. The various include files called sql.h (and the underlying sqlext.h etc) are interchangeable from one driver manager to another. The reason why there is a sql.h inside virtuoso is just that not every OS has an ODBC compatible driver manager and sdk (yet), and since we use these defines to create our client layer, we included a copy inside the source tree that gets used when you do not have a system wide version. Patrick
Re: [Virtuoso-users] V6.1.0 Reasoning and index with strange error
Hi Sebastian, I experimented with the new reasoning features and there are some issues. I already solved them and just want to give you some feedback. The features and the speed of reasoning are quite awesome, good work thumbs up. Here is one small question: If my:trans is a transitive Property and I query: ?s my:trans ?class. ?class a my:Person. Will the inference engine's answer be complete and combinable? Here is a list of strange errors I encountered with V6.1.0. I can provide you with the data and test queries, if you are interested. I don't need answers for these, as for me they are already fixed. 1. CREATE BITMAP index RDF_QUAD_PSOG on DB.DBA.RDF_QUAD (P,S,O,G); Other indexes worked, but the PSOG messed up the DB. After restarting I got the message: Error executing a server init statement : 22023: JSO_LOAD_GRAPH has not found expected metadata in the graph -- DB.DBA.RDF_QUAD_FT_UPGRADE () and executing a query with define input:inference I got this message: JSO_LOAD_GRAPH has not found expected metadata in the graph So server was loading data and index well, but after restarting it didn't work any more. You do not need to create this particular index in Virtuoso v6.1.0 as this is the same as the primary key of the table. Note that the index scheme for the RDF_QUAD table has changed drastically with the introduction of the 2+3 index. In Virtuoso v5 we only had a small standard set of indexes, combined with an extended set for facetted browsing purposes. This meant that for certain types of queries and reasoning additional indexes where required. In Virtuoso v6 we have implemented a new 2+3 index scheme, which consists of 2 full indexes (PSOG and POGS) and 3 partial indexes (SP, OP and GS). This new approach takes up a lot less index space, while allowing the same or better capabilities as the older v5 facetted browsing scheme. While other indexes may be created for certain types of operations, in many cases they will not be needed when moving to the v6 platform. Please read the following section of the documentation which explains the 2+3 indexing scheme in more details: http://docs.openlinksw.com/virtuoso/rdfperformancetuning.html#rdfperfrdfscheme Needless to say we will investigate why the creation of this extra index caused your exec error and will fix it for the next release. 2. At first, I loaded an Ontology for reasoning, containing some blanknodes: my:SyntacticNode rdfs:subClassOf _:bn1 . _:bn1 owl:minCardinality 1^^xsd:nonNegativeInteger . _:bn1 owl:onProperty my:hasTag . _:bn1 rdf:type owl:Restriction . Whenever I was querying some high classes in the hierarchy, the query took over 400 seconds and brought the wrong result. So there might be a glitch there. 3. Inferencing doesn't seem to be compatible with Vectors, so for the pattern: ?instance a ?class this still works: Filter ( ?class = my:Person ) But these do not: Filter ( ?class = my:Person || ?class = my:Student ) Filter ( ?class in ( my:Person, my:Student) ) I'm not sure if this is a bug, might be a new feature. Dataset: 8 million triples instance data About 1000 schema triples with subclassof, inverseof and transitive properties Ivan will be looking into these two items. Best regards, Patrick
Re: [Virtuoso-users] Windows build manual
Hi Alexander, Is there any more up-to-date build manual for Windows that this? The scripts are all up to date in both win32 and win64 directories, and while doc may need some attention, for the most part it should give you reasonable idea of how to perform a build yourself. However since Windows is not an easy option for most people to build, we will be uploading our builds for virtuoso open source 6.1.0 as soon as possible. Expect them some time Monday. Patrick
Re: [Virtuoso-users] FYI: Dbpedia-Live Reports Could Not Connect to Host
Hi Stephen, I noticed all of the directly accessed resources at dbpedia-live.openlinksw.com http://dbpedia-live.openlinksw.com weren't working. Here's what it's been saying for at least several resources: *Address:* http://dbpedia-live.openlinksw.com/page/Dauphin_commun_%C3%A0_bec_court *Error 08C01* CL...: Cluster could not connect to host 3 192.168.11.174:3003 http://192.168.11.174:3003 error 111 in DB.DBA.DAV_SEARCH_ID, path = '/DAV/VAD/dbpedia/description.vsp', what = 'R', WS.WS.GET, path = (ARRAY_OF_POINTER value, tag 193), params = (ARRAY_OF_POINTER value, tag 193), lines = (ARRAY_OF_POINTER value, tag 193), Top Level, :0 = 'WS.WS.GET', :1 = (ARRAY_OF_POINTER value, tag 193), :2 = (ARRAY_OF_POINTER value, tag 193), :3 = (ARRAY_OF_POINTER value, tag 193) Apologies for the inconvenience. We are in the process of doing some upgrades to this experimental system and one of the nodes was not restarted automatically. I restarted cluster node and checked the database is operational. Patrick
Re: [Virtuoso-users] OS X 10.6.2: Exceeded maximum number of file descriptors in FD_SET.
Hi Ceriel, As soon as the virtuoso.log mentions Exceeded maximum number of file descriptors in FD_SET. in a testing environment (=few users), how should the OS or virtuoso or the OS be reconfigured? There are three posibilities: 1. Your ulimit / kernel settings are too small for your usage. 2. Your C library can only handle so many concurrent open file descriptors on a default compile. This is indicated by the FD_SETSIZE define in select.h. On Mac OS X this is a default of 1024, so if you have over 1024 concurrent files opened this can be an issue. Remember that all open connections count e.g. HTTP/ODBC/JDBC sessions as well as database files and temp streams. If this is the case, some header files allow you to set FD_SETSIZE to a larger value, but i would need to check if Apple can handle this. 3. You are experiencing a fd leak. I will send you a patch that could resolve this problem. /usr/local/virtuoso-opensource/var/lib/virtuoso/db/virtuoso.log --- 23:42:14 Checkpoint made, log reused Mon Jan 18 2010 00:30:06 Exceeded maximum number of file descriptors in FD_SET. 00:42:16 Exceeded maximum number of file descriptors in FD_SET. 00:42:16 Checkpoint made, log reused 00:42:16 Exceeded maximum number of file descriptors in FD_SET. 00:42:17 Server received signal 11. Continuing with the default action for that signal. Mon Jan 18 2010 16:30:17 OpenLink Virtuoso Universal Server 16:30:17 Version 06.00.3123-pthreads for Darwin as of Jan 12 2010 16:30:17 uses parts of OpenSSL, PCRE, Html Tidy 16:30:29 Database version 3100 16:30:30 SQL Optimizer enabled (max 1000 layouts) 16:30:34 Compiler unit is timed at 0.002779 msec 16:30:37 Roll forward started 16:30:37 2 transactions, 87 bytes replayed (100 %) 16:30:37 Roll forward complete 16:30:39 Checkpoint made, log reused 16:30:42 HTTP/WebDAV server online at 8890 16:30:42 Server online at (pid 7403) 17:30:42 Checkpoint made, log reused Patrick
Re: [Virtuoso-users] problem loading RDF...
HI Egon, I am trying to load a RDF document (made with a PHP script from a MySQL database) into Virtuoso with isql, but running into this exception: SQL DB.DBA.RDF_LOAD_RDFXML_MT(file_to_string_output('/tmp/compounds.rdf', 'http://pele.farmbio.uu.se/chembl'); *** Error 37000: [Virtuoso Driver][Virtuoso Server]SQ074: Line 1: syntax error at line 4 of Top-Level: DB.DBA.RDF_LOAD_RDFXML_MT(file_to_string_output('/tmp/compounds.rdf', 'http://pele.farmbio.uu.se/chembl') Your line is missing a closing paren after the call to file_to_string_output: DB.DBA.RDF_LOAD_RDFXML_MT( file_to_string_output('/tmp/compounds.rdf'), 'http://pele.farmbio.uu.se/chembl' ); Patrick
Re: [Virtuoso-users] How to download Virtuoso open source 6.0 ?
Hi Wenxiu, Thanks for your contribution on Virtuoso! I am wondering how to download virtuoso open source verison 6.0, seems the latest version in both Sourceforge and CVS is 5.0.12. Virtuoso 6.0.0 was downloadable from the virtuoso-devel section of Sourceforge. We are in the process of moving it so it comes up under the main virtuoso download area. The VOS 6 source code in CVS is on a branch called V6_0_0-DEVEL on Sourceforge. But I really want to have a try on version 6.0 to play with the clustering feature ( this feature only works over version 6.0, right?). The clustering code is only available in the Commercial version of Virtuoso. If you are still interested in testing this technology, we do offer evaluation licenses. Please contact me if you are interested. Patrick
Re: [Virtuoso-users] Problems building 6.0.0 ODBC driver on OSX 10.6
Hi Ryan, I am trying to compile virtuoso-opensource 6.0.0 on a 32-bit Intel Mac running OSX 10.6. Everything goes fine until it gets to the ODBC driver, at which point I run into the following error: ld: warning: in .libs/virt_vers_r.o, file is not of required architecture ld: warning: in ./.libs/libvirtodbc.a, file is not of required architecture ld: warning: in ../../libsrc/Thread/.libs/libthrp.a, file is not of required architecture ld: warning: in ../../libsrc/Dk/.libs/libdk1t.a, file is not of required architecture ld: warning:ld : inwarning :. in. /..libs.//virt_vers.olibsrc,/ utilfile/ .islibs /notlibutil.a ,of filerequired isarchitecture notld :of warningrequired: architecturein ./.libs/libvirtodbc.a, file is not of required architecture ld: warning: in ../../libsrc/Thread/.libs/libthrs.a, file is not of required architecture ld: warning: in ../../libsrc/Dk/.libs/libdk1t.a, file is not of required architecture ld: warning: in ../../libsrc/util/.libs/libutil.a, file is not of required architecture nmedit -s .libs/virtodbc_r-symbols.expsym .libs/virtodbc_r.so nmedit -s .libs/virtodbc-symbols.expsym .libs/virtodbc.so nmedit: nmedit: symbols names listed in: .libs/virtodbc-symbols.expsym not in: /private/tmp/homebrew-virtuoso-6.0.0-KWgQ/virtuoso- opensource-6.0.0/binsrc/driver/.libs/virtodbc.sosymbols names listed in: .libs/virtodbc_r-symbols.expsym not in: _SQLAllocConnect /private/tmp/homebrew-virtuoso-6.0.0-KWgQ/virtuoso-opensource-6.0.0/ binsrc/driver/.libs/virtodbc_r.so_SQLAllocEnv _SQLAllocHandle long list of _SQL* symbols snipped make[2]: *** [virtodbc_r.la] Error 1 make[2]: *** Waiting for unfinished jobs make[2]: *** [virtodbc.la] Error 1 make[1]: *** [install-recursive] Error 1 make: *** [install-recursive] Error 1 What am I doing wrong? The required architecture errors are probably due to a missing compiler flag in your setup, so the system thinks it needs to link a different architecture than you have compiled your objects with. Please email me your config.nice file privately and i will be able to help you configure your system. Patrick
Re: [Virtuoso-users] Newbie questions
Hi Eddy, 2. Has any-one an idea if and when the form-designer of OAT would be re-activated ? Don't get data into the widgets. We have scheduled to fix form designer in the next week or so. I will let you know as soon as i have an ETA from development. Patrick
Re: [Virtuoso-users] Querying the currently used indexes
HI Sebastian, currently I am using the following query to determine the indexes that are in use: SELECT DISTINCT SUBSTRING(ISS_KEY_NAME,10,4) FROM SYS_INDEX_SPACE_STATS WHERE ISS_KEY_TABLE='DB.DBA.RDF_QUAD' AND ISS_KEY_NAME LIKE 'RDF_QUAD_*' However, this query is very slow. Is there a better alternative? Please use the ODBC SQLStatistics call to get this information. Patrick
Re: [Virtuoso-users] Virtuoso 6.0.1
Hi Xavier, with KDE 4.4's feature freeze coming up I would like to know when Virtuoso 6.0.1 will be released. KDE 4.4 will be the first release of KDE which depends on Virtuoso and I would like for packagers to package Virtuoso 6 rather than 5. However, 6.0 does contain at least one regression (already reported and apparently fixed internally) which makes it unusable for KDE. Is there any chance to get a release soon so that packagers for the different linux distributions can start working on it soon? We are working on a couple more bugfixes we want to get into V6, but we are planning to do a new Virtuoso Open Source 6.0.1 in the next week or so. Do you have an idea of the release date of 6.0.1 or a pointer to a patch making 6.0.0 work with nepomuk so that we can package it ? I am working closely with Sebastian to make sure the new VOS 6.0.1 release works perfectly with the nepomuk/soprano code base for the upcoming KDE 4.4 release. As soon as we are both happy with the results, i will make the V6.0.1 cut and release it to sourceforge. We are talking days here, not weeks. I will let you know the moment it is official. In the mean time, can you mail me details where i can see your packaging scripts you made thusfar, so i have a change to see if they match the way we are working with other teams/distributions to provide a common base for everyone. Patrick