Reputation: 560
configured a file:
@prefix : <#> .
@prefix fuseki: <http://jena.apache.org/fuseki#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix tdb: <http://jena.hpl.hp.com/2008/tdb#> .
@prefix ja: <http://jena.hpl.hp.com/2005/11/Assembler#> .
[] rdf:type fuseki:Server ;
fuseki:services (
<#testService>
) .
<#testService>
rdf:type fuseki:Service ;
fuseki:name "testService" ;
fuseki:serviceQuery "query" ;
fuseki:serviceReadGraphStore "get" ;
fuseki:dataset <#Dataset> .
<#Dataset>
rdf:type ja:RDFDataset ;
rdfs:label "a label for your dataset" ;
ja:defaultGraph
[ rdfs:label "sample.rdf" ;
a ja:MemoryModel ;
ja:content [ja:externalContent <file:/Users/hdeus/Documents/KnowledgeBase/SPARQL/TestData/sample.rdf> ] .
] .
Ran java -jar fuseki-server.jar --config=fuseki_config.ttl
20:46:08 INFO Home Directory: /Users/hdeus/Documents/KnowledgeBase/SPARQL/Engines/.
20:46:08 WARN No such directory for static content: /Users/hdeus/Documents/KnowledgeBase/SPARQL/Engines/.
20:46:08 WARN You may need to set the --pages or --home option to configure static content correctly
20:46:08 INFO Configuration file: fuseki_config.ttl
20:46:08 INFO Service: <file:///Users/hdeus/Documents/KnowledgeBase/SPARQL/Engines/fuseki_config.ttl#testService>
20:46:08 INFO name = testService
20:46:08 INFO query = /testService/query
20:46:08 INFO graphStore(R) = /testService/get
20:46:09 WARN Already initialized: dataset = testService
20:46:09 INFO Dataset path = /testService
20:46:09 INFO Fuseki 0.2.8-SNAPSHOT 20130530-0913
20:46:09 INFO Started 2013/06/01 20:46:09 EDT on port 3030
Went to http://localhost:3030/
And got the following message:
Error 404: Not Found
Fuseki - version 0.2.8-SNAPSHOT (Build date: 20130530-0913)
What I am doing wrong? From various sources, this is working for others but not for me.
Upvotes: 2
Views: 1974
Reputation: 28636
Did you by any chance either copy/move the Fuseki JAR from the original location you downloaded it to on your machine?
As the warning messages in the log output state Fuseki was unable to find the directory for static content, it expects to find a /pages
directory under the directory in which you launch it. This directory should be present in your download whether you downloaded the source/binaries.
This warning does not mean that Fuseki is not running just that you won't have the UI available to you, if you are a beginner then you likely want the UI available. The fix is to make sure you copy over the /pages
directory from your download or to use the --pages
flag to point to the location from your download.
If you make a SPARQL query to the endpoint URI like http://localhost:3030/testService/query
then you will be able to get a result. Note that testService
is the value from the fuseki:name
property in your config file.
Upvotes: 5