Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
# Stop the old neo4j installation, and remove it from rc.d
$ sudo service neo4j-service stop
$ sudo update-rc.d -f neo4j-service remove

Debian package

 

You can follow the installation steps from the setup guide above. The guide below for migrating assumes you don't do the password creation step, so if you do you can skip the set-defa

If you use the debian package, you might want to change your database path, default is `/var/lib/neo4j/data`.

...

  1. Stop neo4j service if running
  2. Remove data/databases/graph.db in 3.2 `sudo rm -r /var/lib/neo4j/data/databases/graph.db/`
  3. Enable data migration in neo4j.conf `dbms.allow_format_migration=true` (should probably be disabled after first migration is done)
  4. Import database from 2.x `sudo -u neo4j neo4j-admin import --mode=database --database=graph.db --from=/var/opt/neo4j-community-2.1.8/data/graph.db/``
  5. Set default admin `sudo -u neo4j neo4j-admin set-default-admin neo4j`
  6. Set password `sudo -u neo4j neo4j-admin set-default-admin`initial-password your_awesome_password`
  7. Start neo4j service `sudo service neo4j start`
    1.  you can follow along in `logs/neo4j.log`

...

You might have to remove the old auth settings first: `sudo rm /var/lib/neo4j/data/dbms/auth`

Code Block
# Note the extra space in front to not have the password in your bash history
$  sudo -u neo4j neo4j-admin set-initial-password your_awesome_password

...

Code Block
# In norduni directory as the NI user
$ sudo -u ni -i
$ git stash
$ git pull origin master
$ git stash apply
$ rm -r src/niweb/norduniclient
 
# Delete old virtualenv and create a new
$ cd ..
$ rm -r norduni_environment
$ virtualenv norduni_environment
$ . norduni_environment/bin/activate
$ pip instal -U pip
$ pip install -U -r norduni/requirements/prod.txt
 
# update norduni/src/niweb/.env to have:
	NEO4J_USERNAME=neo4j
    NEO4J_PASSWORD=your_awesome_password
    NEO4J_RESOURCE_URI=bolt://localhost:7687

...