Could not upgrade capabilities.xml to Kazuki - Nexus doesn't start

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Could not upgrade capabilities.xml to Kazuki - Nexus doesn't start

Tim Astle
Hi all,

I have a system administrator updating our Nexus OSS from 2.7.0-06 to 2.8.0-05.  We're following this guide:
https://support.sonatype.com/entries/21701998-nexus-upgrade-notes

He just showed me the logs after trying to start 2.8 and this is what I'm seeing:

jvm 1    | 1) Error injecting constructor, java.lang.Error: Could not boot capabilities
jvm 1    |   at org.sonatype.nexus.NxApplication.<init>(NxApplication.java:78)
jvm 1    |   at WebAppClassLoader=Sonatype Nexus 2.8.0-05@5e4aaf28 (via modules: org.eclipse.sisu.wire.WireModule -> org.eclipse.sisu.plexus.PlexusSpaceModule -> org.eclipse.sisu.plexus.PlexusBindingModule)
jvm 1    |   while locating org.sonatype.nexus.NxApplication

...

jvm 1    | Caused by: java.lang.IllegalStateException: Could not upgrade capabilities.xml to Kazuki as Kazuki already contains capabilities
jvm 1    |     at com.google.common.base.Preconditions.checkState(Preconditions.java:176) ~[na:na]
jvm 1    |     at org.sonatype.nexus.plugins.capabilities.internal.storage.CapabilityStorageConverter.convertToKazukiIfNecessary(CapabilityStorageConverter.java:74) ~[na:na]
jvm 1    |     at org.sonatype.nexus.plugins.capabilities.internal.CapabilityRegistryBooter.handle(CapabilityRegistryBooter.java:61) ~[na:na]
jvm 1    |     ... 54 common frames omitted

Any idea as what is going wrong?

Our configuration is that we have our data on a SAN, and the web application points to it from a linux VM.

I believe he is accessing the repository on the SAN with both the current Nexus instance (2.7) and the
new Nexus instance (2.8) as part of testing.


Tim
Reply | Threaded
Open this post in threaded view
|

Re: Could not upgrade capabilities.xml to Kazuki - Nexus doesn't start

Tamás Cservenák
Hi,

any other error in logs? I'd expect to have some before the ISEx, maybe some related to FS perms or alike?

You should check the ${sonatype-work}/nexus/db folder for existence, and perms (user running nexus process should have full access to this folder and below).


HTH,
~t~


On Thu, May 22, 2014 at 4:54 AM, Timothy Astle <[hidden email]> wrote:
Hi all,

I have a system administrator updating our Nexus OSS from 2.7.0-06 to 2.8.0-05.  We're following this guide:
https://support.sonatype.com/entries/21701998-nexus-upgrade-notes

He just showed me the logs after trying to start 2.8 and this is what I'm seeing:

jvm 1    | 1) Error injecting constructor, java.lang.Error: Could not boot capabilities
jvm 1    |   at org.sonatype.nexus.NxApplication.<init>(NxApplication.java:78)
jvm 1    |   at WebAppClassLoader=Sonatype Nexus 2.8.0-05@5e4aaf28 (via modules: org.eclipse.sisu.wire.WireModule -> org.eclipse.sisu.plexus.PlexusSpaceModule -> org.eclipse.sisu.plexus.PlexusBindingModule)
jvm 1    |   while locating org.sonatype.nexus.NxApplication

...

jvm 1    | Caused by: java.lang.IllegalStateException: Could not upgrade capabilities.xml to Kazuki as Kazuki already contains capabilities
jvm 1    |     at com.google.common.base.Preconditions.checkState(Preconditions.java:176) ~[na:na]
jvm 1    |     at org.sonatype.nexus.plugins.capabilities.internal.storage.CapabilityStorageConverter.convertToKazukiIfNecessary(CapabilityStorageConverter.java:74) ~[na:na]
jvm 1    |     at org.sonatype.nexus.plugins.capabilities.internal.CapabilityRegistryBooter.handle(CapabilityRegistryBooter.java:61) ~[na:na]
jvm 1    |     ... 54 common frames omitted

Any idea as what is going wrong?

Our configuration is that we have our data on a SAN, and the web application points to it from a linux VM.

I believe he is accessing the repository on the SAN with both the current Nexus instance (2.7) and the
new Nexus instance (2.8) as part of testing.


Tim

Reply | Threaded
Open this post in threaded view
|

Re: Could not upgrade capabilities.xml to Kazuki - Nexus doesn't start

Stuart McCulloch-2
Hi Tim,

Are the two Nexus instances sharing the same sonatype-work directory, or do they each have their own copy?

The reason I ask is because Nexus 2.8 automatically migrates the capabilities.xml file used in 2.7 to the new capabilities storage (kazuki) in 2.8. As part of this migration it moves the original file to capabilities.xml.old.

If for some reason another process creates a new capabilities.xml file in the same sonatype-work directory (like the default "sonatype-work/nexus/conf/capabilities.xml” file that Nexus 2.7 creates at startup) then Nexus 2.8 would refuse to re-do the migration, to avoid corrupting the previously migrated data, and stop. Backing up and removing this capabilities.xml file should then allow Nexus 2.8 to start up. You can then check the capabilities panel to verify the migration.

If you want to repeat the capabilities migration then stop Nexus, remove "sonatype-work/nexus/db/capabilities/capabilities.h2.db", copy the old capabilities.xml file back into the configuration directory, and restart Nexus.

Cheers, Stuart

On 22 May 2014, at 12:46, Tamás Cservenák <[hidden email]> wrote:

Hi,

any other error in logs? I'd expect to have some before the ISEx, maybe some related to FS perms or alike?

You should check the ${sonatype-work}/nexus/db folder for existence, and perms (user running nexus process should have full access to this folder and below).

HTH,
~t~


On Thu, May 22, 2014 at 4:54 AM, Timothy Astle <[hidden email]> wrote:
Hi all,

I have a system administrator updating our Nexus OSS from 2.7.0-06 to 2.8.0-05.  We're following this guide:
https://support.sonatype.com/entries/21701998-nexus-upgrade-notes

He just showed me the logs after trying to start 2.8 and this is what I'm seeing:

jvm 1    | 1) Error injecting constructor, java.lang.Error: Could not boot capabilities
jvm 1    |   at org.sonatype.nexus.NxApplication.<init>(NxApplication.java:78)
jvm 1    |   at WebAppClassLoader=Sonatype Nexus 2.8.0-05@5e4aaf28 (via modules: org.eclipse.sisu.wire.WireModule -> org.eclipse.sisu.plexus.PlexusSpaceModule -> org.eclipse.sisu.plexus.PlexusBindingModule)
jvm 1    |   while locating org.sonatype.nexus.NxApplication

...

jvm 1    | Caused by: java.lang.IllegalStateException: Could not upgrade capabilities.xml to Kazuki as Kazuki already contains capabilities
jvm 1    |     at com.google.common.base.Preconditions.checkState(Preconditions.java:176) ~[na:na]
jvm 1    |     at org.sonatype.nexus.plugins.capabilities.internal.storage.CapabilityStorageConverter.convertToKazukiIfNecessary(CapabilityStorageConverter.java:74) ~[na:na]
jvm 1    |     at org.sonatype.nexus.plugins.capabilities.internal.CapabilityRegistryBooter.handle(CapabilityRegistryBooter.java:61) ~[na:na]
jvm 1    |     ... 54 common frames omitted

Any idea as what is going wrong?

Our configuration is that we have our data on a SAN, and the web application points to it from a linux VM.

I believe he is accessing the repository on the SAN with both the current Nexus instance (2.7) and the
new Nexus instance (2.8) as part of testing.


Tim


Reply | Threaded
Open this post in threaded view
|

Re: Could not upgrade capabilities.xml to Kazuki - Nexus doesn't start

Tim Astle
The advice in the 3rd paragraph got us going.

Thanks Stuart!


Tim



On 22/05/2014 9:20 AM, Stuart McCulloch wrote:
Hi Tim,

Are the two Nexus instances sharing the same sonatype-work directory, or do they each have their own copy?

The reason I ask is because Nexus 2.8 automatically migrates the capabilities.xml file used in 2.7 to the new capabilities storage (kazuki) in 2.8. As part of this migration it moves the original file to capabilities.xml.old.

If for some reason another process creates a new capabilities.xml file in the same sonatype-work directory (like the default "sonatype-work/nexus/conf/capabilities.xml” file that Nexus 2.7 creates at startup) then Nexus 2.8 would refuse to re-do the migration, to avoid corrupting the previously migrated data, and stop. Backing up and removing this capabilities.xml file should then allow Nexus 2.8 to start up. You can then check the capabilities panel to verify the migration.

If you want to repeat the capabilities migration then stop Nexus, remove "sonatype-work/nexus/db/capabilities/capabilities.h2.db", copy the old capabilities.xml file back into the configuration directory, and restart Nexus.

Cheers, Stuart

On 22 May 2014, at 12:46, Tamás Cservenák <[hidden email]> wrote:

Hi,

any other error in logs? I'd expect to have some before the ISEx, maybe some related to FS perms or alike?

You should check the ${sonatype-work}/nexus/db folder for existence, and perms (user running nexus process should have full access to this folder and below).

HTH,
~t~


On Thu, May 22, 2014 at 4:54 AM, Timothy Astle <[hidden email]> wrote:
Hi all,

I have a system administrator updating our Nexus OSS from 2.7.0-06 to 2.8.0-05.  We're following this guide:
https://support.sonatype.com/entries/21701998-nexus-upgrade-notes

He just showed me the logs after trying to start 2.8 and this is what I'm seeing:

jvm 1    | 1) Error injecting constructor, java.lang.Error: Could not boot capabilities
jvm 1    |   at org.sonatype.nexus.NxApplication.<init>(NxApplication.java:78)
jvm 1    |   at WebAppClassLoader=Sonatype Nexus 2.8.0-05@5e4aaf28 (via modules: org.eclipse.sisu.wire.WireModule -> org.eclipse.sisu.plexus.PlexusSpaceModule -> org.eclipse.sisu.plexus.PlexusBindingModule)
jvm 1    |   while locating org.sonatype.nexus.NxApplication

...

jvm 1    | Caused by: java.lang.IllegalStateException: Could not upgrade capabilities.xml to Kazuki as Kazuki already contains capabilities
jvm 1    |     at com.google.common.base.Preconditions.checkState(Preconditions.java:176) ~[na:na]
jvm 1    |     at org.sonatype.nexus.plugins.capabilities.internal.storage.CapabilityStorageConverter.convertToKazukiIfNecessary(CapabilityStorageConverter.java:74) ~[na:na]
jvm 1    |     at org.sonatype.nexus.plugins.capabilities.internal.CapabilityRegistryBooter.handle(CapabilityRegistryBooter.java:61) ~[na:na]
jvm 1    |     ... 54 common frames omitted

Any idea as what is going wrong?

Our configuration is that we have our data on a SAN, and the web application points to it from a linux VM.

I believe he is accessing the repository on the SAN with both the current Nexus instance (2.7) and the
new Nexus instance (2.8) as part of testing.


Tim



--
Tim Astle
Development Manager
Web Technologies

CARIS
115 Waggoners Lane
Fredericton, New Brunswick
Canada    E3B 2L4
Tel: +1.506.458.8533     Fax: +1.506.459.3849
www.caris.com

CARIS 2014
June 2-5, 2014 | Brest, France | 2-5 juin, 2014
Join us in France at CARIS 2014 as we focus on Developing the Blue Economy. www.caris.com/caris2014/
Venez nous rejoindre en France pour CARIS 2014 et appuyons ensemble l'Économie Bleue. www.caris.com/caris2014-fr/

Download your free copy of CARIS Easy View today!
www.caris.com/easyview

_________________________________________________________________________
This email and any files transmitted with it are confidential and intended only for the addressee(s). If you are not the intended recipient(s) please notify us by email reply. You should not use, disclose, distribute or copy this communication if received in error.

Any views or opinions expressed in this email are solely those of the author and do not necessarily represent those of the company. No binding contract will result from this email until such time as a written document is signed on behalf of the company.