# Something happened to the labels

**URL:** <https://community.neo4j.com/t/something-happened-to-the-labels/6281>\
**Category:** Neo4j Graph Platform\
**Created:** [April 3, 2019, 2:08am UTC](https://community.neo4j.com/t/something-happened-to-the-labels/6281 "2019-04-03T02:08:01Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![david.makovoz](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/david.makovoz/32/2109_2.png) [@david.makovoz](https://community.neo4j.com/u/david.makovoz)\
**Post date:** [April 3, 2019, 2:08am UTC](https://community.neo4j.com/t/something-happened-to-the-labels/6281/1 "2019-04-03T02:08:01Z")

</div>

Something went wrong with my neo4j community 3.3.0 database.  
When I run in the browser  
_match (n) return n limit 1_  
The query doesn’t return, just keeps spinning in the browser, and I get the following error (in the linux terminal running neo4j )  
_ERROR Client triggered an unexpected error [LabelAccessFailed]: Label retrieved through kernel API should exist._

When I run this command in the shell  
_match (n) return n limit 1_  
I get back something:  
_| Node[335339]{property1:0,property2:0}_

but running schema throws  
_RuntimeException: org.neo4j.kernel.api.exceptions.LabelNotFoundKernelException: Label by id 8_'  
and running _match (n) return labels(n) limit 1_  
throws _QueryExecutionException: Label by id 1_

I tried to google "LabelAccessFailed" and "LabelNotFoundKernelException" but didn't see anything relevant.

Any help, suggestions are appreciated.

David

---

<div class="post-metadata">

**Author:** ![andrew\_bowman](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/andrew_bowman/32/73_2.png) [@andrew\_bowman](https://community.neo4j.com/u/andrew_bowman)\
**Post date:** [April 3, 2019, 7:12pm UTC](https://community.neo4j.com/t/something-happened-to-the-labels/6281/2 "2019-04-03T19:12:04Z")

</div>

You should upgrade at least. .0 releases tend to be the most buggy, you should at least be on the latest patch version for the minor version of interest. Here's the [3.3.x changelog], though you should know we're up to 3.5.x by now.

---

<div class="post-metadata">

**Author:** ![keithave](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/keithave/32/9037_2.png) [@keithave](https://community.neo4j.com/u/keithave)\
**Post date:** [June 1, 2021, 3:49am UTC](https://community.neo4j.com/t/something-happened-to-the-labels/6281/3 "2021-06-01T03:49:37Z")

</div>

Hi @andrew_bowman, I'm having similar issues where I'm trying to upgrade from 3.5.6 to either 4.1.9 or 4.2.7. Neither is working and I am receiving an error of:

```auto
Caused by: org.neo4j.kernel.impl.storemigration.StoreUpgrader$UnableToUpgradeException: Failure doing migration
	at org.neo4j.kernel.impl.storemigration.StoreUpgrader.migrateToIsolatedDirectory(StoreUpgrader.java:318)
	at org.neo4j.kernel.impl.storemigration.StoreUpgrader.migrate(StoreUpgrader.java:206)
	at org.neo4j.kernel.impl.storemigration.StoreUpgrader.migrateIfNeeded(StoreUpgrader.java:153)
	at org.neo4j.kernel.impl.storemigration.DatabaseMigrator.migrate(DatabaseMigrator.java:107)
	at org.neo4j.kernel.database.Database.upgradeStore(Database.java:554)
	at org.neo4j.kernel.database.Database.start(Database.java:362)
	... 14 more
Caused by: org.neo4j.internal.kernel.api.exceptions.LabelNotFoundKernelException: Label with id=15 not found
	at org.neo4j.kernel.impl.storemigration.RecordStorageMigrator.getEntityTokenNames(RecordStorageMigrator.java:872)
	at org.neo4j.kernel.impl.storemigration.RecordStorageMigrator$SchemaNameGiver.ensureHasUniqueName(RecordStorageMigrator.java:839)
	at org.neo4j.kernel.impl.storemigration.RecordStorageMigrator.schemaGenerateNames(RecordStorageMigrator.java:791)
	at org.neo4j.kernel.impl.storemigration.RecordStorageMigrator.migrateSchemaRules(RecordStorageMigrator.java:753)
	at org.neo4j.kernel.impl.storemigration.RecordStorageMigrator.migrateSchemaStore(RecordStorageMigrator.java:741)
	at org.neo4j.kernel.impl.storemigration.RecordStorageMigrator.migrate(RecordStorageMigrator.java:266)
	at org.neo4j.kernel.impl.storemigration.StoreUpgrader.migrateToIsolatedDirectory(StoreUpgrader.java:312)
	... 19 more
Caused by: org.neo4j.token.api.TokenNotFoundException: Token for id 15

```

How do I fix this issue?

 ![upgrade-3-to-4](https://us1.discourse-cdn.com/flex021/uploads/neo4jcommunity/original/3X/3/5/355e8f66754e898f42674e55fe926fa82653c054.png)

---

<div class="post-metadata">

**Author:** ![keithave](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/keithave/32/9037_2.png) [@keithave](https://community.neo4j.com/u/keithave)\
**Post date:** [June 2, 2021, 1:01am UTC](https://community.neo4j.com/t/something-happened-to-the-labels/6281/4 "2021-06-02T01:01:29Z")

</div>

> [@keithave](#):
>
> `LabelNotFoundKernelException: Label`

Hi @andrew_bowman, can you please explain why we're having the issue stated by David and me but more importantly how to fix it?

---

<div class="post-metadata">

**Author:** ![andrew\_bowman](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/andrew_bowman/32/73_2.png) [@andrew\_bowman](https://community.neo4j.com/u/andrew_bowman)\
**Post date:** [June 2, 2021, 1:14am UTC](https://community.neo4j.com/t/something-happened-to-the-labels/6281/5 "2021-06-02T01:14:25Z")

</div>

I haven't seen that one. You might want to try a consistency check on your db first and make sure that passes. If it spots inconsistencies, then you can use store-utils to copy out the db, omitting anything inconsistent, and checking the state of your labels afterward.

> **[Consistency checker - Operations Manual](https://neo4j.com/docs/operations-manual/3.5/tools/consistency-checker/)**
>
> This section describes the Neo4j consistency checker.

> **[GitHub - jexp/store-utils: Utilities to compact, copy, fix, analyse Neo4j stores](https://github.com/jexp/store-utils)**
>
> Utilities to compact, copy, fix, analyse Neo4j stores - GitHub - jexp/store-utils: Utilities to compact, copy, fix, analyse Neo4j stores

---

<div class="post-metadata">

**Author:** ![keithave](https://sea1.discourse-cdn.com/flex021/user_avatar/community.neo4j.com/keithave/32/9037_2.png) [@keithave](https://community.neo4j.com/u/keithave)\
**Post date:** [June 2, 2021, 5:12am UTC](https://community.neo4j.com/t/something-happened-to-the-labels/6281/6 "2021-06-02T05:12:31Z")

</div>

Thank you so much Andrew!  
**RE: the Consistency checker** , having run cmd line `C:\Users\owner\Documents\neo4j-community-356\bin>neo4j-admin check-consistency --database graph.db`, there are a number of lines that seem to return what has already been confirmed, see this text file...  
[inconsistencies-2021-06-01.22.09.29.txt](https://community.neo4j.com/uploads/short-url/9DIMAwNBDjIP7JoAeLvVqSlNqxZ.txt) (2.0 KB)  
It seems that running this doesn't fix anything, it just confirms issues.

**RE: the store-utils** , I'm having difficulty understanding all of the readme.md directions and paths. Here's where I'm at...

**### Usage**  
As directed, I've cd'd to the dir for \store-util-3.5.6  
I don't understand what either of the following are asking me to do, or where I run or edit...

```auto
export NEO4J_HOME=/path/to/neo4j

```

```auto
# remove target db
rm -rf /path/to/fixed.db

```

**### Config**  
I've set up my neo4j.properties file with source and target like this...  
 ![copy-store-neo4j-properties](https://us1.discourse-cdn.com/flex021/uploads/neo4jcommunity/original/3X/7/0/70f5019eb7e9e3bad7ba981530678a6cf86ea1fd.png)

**### General Usage**  
I then ran the following in the cmd line...

```auto
C:\Users\owner\Documents\store-util-3.5.6>copy-store.sh community source.db target.db

```

I am expecting 'some target .db thing' to show up in my C:\Users\owner\Documents\new356 dir, but no-go at the moment.

What am I missing?
