Graylog2 / graylog2-server

Free and open log management
https://www.graylog.org
Other
7.41k stars 1.07k forks source link

Error 500 while loading Content Pack #5661

Closed USIGI closed 5 years ago

USIGI commented 5 years ago

Expected Behavior

When I open the site http://graylog-fqdn/system/contentpacks the activated content packs are not displayed. The developpement tools show a error code 500

Your Environment

Graylog -> server.log

<!--- Include as many relevant details about the environment you experienced the bug in -->
2019-02-08T11:12:37.864+01:00 ERROR [AnyExceptionClassMapper] Unhandled exception in REST resource
java.lang.RuntimeException: IOException encountered while reading from a byte array input stream
    at org.mongojack.internal.stream.JacksonDBDecoder.decode(JacksonDBDecoder.java:67) ~[graylog.jar:?]
    at com.mongodb.DBDecoderAdapter.decode(DBDecoderAdapter.java:49) ~[graylog.jar:?]
    at com.mongodb.DBDecoderAdapter.decode(DBDecoderAdapter.java:29) ~[graylog.jar:?]
    at com.mongodb.operation.CommandResultArrayCodec.decode(CommandResultArrayCodec.java:52) ~[graylog.jar:?]
    at com.mongodb.operation.CommandResultDocumentCodec.readValue(CommandResultDocumentCodec.java:60) ~[graylog.jar:?]
    at org.bson.codecs.BsonDocumentCodec.decode(BsonDocumentCodec.java:84) ~[graylog.jar:?]
    at org.bson.codecs.BsonDocumentCodec.decode(BsonDocumentCodec.java:41) ~[graylog.jar:?]
    at org.bson.codecs.configuration.LazyCodec.decode(LazyCodec.java:47) ~[graylog.jar:?]
    at org.bson.codecs.BsonDocumentCodec.readValue(BsonDocumentCodec.java:101) ~[graylog.jar:?]
    at com.mongodb.operation.CommandResultDocumentCodec.readValue(CommandResultDocumentCodec.java:63) ~[graylog.jar:?]
    at org.bson.codecs.BsonDocumentCodec.decode(BsonDocumentCodec.java:84) ~[graylog.jar:?]
    at org.bson.codecs.BsonDocumentCodec.decode(BsonDocumentCodec.java:41) ~[graylog.jar:?]
    at com.mongodb.connection.ReplyMessage.<init>(ReplyMessage.java:50) ~[graylog.jar:?]
    at com.mongodb.connection.CommandProtocol.getResponseDocument(CommandProtocol.java:132) ~[graylog.jar:?]
    at com.mongodb.connection.CommandProtocol.execute(CommandProtocol.java:111) ~[graylog.jar:?]
    at com.mongodb.connection.DefaultServer$DefaultServerProtocolExecutor.execute(DefaultServer.java:159) ~[graylog.jar:?]
    at com.mongodb.connection.DefaultServerConnection.executeProtocol(DefaultServerConnection.java:289) ~[graylog.jar:?]
    at com.mongodb.connection.DefaultServerConnection.command(DefaultServerConnection.java:176) ~[graylog.jar:?]
    at com.mongodb.operation.CommandOperationHelper.executeWrappedCommandProtocol(CommandOperationHelper.java:216) ~[graylog.jar:?]
    at com.mongodb.operation.CommandOperationHelper.executeWrappedCommandProtocol(CommandOperationHelper.java:207) ~[graylog.jar:?]
    at com.mongodb.operation.CommandOperationHelper.executeWrappedCommandProtocol(CommandOperationHelper.java:113) ~[graylog.jar:?]
    at com.mongodb.operation.FindOperation$1.call(FindOperation.java:715) ~[graylog.jar:?]
    at com.mongodb.operation.FindOperation$1.call(FindOperation.java:709) ~[graylog.jar:?]
    at com.mongodb.operation.OperationHelper.withConnectionSource(OperationHelper.java:433) ~[graylog.jar:?]
    at com.mongodb.operation.OperationHelper.withConnection(OperationHelper.java:406) ~[graylog.jar:?]
    at com.mongodb.operation.FindOperation.execute(FindOperation.java:709) ~[graylog.jar:?]
    at com.mongodb.operation.FindOperation.execute(FindOperation.java:81) ~[graylog.jar:?]
    at com.mongodb.Mongo.execute(Mongo.java:810) ~[graylog.jar:?]
    at com.mongodb.Mongo$2.execute(Mongo.java:797) ~[graylog.jar:?]
    at com.mongodb.DBCursor.initializeCursor(DBCursor.java:871) ~[graylog.jar:?]
    at com.mongodb.DBCursor.hasNext(DBCursor.java:142) ~[graylog.jar:?]
    at org.mongojack.DBCursor.hasNext(DBCursor.java:330) ~[graylog.jar:?]
    at org.graylog2.bundles.BundleService.loadAll(BundleService.java:83) ~[graylog.jar:?]
    at org.graylog2.rest.resources.system.bundles.BundleResource.listBundles(BundleResource.java:100) ~[graylog.jar:?]
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_191]
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_191]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_191]
    at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_191]
    at org.glassfish.jersey.server.model.internal.ResourceMethodInvocationHandlerFactory$1.invoke(ResourceMethodInvocationHandlerFactory.java:81) ~[graylog.jar:?]
    at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher$1.run(AbstractJavaResourceMethodDispatcher.java:144) ~[graylog.jar:?]
    at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.invoke(AbstractJavaResourceMethodDispatcher.java:161) ~[graylog.jar:?]
    at org.glassfish.jersey.server.model.internal.JavaResourceMethodDispatcherProvider$TypeOutInvoker.doDispatch(JavaResourceMethodDispatcherProvider.java:205) ~[graylog.jar:?]
    at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.dispatch(AbstractJavaResourceMethodDispatcher.java:99) ~[graylog.jar:?]
    at org.glassfish.jersey.server.model.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:389) ~[graylog.jar:?]
    at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:347) ~[graylog.jar:?]
    at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:102) ~[graylog.jar:?]
    at org.glassfish.jersey.server.ServerRuntime$2.run(ServerRuntime.java:326) [graylog.jar:?]
    at org.glassfish.jersey.internal.Errors$1.call(Errors.java:271) [graylog.jar:?]
    at org.glassfish.jersey.internal.Errors$1.call(Errors.java:267) [graylog.jar:?]
    at org.glassfish.jersey.internal.Errors.process(Errors.java:315) [graylog.jar:?]
    at org.glassfish.jersey.internal.Errors.process(Errors.java:297) [graylog.jar:?]
    at org.glassfish.jersey.internal.Errors.process(Errors.java:267) [graylog.jar:?]
    at org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:317) [graylog.jar:?]
    at org.glassfish.jersey.server.ServerRuntime.process(ServerRuntime.java:305) [graylog.jar:?]
    at org.glassfish.jersey.server.ApplicationHandler.handle(ApplicationHandler.java:1154) [graylog.jar:?]
    at org.glassfish.jersey.grizzly2.httpserver.GrizzlyHttpContainer.service(GrizzlyHttpContainer.java:384) [graylog.jar:?]
    at org.glassfish.grizzly.http.server.HttpHandler$1.run(HttpHandler.java:224) [graylog.jar:?]
    at com.codahale.metrics.InstrumentedExecutorService$InstrumentedRunnable.run(InstrumentedExecutorService.java:176) [graylog.jar:?]
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_191]
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_191]
    at java.lang.Thread.run(Thread.java:748) [?:1.8.0_191]
edmundoa commented 5 years ago

Hi @USIGI,

We need a few more details to be able to help you. Is this happening on a new setup or did you upgrade your existing one? Also, would you be so kind as to share with us the Content Packs in your Graylog setup?

Thank you!

USIGI commented 5 years ago

I've installed version 3. Afterwards I did a downgrade to 2.5. Eventually there is a issue with default content packs which were written into the db. I found some entries in the db which I deleted. I haven't even changed any content pack because of this issue.

Content Packs according the DB are now:

edmundoa commented 5 years ago

Sorry to read that, downgrading from Graylog 3 to 2.5 is not supported and probably will break a few things. Did you do a MongoDB backup before upgrading to 3.0? I would try restoring the database to its previous state if possible, as I think that's the easiest way to go.

As we use Github to track issues with the product itself, I'll close this one. In case you need further help with fixing your setup, please post this issue to our discussion forum or join the #graylog channel on freenode IRC.

Thank you!