Neo4j interoperability between community and enterprise edition databases - neo4j

I am having issue switching between neo4j enterprise and community versions.Since i was unable to do a graphml import,i switched to enterprise where i can import graphml databases.Once i am done i am trying to open the database file created in enterprise version in community version it is giving error.
org.neo4j.server.database.LifeCycleManagingDatabase was succesfully initialized but failed to start
Is it possible to open a db created in enterprise version in community.What am i doing wrong here?
Please find the error i am getting when i am opening the db from java .
Exception in thread "main" java.lang.RuntimeException: Error starting org.neo4j.kernel.EmbeddedGraphDatabase, D:\roshni\graph.db
at org.neo4j.kernel.InternalAbstractGraphDatabase.run(InternalAbstractGraphDatabase.java:314)
at org.neo4j.kernel.EmbeddedGraphDatabase.<init>(EmbeddedGraphDatabase.java:59)
at org.neo4j.graphdb.factory.GraphDatabaseFactory.newDatabase(GraphDatabaseFactory.java:107)
at org.neo4j.graphdb.factory.GraphDatabaseFactory$1.newDatabase(GraphDatabaseFactory.java:94)
at org.neo4j.graphdb.factory.GraphDatabaseBuilder.newGraphDatabase(GraphDatabaseBuilder.java:176)
at org.neo4j.graphdb.factory.GraphDatabaseFactory.newEmbeddedDatabase(GraphDatabaseFactory.java:66)
at Testing.main(Testing.java:15)
Caused by: org.neo4j.kernel.lifecycle.LifecycleException: Component 'org.neo4j.kernel.impl.transaction.state.DataSourceManager#f1cb476' was successfully initialized, but failed to start. Please see attached cause exception.
at org.neo4j.kernel.lifecycle.LifeSupport$LifecycleInstance.start(LifeSupport.java:499)
at org.neo4j.kernel.lifecycle.LifeSupport.start(LifeSupport.java:108)
at org.neo4j.kernel.InternalAbstractGraphDatabase.run(InternalAbstractGraphDatabase.java:309)
... 6 more
Caused by: org.neo4j.kernel.lifecycle.LifecycleException: Component 'org.neo4j.kernel.NeoStoreDataSource#2ad13d80' was successfully initialized, but failed to start. Please see attached cause exception.
at org.neo4j.kernel.lifecycle.LifeSupport$LifecycleInstance.start(LifeSupport.java:499)
at org.neo4j.kernel.lifecycle.LifeSupport.start(LifeSupport.java:108)
at org.neo4j.kernel.impl.transaction.state.DataSourceManager.start(DataSourceManager.java:117)
at org.neo4j.kernel.lifecycle.LifeSupport$LifecycleInstance.start(LifeSupport.java:493)
... 8 more
Caused by: org.neo4j.kernel.impl.storemigration.StoreUpgrader$UpgradingStoreVersionNotFoundException: 'neostore.nodestore.db' does not contain a store version, please ensure that the original database was shut down in a clean state.
at org.neo4j.kernel.impl.storemigration.UpgradableDatabase.checkUpgradeable(UpgradableDatabase.java:86)
at org.neo4j.kernel.impl.storemigration.StoreMigrator.needsMigration(StoreMigrator.java:158)
at org.neo4j.kernel.impl.storemigration.StoreUpgrader.getParticipantsEagerToMigrate(StoreUpgrader.java:259)
at org.neo4j.kernel.impl.storemigration.StoreUpgrader.migrateIfNeeded(StoreUpgrader.java:134)
at org.neo4j.kernel.NeoStoreDataSource.upgradeStore(NeoStoreDataSource.java:532)
at org.neo4j.kernel.NeoStoreDataSource.start(NeoStoreDataSource.java:434)
at org.neo4j.kernel.lifecycle.LifeSupport$LifecycleInstance.start(LifeSupport.java:493)
... 11 more

It's better to have same version of Neo4j community and enterprise.
If your enterprise version is older then community. I suggest to change following property for update datastore
conf/neo4j.properties
allow_store_upgrade=true

In addition to what #MicTech said, you cannot downgrade a datastore. Neo4j supports upgrades. So when moving from community to enterprise, the enterprise variant needs to be the same version or a newer one.
Before doing a store upgrade, it's crucial to do a clean shutdown with the old version.

As per their documentation on Ubuntu and Debian you can do an upgrade as follow, for Neo4j 2.3.1
The Neo4j Debian repository can be used on Debian or Ubuntu.
To use the repository follow these steps:
wget -O - https://debian.neo4j.org/neotechnology.gpg.key | sudo
apt-key add - echo 'deb http://debian.neo4j.org/repo stable/'
/tmp/neo4j.list sudo mv /tmp/neo4j.list /etc/apt/sources.list.d
sudo apt-get update
Installing Neo4j
To install the latest Neo4j Community Edition:
sudo apt-get install neo4j
To install the latest Neo4j Enterprise Edition:
sudo apt-get install neo4j-enterprise
The installation process will guide you thru the upgrade

Related

Neo4j - unable to get routing for database neo4j - unavailable after system upgrade

I have been running a neo4j database for a while without problem.
Yesterday our server OS was update from centos-8 to centos-stream, and since this upgrade our neo4j database does not start anymore.
The service is listed as running but on every query it says: Unable to get a routing table for database 'neo4j' because this database is unavailable.
I cannot log in to the cypher shell because it shuts down with the same error.
I'm not sure what I can do here, I would like to not reset the database as we need the information in there.
The versions I'm running are as follows:
neo4j-4.3.6-1.noarch
neo4j-java11-adapter-1-1.noarch
I had similar issue, so I checked the logs and found the below error in the logs.
Caused by: java.nio.file.AccessDeniedException:
/var/lib/neo4j/data/databases/neo4j/neostore
The fix for the above issue is to change the ownership of noe4j databases folders and files.
cd /var/lib/neo4j/data
sudo chown -R neo4j:neo4j databases/
sudo chown -R neo4j:neo4j transactions/
Restart the neo4j service
sudo systemctl restart neo4j.service

Link hadoop installed with sdkman to brew

I installed hadoop with sdkman and now I'm trying to install Hive with homebrew but brew wants to install hadoop again because it doesn't know hadoop is already installed on my computer.
I use --ignore-dependencies flag as workaround but it's not a best practice.
Do you know how can I link my hadoop installation done with sdkman to brew?
It is not possible to use a non-Homebrew hadoop with Homebrew hive, see https://docs.brew.sh/Building-Against-Non-Homebrew-Dependencies
To improve quality and reduce variation, Homebrew now exclusively supports using the default formula, as an ordinary dependency, and no longer supports using arbitrary alternatives.
You will have to install Hive manually: https://cwiki.apache.org/confluence/display/hive/gettingstarted#GettingStarted-InstallingHivefromaStableRelease
Installing Hive from a Stable Release
Start by downloading the most recent stable release of Hive from one of the Apache download mirrors (see Hive Releases).
Next you need to unpack the tarball. This will result in the creation of a subdirectory named hive-x.y.z (where x.y.z is the release number):
$ tar -xzvf hive-x.y.z.tar.gz
Set the environment variable HIVE_HOME to point to the installation directory:
$ cd hive-x.y.z
$ export HIVE_HOME={{pwd}}
Finally, add $HIVE_HOME/bin to your PATH:
$ export PATH=$HIVE_HOME/bin:$PATH

./prereqs-ubuntu.sh Error: Ubuntu focal is not supported

I'm trying to use composer and for the same I'm using the below command for installation.
curl -O https://hyperledger.github.io/composer/latest/prereqs-ubuntu.sh
chmod u+x prereqs-ubuntu.sh
These above commands successfully executed.
But when I executed this command (./prereqs-ubuntu.sh) then I'm getting below error
Terminal Throws Error ///Ubuntu focal is not supported
Please help
Hyperledger Composer Installation
I also find this kind of error during Hyperledger Composer installation this problem mainly depends on the Ubuntu version.
Steps to overcome this problem.
upgrade ubuntu version as per your ubuntu versoin please follow:
https://www.fosslinux.com/38303/how-to-upgrade-to-ubuntu-20-04-lts-focal-fossa.htm
open file prereqs-ubuntu.sh with your compatible editor
update line:
#Array of supported versions
declare -a versions=('trusty' 'xenial' 'yakkety', 'bionic');
with
# Array of supported versions
declare -a versions=('trusty' 'xenial' 'yakkety', 'bionic', 'focal');
After saving this file
Run command: ./prereqs-ubuntu.sh
I hope this problem will resolve if anything please feel free to write.

How to Uninstall Neo4j from Ubuntu 13.04

How to install Neo4j from a Ubuntu 13.04 system
I tried under root privilege "apt-get remove neo4j"...
But it didn't work, I can still see neo4j package in my '/etc' folder.
What should I do to uninstall Neo4j from my system?
try apt-get purge neo4j to get rid of it
To remove completely
For community edition
sudo apt-get purge neo4j
For enterprise edition
sudo apt-get purge neo4j-enterprise
For community version:
sudo apt-get purge neo4j
For enterprise version:
sudo apt-get purge neo4j-enterprise
After deleting neo4j you might want to check data folder, on my Ubuntu it was in /var/lib/neo4j/data/.
I have been working with 68Gb datasets and removing those helped to get lots of disk space back.
Taken from here:
If you downloaded the AppImage, to uninstall you need to remove the
following items:
(1) The downloaded AppImage: this is the executable used to run Neo4j
Desktop.
(2) The ~/.config/Neo4j Desktop directory: this is where Neo4j
Desktop stores configuration files, databases, apps, plugins, and some
other files.
(3) The
~/.local/share/applications/appimagekit-neo4j-desktop-[version].AppImage
file: this is a *.desktop entry, a file used by most desktop
environments to list installed applications. To refresh the content of
your application menu after deleting or making changes to this
*.desktop entries you can run sudo update-desktop-database (this is a system command, it's unrelated to Neo4j Desktop) or reboot.
I did not have to do (3) as it was not there.
For the community version of Neo4j 4.3 on Ubuntu, I found that I needed all the steps below to completely uninstall everything (assuming you're trying to obliterate everything, and not saving anything!):
sudo apt-get purge neo4j
sudo rm -r /var/lib/neo4j/*
sudo rmdir /var/lib/neo4j/
sudo apt autoremove (gets rid of cypher-shell daemon)

jenkins fails to install with no error on debian 7

i'm trying to get jenkins running on debian 7 but i keep getting this error while apt-get install jenkins is running.
Setting up dbus (1.6.8-1) ...
Failed to open connection to "system" message bus: Failed to connect to socket /var/run/dbus/system_bus_socket: No such file or directory
[ ok ] Starting system message bus: dbus.
Also i get the message that jenkins is started at the end and no error message:
[ ok ] Starting Jenkins Continuous Integration Server: jenkins.
but /etc/init.d/jenkins status gives me the output that jenkins is not running. also ls -alh /var/lib/jenkins gives me an empty folder.
So the install fails with no error.
This is the way i'm running the install:
wget -q -O - http://pkg.jenkins-ci.org/debian/jenkins-ci.org.key | apt-key add -
sh -c 'echo deb http://pkg.jenkins-ci.org/debian binary/ > /etc/apt/sources.list.d/jenkins.list'
apt-get update
apt-get install jenkins
Has anyone of you tried installing jenkins on a fresh debian 7?
looking forward for helping answers.
kind regards and thanks in advance
So i solved the problem finally.
I expected the Java SDK to have the right JRE in it, so i downloaded it from the Oracle website: jdk1.7.0_21-x64-linux.tar.gz after installing and registering this to my machine it worked java -version and javac -version.
Problem was the version of this JRE did not work with Jenkins so thanks to #wako, i installed openjdk-7-jre and i have now two jre's running on my machine but jenkins started finally. need to figure out if openjdk-7-jre suits my plans or if i need to fall back to Debian 6.
This is an issue with apt-get and not with Jenkins -
please make sure you run it as root.
Can try to install (or upgrade) another package, to confirm.
I had the same problem on the debian 7 freshly installed, via the light version of debian 7 with the ssh server only installed.
First I add the repository as you specified it, try to install jenkins but some dependencies were broken (daemon-psmisc-java2-runtime).
To solve the problem I did an:
apt-get -f upgrade
And it was OK
To complete the installation of jenkins you will need apache2 and java-jre
apt-get install apache2 openjdk-7-jre

Resources