WikiData Processing
WikiData Processing
Data Accessing
To download latest-all.json.bz2 on the page https://dumps.wikimedia.org/wikidatawiki/entities/ .
wget is the best tool to download huge file:
wget -c -t 0 https://dumps.wikimedia.org/wikidatawiki/entities/latest-all.json.bz2
Installing Neo4j on Ubuntu
From Repositories (Not recommended)
This way needs supervisor authority, which is inconvenient.
Step 1. (Optional) To install OpenJRE and OpenJDK firstly, if there are no Java runtime environment on the computer.
$ sudo apt-get update
$ sudo apt-get install default-jre
$ sudo apt-get install default-jdk
Step 2. Installing Neo4j.
To use the repository add it to the list of sources:
$ wget -O - https://debian.neo4j.org/neotechnology.gpg.key | sudo apt-key add -
$ echo 'deb https://debian.neo4j.org/repo stable/' | sudo tee /etc/apt/sources.list.d/neo4j.list
$ sudo apt-get update
To install the latest Neo4j Community Edition:
$ sudo apt-get install neo4j
User Installation
To extract files from neo4j-community-3.5.8-unix.tar.gz
$ tar zxvf neo4j-community-3.5.8-unix.tar.gz
Adding follow lines to ~/.bashrc, and 'source' it.
# neo4j
export NEO4J_HOME="/home/fyb/neo4j-community-3.5.8"
export PATH=$PATH:$NEO4J_HOME/bin
To open remote accessing authority.
$ vi neo4j-community-3.5.8/conf/neo4j.conf
change #dbms.connector.http.listen_address=:7474
to dbms.connector.http.listen_address=0.0.0.0:7474
change #dbms.connector.bolt.listen_address=:7687
to dbms.connector.bolt.listen_address=0.0.0.0:7687
To start service, <NEO4J_HOME> is the top level directory referred to neo4j-community-3.5.8
$ neo4j console
Installing NodeJs
Node.js v12.x:
$ curl -sL https://deb.nodesource.com/setup_12.x | sudo -E bash -
$ sudo apt-get install -y nodejs
Importing
We employ wikidata-neo4j-importer to import wikidata into neo4J.
https://github.com/findie/wikidata-neo4j-importer
some requirements need to be installed.
$ npm install neo4j-driver async n-readlines cli-color slugify
Now, we can run index.js to import WikiData into neo4j !
$ node index.js
Bibliography
https://github.com/nodesource/distributions/blob/master/README.md#deb
https://neo4j.com/download-thanks/?edition=community&release=3.5.8&flavour=unix
最新文章
- java类的初始化顺序
- VIM编辑器常用命令
- 从零开始学习Android(二)从架构开始说起
- [Exchange]使用EWS托管API2.0同步邮箱
- SqlServer 还原他服数据库只建立发布却删除不了
- Android -- ids.xml文件的使用
- [ACM_暴力] ZOJ 3710 [Friends 共同认识 最终认识 暴力]
- openstack中运行定时任务的两种方法及源代码分析
- 电容值E系列标称方法
- git提交时的冲突处理
- JUnit3 结合一个除法的单元测试说明Assert.fail()的用法
- phpStorm打开提示 failed to create JVM 的解决的方法
- SSH—Struts(三)—跑步者(Action)
- 【bzoj1458】士兵占领
- ctf常见php弱类型分析
- 9.app后端选择什么服务器
- CRT破解版
- Scrapy案例02-腾讯招聘信息爬取
- java多线程探究
- MVC 视图助手书写规范及注意点