I am using neo4j-admin import to read the csv and create nodes. While firing up the command for the import I am facing a file lock exception.
My import csv file -
movieId:ID,title,year:int,:LABEL
tt0133093,"The Matrix",1999,Movie
tt0234215,"The Matrix Reloaded",2003,Movie;Sequel
tt0242653,"The Matrix Revolutions",2003,Movie;Sequel
I have already tried to kill the process and still the problem pertains.
Command while running the import - /bin/neo4j-admin import --nodes=test_new_import.csv
ERROR :
org.neo4j.kernel.impl.store.UnderlyingStorageException: org.neo4j.io.pagecache.impl.FileLockException: This file is locked by another process, please ensure you don't have another Neo4j process or tool using it: '/var/lib/neo4j/data/databases/graph.db/neostore'.'
*** at org.neo4j.kernel.impl.store.NeoStores.verifyRecordFormat(NeoStores.java:217)***
*** at org.neo4j.kernel.impl.store.NeoStores.(NeoStores.java:144)***
*** at org.neo4j.kernel.impl.store.StoreFactory.openNeoStores(StoreFactory.java:129)***
*** at org.neo4j.kernel.impl.store.StoreFactory.openAllNeoStores(StoreFactory.java:93)***
*** at org.neo4j.unsafe.impl.batchimport.store.BatchingNeoStores.instantiateStores(BatchingNeoStores.java:237)***
*** at org.neo4j.unsafe.impl.batchimport.store.BatchingNeoStores.createNew(BatchingNeoStores.java:181)***
*** at org.neo4j.unsafe.impl.batchimport.ParallelBatchImporter.doImport(ParallelBatchImporter.java:87)***
*** at org.neo4j.tooling.ImportTool.doImport(ImportTool.java:581)***
*** at org.neo4j.commandline.dbms.CsvImporter.doImport(CsvImporter.java:128)***
*** at org.neo4j.commandline.dbms.ImportCommand.execute(ImportCommand.java:236)***
*** at org.neo4j.commandline.admin.AdminTool.execute(AdminTool.java:127)***
*** at org.neo4j.commandline.admin.AdminTool.main(AdminTool.java:51)***
*** Suppressed: java.lang.IllegalStateException: VM pause monitor is not started***
*** at org.neo4j.util.Preconditions.checkState(Preconditions.java:142)***
*** at org.neo4j.kernel.monitoring.VmPauseMonitor.stop(VmPauseMonitor.java:71)***
*** at org.neo4j.unsafe.impl.batchimport.staging.OnDemandDetailsExecutionMonitor.done(OnDemandDetailsExecutionMonitor.java:128)***
*** at org.neo4j.unsafe.impl.batchimport.staging.MultiExecutionMonitor.done(MultiExecutionMonitor.java:82)***
*** at org.neo4j.unsafe.impl.batchimport.staging.MultiExecutionMonitor.done(MultiExecutionMonitor.java:82)***
*** at org.neo4j.unsafe.impl.batchimport.ImportLogic.close(ImportLogic.java:520)***
*** at org.neo4j.unsafe.impl.batchimport.ParallelBatchImporter.doImport(ParallelBatchImporter.java:99)***
*** ... 5 more***
Caused by: org.neo4j.io.pagecache.impl.FileLockException: This file is locked by another process, please ensure you don't have another Neo4j process or tool using it: '/var/lib/neo4j/data/databases/graph.db/neostore'.'
*** at org.neo4j.io.pagecache.impl.SingleFilePageSwapper.acquireLock(SingleFilePageSwapper.java:227)***
*** at org.neo4j.io.pagecache.impl.SingleFilePageSwapper.(SingleFilePageSwapper.java:178)***
*** at org.neo4j.io.pagecache.impl.SingleFilePageSwapperFactory.createPageSwapper(SingleFilePageSwapperFactory.java:66)***
*** at org.neo4j.io.pagecache.impl.muninn.MuninnPagedFile.(MuninnPagedFile.java:149)***
*** at org.neo4j.io.pagecache.impl.muninn.MuninnPageCache.map(MuninnPageCache.java:412)***
*** at org.neo4j.kernel.impl.store.MetaDataStore.getRecord(MetaDataStore.java:285)***
*** at org.neo4j.kernel.impl.store.NeoStores.verifyRecordFormat(NeoStores.java:198)***
*** ... 11 more***
WARNING Import failed. The store files in /var/lib/neo4j/data/databases/graph.db are left as they are, although they are likely in an unusable state. Starting a database on these store files will likely fail or observe inconsistent records so start at your own risk or delete the store manually
unexpected error: org.neo4j.io.pagecache.impl.FileLockException: This file is locked by another process, please ensure you don't have another Neo4j process or tool using it: '/var/lib/neo4j/data/databases/graph.db/neostore'.'