Error in Import content pack #2663
Closed
Comments
@greenx Please attach the complete content pack which triggers the error. |
attached in bottom |
By the way, a rollback in case of failure does not work. |
Hi @greenx, Just to double check: does your |
@greenx As a quick side note, you should upload the JSON file of the content pack and not paste it into the comment field as text. |
Thank you @greenx! The new line was only in the copied text, I guess it was a typo while copy/pasting the long text. I have been able to reproduce the issue you described, will create a patch for it soon. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi, ALL!
I have two similar graylog systems (test->prod).
I created on test system: a few syslog udp inputs and grok patter extractor on each input.
I wanted copy this setting to production system.
In "Create a content pack" I filling field "Name", "Description", "Category", selecting needed "inpurs" and "grok pattern" (I don't have output, stream, a dashboard) and download content pack.
Next, on product system in "Content packs" - I pressed "import Content pack", select file and upload him.
Now, I select my content pack and press "apply content" and receive error... something like "error see logs"
Expected Behavior
I expected that import settings (inputs,extractors, grok patterns)
Current Behavior
in logs I saw the following:
I understand that there are two errors:
1.) Wrong text in error description. I don't use dashboards (absolutely). In this place -
graylog2-server/graylog2-server/src/main/java/org/graylog2/bundles/BundleImporter.java
Line 138 in 9dcad95
2.) And main error - "Missing parameters source_field or target_field."
2.1.) In my json - target_field is empty:
2.2.) Next, I found it string
That is, the field can be left blank?
Here - https://github.com/Graylog2/graylog2-web-interface/blob/eb084699edf5686bf124b4086d81ecfdc2e3fb2c/app/controllers/ExtractorsController.java#L137
2.3.) In this case, adding grok patter always is TRUE in this code:
Here -
graylog2-server/graylog2-server/src/main/java/org/graylog2/bundles/BundleImporter.java
Line 312 in 9dcad95
Possible Solution
I do not know much about the graylog - maybe it will be enough to change a logical expression.
Steps to Reproduce (for bugs)
Environment
The text was updated successfully, but these errors were encountered: