Cannot load database configuration. The database seems corrupted - Sonatype Nexus Repository - Sonatype Community
Cannot load database configuration. The database seems corrupted
post by pranav on Jun 7, 2023
Pranav Murali
we have a containerized Nexus Repository Manager OSS 3.48.0-0 which is running on centos 7 base image and our data’s are stored on mount which is totally 700+GB.
our client wants to move nexus to dedicated server which Rocky Linux 8, I have tried to migrate but whenever I tried to start the nexus service it is saying that
"Cannot load database configuration. The database seems corrupted"
all the data transfer was done to new machine using rsync
rsync -avz --progress sonatype-work ip:/nexus
I have followed the below doc to the migration process, can anybody help or suggest to fix this issue
2023-06-08 03:11:19,188+0000 ERROR [ForkJoinPool.commonPool-worker-2] *SYSTEM com.orientechnologies.orient.core.storage.impl.local.paginated.OLocalPaginatedStorage - Exception `7BB1F7DC` in storage `plocal:/nexus/sonatype-work/nexus3/db/security`: 2.2.37 (build a7541e7ceeabf592dd9a7b2928b6c023cbc73193, branch 2.2.x)
com.orientechnologies.orient.core.exception.OStorageException: Cannot open local storage '/nexus/sonatype-work/nexus3/db/security' with mode=rw
DB name="security"
at com.orientechnologies.orient.core.storage.impl.local.OAbstractPaginatedStorage.open(OAbstractPaginatedStorage.java:323)
at com.orientechnologies.orient.core.db.document.ODatabaseDocumentTx.open(ODatabaseDocumentTx.java:259)
at org.sonatype.nexus.orient.DatabaseManagerSupport.connect(DatabaseManagerSupport.java:178)
at org.sonatype.nexus.orient.DatabaseManagerSupport.createInstance(DatabaseManagerSupport.java:312)
at java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1660)
at org.sonatype.nexus.orient.DatabaseManagerSupport.instance(DatabaseManagerSupport.java:289)
at java.util.stream.ForEachOps$ForEachOp$OfRef.accept(ForEachOps.java:183)
at java.util.Spliterators$ArraySpliterator.forEachRemaining(Spliterators.java:948)
at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:482)
at java.util.stream.ForEachOps$ForEachOp$OfRef.accept(ForEachOps.java:183)
at java.util.Spliterators$ArraySpliterator.forEachRemaining(Spliterators.java:948)
at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:482)
at java.util.stream.ForEachOps$ForEachOp$OfRef.accept(ForEachOps.java:183)
at java.util.Spliterators$ArraySpliterator.forEachRemaining(Spliterators.java:948)
post by mpiggott on Jun 8, 2023
Matthew Piggott
If the server was running while copying data that can result in a corrupted database.
post by pranav on Jun 8, 2023
Pranav Murali
@mpiggott thank you for the response, actually I have copied files when the nexus container was not running. can we try to backup from nexus UI and restore it to the destination, will that work?
as per this document: Backup and Restore