I have a service name with long url as follow.
when I click on it, it shows that this service is not authorized or existed. This could be due to special charater = ? . Is there another way to get around that? I want service's name to be url so I can distinguish which one is which.
Can't view Service. NOT AUTHORIZED
-
amit.ahuja
- Posts: 113
- Joined: Fri May 15, 2015 8:20 am
Can't view Service. NOT AUTHORIZED
You do not have the required permissions to view the files attached to this post.
Re: Can't view Service. NOT AUTHORIZED
I can't replicate this on XI5.2.3. What happens if you remove the http:// from the name?
Former Nagios Employee.
me.
me.
-
amit.ahuja
- Posts: 113
- Joined: Fri May 15, 2015 8:20 am
Re: Can't view Service. NOT AUTHORIZED
still same issue. I named my service description with whole url
define service {
host_name ma100mlp_sec
servicegroups Environment URL
service_description http:// ma100mlp:9080/sdp/service-test/CatalogService/getProduct?productId=809315&channel=SITE
define service {
host_name ma100mlp_sec
servicegroups Environment URL
service_description http:// ma100mlp:9080/sdp/service-test/CatalogService/getProduct?productId=809315&channel=SITE
Re: Can't view Service. NOT AUTHORIZED
What version of XI are you running? I tried to add a ? to my service description, and I'm alerted with a javascript error saying 'illegal characters'. See the screenshot below -
To answer your question though, yes, I believe the ? & = can all cause issues, because what your Nagios is trying to do is open this URL -
Code: Select all
http://nagoisxi/nagiosxi/includes/components/xicore/status.php?show=servicedetail&host=localhost&service=http://ma100mlp:9080/sdp/service-test/CatalogService/getProduct?productId=809315&channel=SITE&dest=auto
You do not have the required permissions to view the files attached to this post.
Former Nagios Employee
-
amit.ahuja
- Posts: 113
- Joined: Fri May 15, 2015 8:20 am
Re: Can't view Service. NOT AUTHORIZED
I have edited the nagios.cfg file ignore those characters in order to name the url in service description.
illegal_macro_output_chars=`~$&|'"<>
but after doing that, clicking on the service will give me "NOT AUTHORIZED" error.
is there another way to name the url without getting this error? I have thousands of them. so have to name in service description in order to see them all in GUI.
illegal_macro_output_chars=`~$&|'"<>
but after doing that, clicking on the service will give me "NOT AUTHORIZED" error.
is there another way to name the url without getting this error? I have thousands of them. so have to name in service description in order to see them all in GUI.
Re: Can't view Service. NOT AUTHORIZED
Let's try to wrap that service description in single quotes('something') and see if that helps.
Former Nagios Employee.
me.
me.
Re: Can't view Service. NOT AUTHORIZED
Did you change this one?
I'm sure those are in there for a reason though, I can't guarantee you won't run into any issues.
Code: Select all
illegal_object_name_chars=`~!$%^&*|'"<>?,()=-
amit.ahuja
- Posts: 113
- Joined: Fri May 15, 2015 8:20 am
Re: Can't view Service. NOT AUTHORIZED
I removed ?= from illegal_object_name_chars in order the name service description with whole URL. Let's say that if i revert it back to default, is there another way to name service description with url. I just want to see the url in service status page
You do not have the required permissions to view the files attached to this post.
Re: Can't view Service. NOT AUTHORIZED
What happens if you access the link like this? Does it work?
The problem in this link specifically is that additional variables are contained after the service=, this means that when you try to load the page it's also processing productId=809315&channel=SITE&dest=auto.
Code: Select all
http://nagoisxi/nagiosxi/includes/components/xicore/status.php?show=servicedetail&host=localhost&service="http://ma100mlp:9080/sdp/service-test/CatalogService/getProduct?productId=809315&channel=SITE&dest=auto"
Former Nagios Employee