All Apps and Add-ons

500 Internal Server Error when I click "Manage Apps" under settings?

manish_singh_77
Builder

Hi ,

I am getting 500 Internal Server Error when I click on Manage Apps, however other functionalities are working fine.

Any quick help would be greatly appreciated.

Labels (1)
Tags (1)
0 Karma

kevansrbfcu
Explorer

We are 8.0.1 on Linux and here is how I found the Dashboard that was missing a label:

1.) List Dashboard XML files that are missing a label:

     grep -rl "<dashboard" /opt/splunk/etc/* | grep "\.xml" | xargs grep "<label></label>"

 

2.) Edit these files and change "<label></label>" to "<label>New Label</label>". (Change "New Label" to whatever you want)

 

3.) Restart Splunk.

Nenya
Engager

Hi everyone,

I did grep -rl "<dashboard" /opt/splunk/etc/* | grep "\.xml" | xargs grep "<label></label>",

found an .xml file with no content inside <label></label>,

changed it to <label>Corvil</label>,

restarted Splunk -in fact, the whole system-,

tried updating an app -any app-

and the 500 Error is still there.

 

Any suggestion?

Thanks!

0 Karma

Suirand1
Explorer

I am having the same problem too

0 Karma

michael_kushma
Path Finder

The simple answer to this is you have a dashboard without a title. As soon as I fixed that, all the problems with 500 errors went away.

jpolcari22
New Member

I'm experiencing this too after an upgrade to 8. Did you end up finding a resolution?

0 Karma

skjun
Loves-to-Learn

In my case,
The problem occurred when some dashboard had a label tag but no tag content.
When I added the string in label, the 500 error disappeared.

0 Karma

cucuro11
Explorer

May be it is not problem of Splunk enterprise version. I think...

0 Karma

kdamak_splunk
Splunk Employee
Splunk Employee

Ran into this issue - label was missing in one of the dashboard XML files.

If you're seeing this error message at the bottom of the stack trace - means this is a likely fix.
File "/opt/splunk/lib/python3.7/site-packages/splunk/appserver/mrsparkle/controllers/view.py", line 806, in buildViewTemplate
viewList.sort(key=lambda x: x['label'])
TypeError: '<' not supported between instances of 'NoneType' and 'str'

Quick workaround is to identify the dashboard XML without a label and update it.
https://docs.splunk.com/Documentation/Splunk/8.0.2/Viz/PanelreferenceforSimplifiedXML#Overview

<dashboard>
  <label>test_db</label>

Borrowed this from Engineering.

Here is a regex to find the labels causing the issue, run inside the splunk or diag folder
linux:
find . -name ".xml" | xargs grep -Pzo "(board.|orm.*)>\s+<\/label>"

skjun
Loves-to-Learn

In my case,
Label values were missing in some old dashboard xml files in other app.
(ex. )

After setting the label value, the dashboard such as manager was successfully loaded.
(ex. 111)

0 Karma

skjun
Loves-to-Learn

I had the exact same problem.
I tried but it did not solve the problem.

0 Karma

kdamak_splunk
Splunk Employee
Splunk Employee

Let me know if this helps. Borrowed this from Engineering.

Here is a regex to find the labels causing the issue, run inside the splunk or diag folder
linux:
find . -name ".xml" | xargs grep -Pzo "(board.|orm.*)>\s+<\/label>"

0 Karma

diasmith
Loves-to-Learn Lots

Did anyone solve this? The regex didn't work

0 Karma

skjun
Loves-to-Learn

find . -name ".xml" | xargs grep -Pzo "(board.|orm.)>\s+<\/label>"

I modified it as above but couldn't find a file.

0 Karma

securitypaul
Explorer

I am also seeing this issue when I click on "Update" to update one of the Apps in the Apps list.

The error page loads after about 4-5 seconds.

0 Karma

jcossin
Engager

I am seeing this same error after upgrading to 8.0.2. It's only on 1 of my SH's, the others are functioning fine.

0 Karma

jcossin
Engager

Eventually found the culprit dashboard without a label tag applied and that resolved the issues.

0 Karma

manish_singh_77
Builder

@broberg

And I don't see any error in the splunkd.log around the same time.

0 Karma

broberg
Communicator

What do you get in your splunkd log?

0 Karma

manish_singh_77
Builder

@broberg

I don't see any specific error.

I see this error in the web access log.

ERROR [5e452b083b7f55f825d890] error:335 - Traceback (most recent call last):
File "/opt/splunk/lib/python3.7/site-packages/cherrypy/cprequest.py", line 628, in respond
self._do_respond(path_info)
File "/opt/splunk/lib/python3.7/site-packages/cherrypy/_cprequest.py", line 687, in _do_respond
response.body = self.handler()
File "/opt/splunk/lib/python3.7/site-packages/cherrypy/lib/encoding.py", line 219, in __call
_
self.body = self.oldhandler(*args, **kwargs)
File "/opt/splunk/lib/python3.7/site-packages/splunk/appserver/mrsparkle/lib/htmlinjectiontoolfactory.py", line 75, in wrapper
resp = handler(*args, **kwargs)
File "/opt/splunk/lib/python3.7/site-packages/cherrypy/cpdispatch.py", line 54, in __call_
return self.callable(*self.args, **self.kwargs)
File "/opt/splunk/lib/python3.7/site-packages/splunk/appserver/mrsparkle/lib/routes.py", line 383, in default
return route.target(self, **kw)
File "</opt/splunk/lib/python3.7/site-packages/decorator.py:decorator-gen-136>", line 2, in upload
File "/opt/splunk/lib/python3.7/site-packages/splunk/appserver/mrsparkle/lib/decorators.py", line 40, in rundecs
return fn(*a, **kw)
File "</opt/splunk/lib/python3.7/site-packages/decorator.py:decorator-gen-134>", line 2, in upload
File "/opt/splunk/lib/python3.7/site-packages/splunk/appserver/mrsparkle/lib/decorators.py", line 118, in check
return fn(self, *a, **kw)
File "</opt/splunk/lib/python3.7/site-packages/decorator.py:decorator-gen-133>", line 2, in upload
File "/opt/splunk/lib/python3.7/site-packages/splunk/appserver/mrsparkle/lib/decorators.py", line 166, in validate_ip
return fn(self, *a, **kw)
File "</opt/splunk/lib/python3.7/site-packages/decorator.py:decorator-gen-132>", line 2, in upload
File "/opt/splunk/lib/python3.7/site-packages/splunk/appserver/mrsparkle/lib/decorators.py", line 245, in preform_sso_check
return fn(self, *a, **kw)
File "</opt/splunk/lib/python3.7/site-packages/decorator.py:decorator-gen-131>", line 2, in upload
File "/opt/splunk/lib/python3.7/site-packages/splunk/appserver/mrsparkle/lib/decorators.py", line 284, in check_login
return fn(self, *a, **kw)
File "</opt/splunk/lib/python3.7/site-packages/decorator.py:decorator-gen-130>", line 2, in upload
File "/opt/splunk/lib/python3.7/site-packages/splunk/appserver/mrsparkle/lib/decorators.py", line 304, in handle_exceptions
return fn(self, *a, **kw)
File "/opt/splunk/lib/python3.7/site-packages/splunk/appserver/mrsparkle/controllers/appinstall.py", line 358, in upload
'state': state
File "/opt/splunk/lib/python3.7/site-packages/splunk/appserver/mrsparkle/controllers/appinstall.py", line 185, in render_admin_template
return manager.render_admin_template(*a, **kw)
File "/opt/splunk/lib/python3.7/site-packages/splunk/appserver/mrsparkle/controllers/admin.py", line 1381, in render_admin_template
args = root.app.buildViewTemplate(namespace, ADMIN_VIEW_NAME, render_invisible=True, build_nav=False, include_app_css_assets=False)
File "/opt/splunk/lib/python3.7/site-packages/splunk/appserver/mrsparkle/controllers/view.py", line 806, in buildViewTemplate
viewList.sort(key=lambda x: x['label'])
TypeError: '<' not supported between instances of 'NoneType' and 'str'

0 Karma

donelliot
Path Finder

I'm getting the same

0 Karma
Get Updates on the Splunk Community!

Federated Search for Amazon S3 | Key Use Cases to Streamline Compliance Workflows

Modern business operations are supported by data compliance. As regulations evolve, organizations must ...

New Dates, New City: Save the Date for .conf25!

Wake up, babe! New .conf25 dates AND location just dropped!! That's right, this year, .conf25 is taking place ...

Introduction to Splunk Observability Cloud - Building a Resilient Hybrid Cloud

Introduction to Splunk Observability Cloud - Building a Resilient Hybrid Cloud  In today’s fast-paced digital ...